# Image to Prompt Generator v3 (`dev00/z-image-apify`) Actor

Generate Midjourney, Stable Diffusion, and natural language prompt descriptions from any image URL using visual AI models.

- **URL**: https://apify.com/dev00/z-image-apify.md
- **Developed by:** [dev00](https://apify.com/dev00) (community)
- **Categories:** AI, Agents
- **Stats:** 6 total users, 2 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$15.00 / 1,000 image to prompt scans

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.
Actors are written with capital "A".

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

## 🔗 Image to Prompt v3 Generator Actor

Instantly convert any image URL into a detailed Midjourney, Stable Diffusion, or natural language prompt using advanced vision models (without storing alt-text or extra tracking IDs).

This Actor integrates with a high-performance Cloudflare Worker edge reverse-proxy to process visual media.

***

### 🌟 Key Features

- **Deep Visual Interrogation**: Analyzes subject attributes, background elements, lighting conditions, styling, perspective, and color palettes.
- **Prompt Engineering Optimized**: Tailors generated prompt descriptions to be directly usable in generative text-to-image AI platforms.
- **Multi-Storage Outputs**: Saves the raw result object to both the default dataset and Key-Value store under the `OUTPUT` key.
- **Privacy Aware**: Removes the `requestId` tracking field from response payloads automatically.

***

### 📥 Input Parameters

| Field | Type | Description | Prefill Example |
| :--- | :--- | :--- | :--- |
| **Image URL** | `string` | The public URL of the image to analyze. | `https://picsum.photos/id/237/200/300.jpg` |
| **Language** | `string` | The language of the prompt output (e.g. 'en', 'es'). | `en` |

#### Input JSON Example

```json
{
  "image_url": "https://picsum.photos/id/237/200/300.jpg",
  "language": "en"
}
```

***

### 📤 Output Data Structure

The dataset outputs the complete JSON response:

#### Output JSON Example (Success)

```json
{
  "success": true,
  "result": "This image features a yellow emoji face as the central subject, rendered in a simple, cartoonish, and flat graphic style...",
  "cached": false
}
```

#### Output JSON Example (Error/Missing)

```json
{
  "success": false,
  "error": "Failed to analyze image, please try again"
}
```

***

### 💳 Apify Pricing & Monetization

This Actor is published under the **Apify Monetization** program. The pricing consists of two components: the developer's monetization charge and Apify's infrastructure usage cost.

#### 1. Developer Monetization (Pay-Per-Event)

We charge a fixed price per successful prompt generation:

- **Pricing Model**: Pay-Per-Event (PPE)
- **Event Name**: `z-image-scan`
- **Price Per Event**: **$0.015** (Only charged when the prompt is successfully generated; failed runs are free).

#### 2. Apify Platform Compute Costs (Usage-Based)

Since the actor runs on Apify's serverless infrastructure, it consumes platform memory:

- **Recommended Memory**: **256 MB** (Very lightweight because it offloads processing to the Cloudflare Worker).
- **Average Run Time**: 1 - 3 seconds (excluding container startup cold starts).
- **Compute Units (CU)**: Consumes approx. **0.0001 - 0.0003 CU** per run.
- **Estimated Cost**: Less than **$0.00005** per run in platform resources.

#### 3. Free Trial & Limits

- **Trial Credits**: Every new user receives **$1.00** of free platform usage credits upon registration, allowing for up to **60+ free image scans** during evaluation.

# Actor input Schema

## `image_url` (type: `string`):

Provide the public URL of the image you want to generate a prompt description for.

## `language` (type: `string`):

The language of the generated prompt text (e.g. 'en', 'es', 'fr').

## Actor input object example

```json
{
  "image_url": "https://picsum.photos/id/237/200/300.jpg",
  "language": "en"
}
```

# Actor output Schema

## `results` (type: `string`):

No description

## `keyValueStoreResult` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "image_url": "https://picsum.photos/id/237/200/300.jpg",
    "language": "en"
};

// Run the Actor and wait for it to finish
const run = await client.actor("dev00/z-image-apify").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "image_url": "https://picsum.photos/id/237/200/300.jpg",
    "language": "en",
}

# Run the Actor and wait for it to finish
run = client.actor("dev00/z-image-apify").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "image_url": "https://picsum.photos/id/237/200/300.jpg",
  "language": "en"
}' |
apify call dev00/z-image-apify --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,dev00/z-image-apify"
        }
    }
}

```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/dZG7Z0J7SaeMig7XC/builds/EMj5akZv6uMxeX2PM/openapi.json
