# Ai Floor Planner (`calm_necessity/ai-floor-planner`) Actor

This Actor provides an AI Floor Plan Creator API that generates clean, professional floor plans from simple text descriptions or structured inputs.It helps users quickly visualize architectural layouts without manual drafting or CAD software.

- **URL**: https://apify.com/calm_necessity/ai-floor-planner.md
- **Developed by:** [Taher Ali Badnawarwala](https://apify.com/calm_necessity) (community)
- **Categories:** AI, Real estate, Developer tools
- **Stats:** 214 total users, 0 monthly users, 100.0% runs succeeded, 2 bookmarks
- **User rating**: No ratings yet

## Pricing

from $80.00 / 1,000 results

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?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
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.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## 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.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

<header>

## AI Floor Planner

<p><strong>Text-to-floor-plan API</strong> that turns a description into a ready-to-use floor plan image with AutoCAD commands. Send one prompt and get back a direct image URL and metadata. Designed for architects, real estate, interior designers, and developers who want fast, automated floor plan generation without design tools.</p>

<blockquote>
  <strong>What it does:</strong> Send a text prompt (for example <em>"2-bedroom apartment with living room, kitchen, and bathroom"</em> or <em>"Modern 3-bedroom house with open-plan kitchen"</em>) and receive a generated floor plan image URL plus AutoCAD commands in seconds.
</blockquote>

</header>

***

### TL;DR

- **Input:** One text prompt (floor plan description)
- **Output:** Floor plan image URL + metadata + AutoCAD commands
- **Use it for:** Architecture, real estate, interior design, automation, construction
- **Result time:** Usually 1–2 minutes (generation is done by external API)

***

### Table of contents

- [Try it now](#try-it-now)
- [Overview](#overview)
- [Usage examples](#usage-examples)
- [Features](#features)
- [Configuration](#configuration)
- [Usage](#usage)
- [Output](#output)
- [For bloggers & tutorial writers](#for-bloggers--tutorial-writers)
- [Grow your user base](#grow-your-user-base)
- [Integration](#integration)
- [Technical details](#technical-details)
- [FAQ](#faq)
- [Resources](#resources)

***

### Try it now

| Action | Link |
|------|------|
| **Run in Apify Console** | Open Actor → Start |
| **API (sync)** | `POST https://api.apify.com/v2/acts/YOUR_USERNAME~ai-floor-planner/run-sync` |

<em>Replace <code>YOUR_USERNAME</code> with your Apify username.</em>

***

### Overview

The **AI Floor Planner** creates floor plans from plain text using the MultipleWords floor plan generation API. You describe the layout, rooms, and style; the Actor returns a generated floor plan image URL, structured metadata, and AutoCAD commands for technical implementation.

This Actor is useful when you need floor plans on demand, at scale, or as part of an automated workflow.

#### Common use cases

| Category | Examples |
|-------|---------|
| Architecture & design | Rapid prototyping, layout variations, residential/commercial plans |
| Real estate | Property listings, virtual staging, renovation proposals |
| Interior design | Furniture layouts, space planning, client presentations |
| Development & automation | Batch generation, API integration, automated documentation |
| Construction & planning | Initial concepts, approval alternatives, technical drawings |

> **Note:** Usage rights depend on the upstream API and your Apify plan. Review terms before commercial use.

***

### Usage examples

Paste these into the **Prompt** field or API input.

| Scenario | Prompt |
|-------|--------|
| Small apartment | `Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom.` |
| Modern house | `Modern 3-bedroom house with open-plan kitchen and living area, two bathrooms, and a home office.` |
| Studio | `Create a floor plan for a small studio apartment with a kitchenette and bathroom.` |
| Commercial | `Office layout with open workspace, 4 meeting rooms, and reception area.` |
| Renovation | `2-bedroom flat with separate kitchen, combined living-dining, and one bathroom.` |

***

### Features

- Text-to-floor-plan generation from a single prompt
- Clean JSON output with image URL, metadata, and AutoCAD commands
- Works in bulk via API or standby HTTP mode
- Input validation and retries with exponential backoff
- Runs fully on Apify (Console, API, automation tools)
- Dataset views: overview table and detailed view for easy reading in Output tab

***

### Configuration

All settings are provided via the Actor input.

#### Input parameters

| Parameter | Type | Required | Default | Description |
|--------|------|----------|--------|-------------|
| `prompt` | string | Yes | — | Text description of the floor plan to generate |

#### Prompt tips

- Include room types and count (bedrooms, bathrooms, kitchen, etc.)
- Mention layout preferences (open concept, separate rooms)
- Specify approximate dimensions if you have requirements
- Describe intended use (residential, commercial, office)
- Add special requirements (accessibility, storage) if needed

#### Example input

```json
{
  "prompt": "Generate a modern 3-bedroom house with an open-plan kitchen and living area, two bathrooms, and a home office."
}
```

***

### Usage

#### Apify Console

1. Open the Actor in Apify Console.
2. Enter a prompt in the **Prompt** field (or use the default).
3. Click **Start** and check the **Output** tab for the floor plan URL, metadata, and AutoCAD commands.

#### API (run-sync)

Replace `YOUR_USERNAME` with your Apify username and `YOUR_API_TOKEN` with your [Apify API token](https://console.apify.com/account/integrations).

```bash
curl -X POST "https://api.apify.com/v2/acts/YOUR_USERNAME~ai-floor-planner/run-sync?token=YOUR_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{"prompt": "Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom."}'
```

Response includes `runId`, `status`, and dataset items with `imageUrl`, `imageLink`, `details` (including `autocadCommands`, `summary`, `originalPrompt`), and `timestamp`.

***

### Output

Each run writes one or more items to the default dataset. The **Output** tab shows organized views (overview and detailed) thanks to the [output schema](https://docs.apify.com/platform/actors/development/actor-definition/output-schema). Each item looks like:

| Field | Description |
|-------|-------------|
| `status` | Success indicator (1 = success) |
| `imageUrl` | Direct URL of the generated floor plan image |
| `imageLink` | Same URL for link display in Console |
| `details` | Full API response (id, timestamps, engine, originalPrompt, detailedDescription, autocadCommands, summary, etc.) |
| `timestamp` | ISO timestamp when the result was saved |

#### Example output (dataset item)

```json
{
  "status": 1,
  "imageUrl": "https://example.com/floor-plans/generated.png",
  "imageLink": "https://example.com/floor-plans/generated.png",
  "details": {
    "id": 506170,
    "imageUrl": "https://example.com/floor-plans/generated.png",
    "imageDescription": "2-bedroom apartment floor plan",
    "imageName": "floor plan generation",
    "imageCreatedAt": "2026-01-23T12:55:52.106684Z",
    "originalPrompt": "Generate a simple 2-bedroom apartment...",
    "detailedDescription": "Detailed floor plan description...",
    "autocadCommands": "LINE 0,0 100,0\nRECTANGLE 0,0 100,80...",
    "summary": "Floor plan summary..."
  },
  "timestamp": "2026-01-23T12:55:52.000Z"
}
```

In the Apify Console **Output** tab you can open **Floor Plan Image** or **Image Link** and copy the URL for use in listings, CAD tools, or automation.

***

### For bloggers & tutorial writers

You can use this Actor in tutorials, blog posts, or videos without running it first:

- **Input:** Use the [Example input](#example-input) or [Usage examples](#usage-examples) table.
- **Output:** Use the [Example output](#example-output-dataset-item) above to show what users get.
- **API:** Use the [API (run-sync)](#api-run-sync) curl example; remind readers to replace `YOUR_USERNAME` and `YOUR_API_TOKEN`.

For promotion ideas, copy-paste posts, and where to share, see [PROMOTION.md](PROMOTION.md) in this repo.

***

### Grow your user base

Promote your Actor to reach more users. Share it where your audience is active:

| Action | Where |
|--------|--------|
| **Share** | Relevant communities, forums, and social media (e.g. Apify Discord, Reddit r/architecture, r/RealEstate, LinkedIn) |
| **Content** | Blog posts, tutorials, or videos showing use cases (e.g. "From text to floor plan in 5 minutes", Make/Zapier automation) |
| **Store visibility** | Keep [actor.json](https://docs.apify.com/platform/actors/development/actor-definition/actor-json) strong: `title`, `description`, and `readme` affect how you appear in the Apify Store and search |

**Quick links:** Copy-paste posts, channels, and a weekly checklist → [PROMOTION.md](PROMOTION.md).

***

### Integration

- **Make (Integromat)** — Use the Apify module and select this Actor; map your prompt to the **Prompt** input.
- **Zapier** — Use the Apify Zapier app and choose "Run Actor"; select this Actor and pass the prompt.
- **Custom apps** — Call the Apify API (`/run` or `/run-sync`) with the same input JSON.

***

### Technical details

- **Runtime:** Node.js (see [Dockerfile](Dockerfile)).
- **Input:** Validated against the input schema; invalid input returns a clear error.
- **External API:** Uses MultipleWords floor plan API (`prompt_to_autocad`); failures are retried with exponential backoff.
- **Output schema:** Defined in `.actor/output_schema.json` so the Output tab shows organized tables and links.

***

### FAQ

**How long does a run take?**\
Usually 1–2 minutes for a single prompt; the external API performs the actual generation.

**Can I run multiple prompts in one go?**\
Yes. Send one prompt per run, or trigger multiple runs via API or automation tools for batch generation.

**Where is the image stored?**\
The image is hosted by the upstream API. The Actor returns the URL; you can download or hotlink it.

**Do I need an API key for the floor plan API?**\
The Actor uses its own integration; you only need your Apify account and (for API calls) your Apify API token.

**What is the output schema?**\
The [output schema](https://docs.apify.com/platform/actors/development/actor-definition/output-schema) defines how results appear in the Apify Console Output tab (overview table, detailed view, full dataset), so users see clear field names and types instead of raw JSON.

***

### Resources

- [Apify Console](https://console.apify.com) — Run the Actor and view datasets
- [Apify API](https://docs.apify.com/api/v2) — Run actors programmatically
- [Actor output schema](https://docs.apify.com/platform/actors/development/actor-definition/output-schema) — Define and present Actor output
- [PROMOTION.md](PROMOTION.md) — How to promote this Actor and grow your user base

# Changelog

This Actor's version history is a separate document: https://apify.com/calm_necessity/ai-floor-planner/changelog.md

# Actor input Schema

## `prompt` (type: `string`):

Text prompt describing the floor plan to generate (e.g., 'Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom.')

## Actor input object example

```json
{
  "prompt": "Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom."
}
```

# Actor output Schema

## `floorPlans` (type: `string`):

Dataset view: status, image URL, link, timestamp, and details

## `detailed` (type: `string`):

Dataset view with flattened fields: ID, prompt, job status, description, timestamps

## `dataset` (type: `string`):

Complete dataset (all fields) as JSON

# 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 = {
    "prompt": "Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom."
};

// Run the Actor and wait for it to finish
const run = await client.actor("calm_necessity/ai-floor-planner").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 = { "prompt": "Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom." }

# Run the Actor and wait for it to finish
run = client.actor("calm_necessity/ai-floor-planner").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 '{
  "prompt": "Generate a simple 2-bedroom apartment with a living room, kitchen, and bathroom."
}' |
apify call calm_necessity/ai-floor-planner --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,calm_necessity/ai-floor-planner"
        }
    }
}
```

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/f4qICZA6MS9lwLccr/builds/4gr8yDiaZSuPZCEj9/openapi.json
