# 13-Week Cash Runway Model (`bloom-consulting/cash-runway-13-week`) Actor

Build a 13-week direct cash-flow forecast in base, best and worst scenarios. Reports the lowest cash week, the week cash runs out and the gap to close, as a cash card, an HTML/PDF report and an Excel model. English and Turkish.

- **URL**: https://apify.com/bloom-consulting/cash-runway-13-week.md
- **Developed by:** [Bloom Consulting](https://apify.com/bloom-consulting) (community)
- **Stats:** 2 total users, 1 monthly users, 0.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

Pay per usage

This Actor is paid per platform usage. The Actor is free to use, and you only pay for the Apify platform usage, which gets cheaper the higher subscription plan you have.

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

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

## 13-Week Cash Runway Model

The 13-week direct cash-flow forecast is the standard tool for answering the only question that kills companies: **when does the cash run out, and how much do I need to find before then?**

This Actor builds one from a plain description of your opening cash, expected collections and expenses — in **base, best and worst** scenarios — and hands back a cash card, a full report and an Excel model you can keep working in.

No API keys, no LLM calls, no data sent anywhere. The model is deterministic arithmetic, and every week's figure traces back to the line item that produced it.

### What it does

- Lays out **13 weeks** from a start date, week by week.
- Places collections on the weeks they are expected: a steady weekly amount, named customers on specific weeks, or both.
- Places expenses by frequency: **monthly** (on a payment day), **weekly**, **variable** (a share of that week's collections) or **one-off** (on a given week).
- Runs three scenarios by applying multipliers to collections and expenses, plus a collection delay in weeks.
- Reports, for each scenario: closing cash per week, the **lowest cash week**, the **week cash runs out**, runway in months, and two funding gaps — how much you need to bring in to stay **above zero** and to stay **above your safety threshold**.
- Compares plan against actuals for the weeks you have already lived through.

### What you get

Every run writes these to the run's key-value store:

| File | What it is |
| --- | --- |
| `cash-card.md` | One-screen summary: lowest cash week, depletion week, gap to close |
| `report.html` | Full report — weekly table per scenario, line-item breakdown, plan vs actual |
| `report.pdf` | The same report, print-ready |
| `model.xlsx` | The 13-week model as a spreadsheet you can keep editing |
| `data.json` | Every weekly figure and metric as structured data |
| `input.json` | The exact model the engine used |

The dataset row carries minimum cash, the week it occurs, the depletion week and the full metric set for all three scenarios.

### Input

Tick **Run with sample data** for a full example run before you enter anything.

Otherwise fill **Cash model**. Field names can be English or Turkish. `openingCash` is the only required field.

```json
{
  "company": "Example Technology Inc.",
  "currency": "USD",
  "startDate": "2026-09-07",
  "openingCash": 2400000,
  "availableCreditLine": 750000,
  "collections": [
    {"customer": "Customer A (monthly invoice)", "weeks": {"2": 620000, "6": 620000, "11": 620000}},
    {"customer": "Customer B (project payment)", "weeks": {"8": 900000}},
    {"customer": "Other customers (every week)", "weekly": 300000}
  ],
  "otherInflows": [
    {"item": "Grant payment", "week": 9, "amount": 250000}
  ],
  "expenses": [
    {"item": "Payroll and social security", "amount": 1150000, "frequency": "monthly", "paymentDay": 5},
    {"item": "Rent", "amount": 180000, "frequency": "monthly", "paymentDay": 1},
    {"item": "Marketing", "amount": 45000, "frequency": "weekly"},
    {"item": "Supplier payments", "rate": 0.22, "frequency": "variable"},
    {"item": "Annual insurance premium", "amount": 90000, "frequency": "one-off", "week": 7}
  ],
  "scenarios": {
    "base":  {"collectionMultiplier": 1.00, "expenseMultiplier": 1.00, "collectionDelayWeeks": 0},
    "best":  {"collectionMultiplier": 1.10, "expenseMultiplier": 0.97, "collectionDelayWeeks": 0},
    "worst": {"collectionMultiplier": 0.80, "expenseMultiplier": 1.05, "collectionDelayWeeks": 2}
  },
  "thresholdWeeks": 4,
  "pastMonthlyNetCash": [-310000, -280000, -350000],
  "actuals": {
    "1": {"inflow": 280000, "outflow": 125000}
  }
}
```

Notes:

- **`startDate`** is the first day of week 1. A Monday keeps the weeks aligned with how people talk about them.
- **Weeks are numbered 1-13** everywhere, including the `weeks` map on a collection and the `week` on a one-off expense.
- **`frequency`** accepts `monthly`, `weekly`, `variable`, `one-off` (or the Turkish `aylik`, `haftalik`, `degisken`, `tek`).
- **`rate`** on a variable expense is a fraction, not a percentage: `0.22` means 22% of that week's collections.
- **`thresholdWeeks`** is your safety floor — how many weeks of expenses you never want to drop below. The funding gap is measured against it.
- **`actuals`** are optional; supply what has already happened and the report adds a plan-vs-actual view.
- Instead of the JSON field you can pass **Input file URL** — a public link to a JSON file with the same model.

### Report language

`language: "en"` or `"tr"`. Every output — cash card, HTML, PDF, spreadsheet — is produced in the chosen language.

### Typical uses

- **Founders raising** — know the exact week you must close by, and show investors you know it.
- **Founders not raising** — see which expense line or collection date actually moves the depletion week.
- **CFOs and controllers** — a repeatable weekly cash meeting artefact instead of a spreadsheet nobody trusts.
- **Investors and boards** — ask a portfolio company for this output and compare like with like.

### Cost

The Actor is free to use; you pay only Apify platform usage for the run. A run takes roughly 15-40 seconds, most of it PDF rendering. Turn **Generate PDF** off for the cheapest possible run.

### Limits and honesty

- A 13-week model is a **planning instrument**, not a promise. Its quality is entirely the quality of your collection assumptions.
- The worst-case scenario is only as pessimistic as the multipliers you set. If collections have ever collapsed harder than your `worst`, the model is not showing you the real downside.
- It models cash movements, not accounting profit. Cash-positive and loss-making at the same time is normal and expected here.

### About

Built by **Bloom Consulting**, a fractional CFO practice working with startups and SMEs. The [paid desktop edition](https://bloomconsulting.com.tr/paketler?utm_source=apify\&utm_medium=store\&utm_campaign=pusula\&utm_content=readme-paid#ajanlar) adds rolling week-over-week comparison, longer horizons and branded report templates.

- Web: [bloomconsulting.com.tr](https://bloomconsulting.com.tr/?utm_source=apify\&utm_medium=store\&utm_campaign=pusula\&utm_content=readme-footer)
- Contact: iletisim@bloomconsulting.com.tr

Found a bug or want a feature? Open an issue on the Actor page.

# Actor input Schema

## `useSampleData` (type: `boolean`):

Ignore the fields below and run on a built-in example company. Use this first to see what the model looks like. Reports produced this way are stamped DEMO.

## `cashModel` (type: `object`):

Weeks are numbered 1-13; week 1 begins on startDate (a Monday is recommended). English and Turkish field names are both accepted. Collections: use "weekly" for a steady amount every week, or "weeks" for amounts landing on specific week numbers. Expenses: frequency is monthly (with paymentDay), weekly, variable (rate = share of that week's collections) or one-off (with week). openingCash is required; everything else is optional.

## `inputFileUrl` (type: `string`):

Alternative to the field above: a public http(s) URL of a JSON file holding the same model. Used only when "Cash model" is empty.

## `companyName` (type: `string`):

Overrides the company name inside the model. Leave empty to keep it.

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

Language of the cash card, HTML report, PDF and spreadsheet.

## `generatePdf` (type: `boolean`):

Print the HTML report to PDF with headless Chromium. Turn off for a faster, cheaper run.

## Actor input object example

```json
{
  "useSampleData": false,
  "cashModel": {
    "company": "Example Technology Inc.",
    "currency": "USD",
    "startDate": "2026-09-07",
    "openingCash": 2400000,
    "availableCreditLine": 750000,
    "collections": [
      {
        "customer": "Customer A (monthly invoice)",
        "weeks": {
          "2": 620000,
          "6": 620000,
          "11": 620000
        }
      },
      {
        "customer": "Customer B (project payment)",
        "weeks": {
          "8": 900000
        }
      },
      {
        "customer": "Other customers (every week)",
        "weekly": 300000
      }
    ],
    "otherInflows": [
      {
        "item": "Grant payment",
        "week": 9,
        "amount": 250000
      }
    ],
    "expenses": [
      {
        "item": "Payroll and social security",
        "amount": 1150000,
        "frequency": "monthly",
        "paymentDay": 5
      },
      {
        "item": "Rent",
        "amount": 180000,
        "frequency": "monthly",
        "paymentDay": 1
      },
      {
        "item": "SaaS and infrastructure",
        "amount": 95000,
        "frequency": "monthly",
        "paymentDay": 15
      },
      {
        "item": "Marketing",
        "amount": 45000,
        "frequency": "weekly"
      },
      {
        "item": "Taxes and withholding",
        "amount": 320000,
        "frequency": "monthly",
        "paymentDay": 26
      },
      {
        "item": "Loan instalment",
        "amount": 210000,
        "frequency": "monthly",
        "paymentDay": 20
      },
      {
        "item": "Supplier payments (share of collections)",
        "rate": 0.22,
        "frequency": "variable"
      },
      {
        "item": "Annual insurance premium",
        "amount": 90000,
        "frequency": "one-off",
        "week": 7
      }
    ],
    "scenarios": {
      "base": {
        "collectionMultiplier": 1,
        "expenseMultiplier": 1,
        "collectionDelayWeeks": 0
      },
      "best": {
        "collectionMultiplier": 1.1,
        "expenseMultiplier": 0.97,
        "collectionDelayWeeks": 0
      },
      "worst": {
        "collectionMultiplier": 0.8,
        "expenseMultiplier": 1.05,
        "collectionDelayWeeks": 2
      }
    },
    "thresholdWeeks": 4,
    "pastMonthlyNetCash": [
      -310000,
      -280000,
      -350000
    ],
    "actuals": {
      "1": {
        "inflow": 280000,
        "outflow": 125000
      }
    }
  },
  "language": "en",
  "generatePdf": true
}
```

# Actor output Schema

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

The cash model: minimum cash and its week, depletion week, funding gap to zero and to the safety threshold, runway, and the base, best and worst case.

## `cashCard` (type: `string`):

One-screen summary: minimum cash, the week cash runs out, the funding gap and the runway.

## `reportHtml` (type: `string`):

The full report, section by section, ready to read in the browser.

## `reportPdf` (type: `string`):

The same report, print-ready.

## `model` (type: `string`):

The full 13-week model with the three scenarios, live formulas included.

## `data` (type: `string`):

Every intermediate figure the report was built from - the audit trail.

# 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 = {
    "cashModel": {
        "company": "Example Technology Inc.",
        "currency": "USD",
        "startDate": "2026-09-07",
        "openingCash": 2400000,
        "availableCreditLine": 750000,
        "collections": [
            {
                "customer": "Customer A (monthly invoice)",
                "weeks": {
                    "2": 620000,
                    "6": 620000,
                    "11": 620000
                }
            },
            {
                "customer": "Customer B (project payment)",
                "weeks": {
                    "8": 900000
                }
            },
            {
                "customer": "Other customers (every week)",
                "weekly": 300000
            }
        ],
        "otherInflows": [
            {
                "item": "Grant payment",
                "week": 9,
                "amount": 250000
            }
        ],
        "expenses": [
            {
                "item": "Payroll and social security",
                "amount": 1150000,
                "frequency": "monthly",
                "paymentDay": 5
            },
            {
                "item": "Rent",
                "amount": 180000,
                "frequency": "monthly",
                "paymentDay": 1
            },
            {
                "item": "SaaS and infrastructure",
                "amount": 95000,
                "frequency": "monthly",
                "paymentDay": 15
            },
            {
                "item": "Marketing",
                "amount": 45000,
                "frequency": "weekly"
            },
            {
                "item": "Taxes and withholding",
                "amount": 320000,
                "frequency": "monthly",
                "paymentDay": 26
            },
            {
                "item": "Loan instalment",
                "amount": 210000,
                "frequency": "monthly",
                "paymentDay": 20
            },
            {
                "item": "Supplier payments (share of collections)",
                "rate": 0.22,
                "frequency": "variable"
            },
            {
                "item": "Annual insurance premium",
                "amount": 90000,
                "frequency": "one-off",
                "week": 7
            }
        ],
        "scenarios": {
            "base": {
                "collectionMultiplier": 1,
                "expenseMultiplier": 1,
                "collectionDelayWeeks": 0
            },
            "best": {
                "collectionMultiplier": 1.1,
                "expenseMultiplier": 0.97,
                "collectionDelayWeeks": 0
            },
            "worst": {
                "collectionMultiplier": 0.8,
                "expenseMultiplier": 1.05,
                "collectionDelayWeeks": 2
            }
        },
        "thresholdWeeks": 4,
        "pastMonthlyNetCash": [
            -310000,
            -280000,
            -350000
        ],
        "actuals": {
            "1": {
                "inflow": 280000,
                "outflow": 125000
            }
        }
    }
};

// Run the Actor and wait for it to finish
const run = await client.actor("bloom-consulting/cash-runway-13-week").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 = { "cashModel": {
        "company": "Example Technology Inc.",
        "currency": "USD",
        "startDate": "2026-09-07",
        "openingCash": 2400000,
        "availableCreditLine": 750000,
        "collections": [
            {
                "customer": "Customer A (monthly invoice)",
                "weeks": {
                    "2": 620000,
                    "6": 620000,
                    "11": 620000,
                },
            },
            {
                "customer": "Customer B (project payment)",
                "weeks": { "8": 900000 },
            },
            {
                "customer": "Other customers (every week)",
                "weekly": 300000,
            },
        ],
        "otherInflows": [{
                "item": "Grant payment",
                "week": 9,
                "amount": 250000,
            }],
        "expenses": [
            {
                "item": "Payroll and social security",
                "amount": 1150000,
                "frequency": "monthly",
                "paymentDay": 5,
            },
            {
                "item": "Rent",
                "amount": 180000,
                "frequency": "monthly",
                "paymentDay": 1,
            },
            {
                "item": "SaaS and infrastructure",
                "amount": 95000,
                "frequency": "monthly",
                "paymentDay": 15,
            },
            {
                "item": "Marketing",
                "amount": 45000,
                "frequency": "weekly",
            },
            {
                "item": "Taxes and withholding",
                "amount": 320000,
                "frequency": "monthly",
                "paymentDay": 26,
            },
            {
                "item": "Loan instalment",
                "amount": 210000,
                "frequency": "monthly",
                "paymentDay": 20,
            },
            {
                "item": "Supplier payments (share of collections)",
                "rate": 0.22,
                "frequency": "variable",
            },
            {
                "item": "Annual insurance premium",
                "amount": 90000,
                "frequency": "one-off",
                "week": 7,
            },
        ],
        "scenarios": {
            "base": {
                "collectionMultiplier": 1,
                "expenseMultiplier": 1,
                "collectionDelayWeeks": 0,
            },
            "best": {
                "collectionMultiplier": 1.1,
                "expenseMultiplier": 0.97,
                "collectionDelayWeeks": 0,
            },
            "worst": {
                "collectionMultiplier": 0.8,
                "expenseMultiplier": 1.05,
                "collectionDelayWeeks": 2,
            },
        },
        "thresholdWeeks": 4,
        "pastMonthlyNetCash": [
            -310000,
            -280000,
            -350000,
        ],
        "actuals": { "1": {
                "inflow": 280000,
                "outflow": 125000,
            } },
    } }

# Run the Actor and wait for it to finish
run = client.actor("bloom-consulting/cash-runway-13-week").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 '{
  "cashModel": {
    "company": "Example Technology Inc.",
    "currency": "USD",
    "startDate": "2026-09-07",
    "openingCash": 2400000,
    "availableCreditLine": 750000,
    "collections": [
      {
        "customer": "Customer A (monthly invoice)",
        "weeks": {
          "2": 620000,
          "6": 620000,
          "11": 620000
        }
      },
      {
        "customer": "Customer B (project payment)",
        "weeks": {
          "8": 900000
        }
      },
      {
        "customer": "Other customers (every week)",
        "weekly": 300000
      }
    ],
    "otherInflows": [
      {
        "item": "Grant payment",
        "week": 9,
        "amount": 250000
      }
    ],
    "expenses": [
      {
        "item": "Payroll and social security",
        "amount": 1150000,
        "frequency": "monthly",
        "paymentDay": 5
      },
      {
        "item": "Rent",
        "amount": 180000,
        "frequency": "monthly",
        "paymentDay": 1
      },
      {
        "item": "SaaS and infrastructure",
        "amount": 95000,
        "frequency": "monthly",
        "paymentDay": 15
      },
      {
        "item": "Marketing",
        "amount": 45000,
        "frequency": "weekly"
      },
      {
        "item": "Taxes and withholding",
        "amount": 320000,
        "frequency": "monthly",
        "paymentDay": 26
      },
      {
        "item": "Loan instalment",
        "amount": 210000,
        "frequency": "monthly",
        "paymentDay": 20
      },
      {
        "item": "Supplier payments (share of collections)",
        "rate": 0.22,
        "frequency": "variable"
      },
      {
        "item": "Annual insurance premium",
        "amount": 90000,
        "frequency": "one-off",
        "week": 7
      }
    ],
    "scenarios": {
      "base": {
        "collectionMultiplier": 1,
        "expenseMultiplier": 1,
        "collectionDelayWeeks": 0
      },
      "best": {
        "collectionMultiplier": 1.1,
        "expenseMultiplier": 0.97,
        "collectionDelayWeeks": 0
      },
      "worst": {
        "collectionMultiplier": 0.8,
        "expenseMultiplier": 1.05,
        "collectionDelayWeeks": 2
      }
    },
    "thresholdWeeks": 4,
    "pastMonthlyNetCash": [
      -310000,
      -280000,
      -350000
    ],
    "actuals": {
      "1": {
        "inflow": 280000,
        "outflow": 125000
      }
    }
  }
}' |
apify call bloom-consulting/cash-runway-13-week --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,bloom-consulting/cash-runway-13-week"
        }
    }
}
```

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/2D7mYiyccG0in1yfM/builds/t6oQDa6cjuyJilp7B/openapi.json
