# Los Angeles Open Data Scraper (`parseforge/la-open-data-scraper`) Actor

Scrape any Los Angeles Open Data dataset via Socrata SODA API. Crime, business taxes, building permits, parking, 311 service requests and more. No API key required.

- **URL**: https://apify.com/parseforge/la-open-data-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** Business, Developer tools, Automation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $26.02 / 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.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

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

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

![ParseForge Banner](https://github.com/ParseForge/apify-assets/blob/ad35ccc13ddd068b9d6cba33f323962e39aed5b2/banner.jpg?raw=true)

## 🌴 Los Angeles Open Data Scraper

> 🚀 **Export any Los Angeles Open Data dataset in seconds.** Tap **361 published datasets** including crime data, building and safety permits, business registrations, MyLA311 service requests, parking citations, traffic collisions, payroll, and more, via the official Socrata SODA API. No API key, no registration.

> 🕒 **Last updated:** 2026-05-13 · **📊 Native dataset schema** per record · **🗂️ 361 datasets** · **🌴 City of Los Angeles** · **🔌 Socrata SODA API**

The **Los Angeles Open Data Scraper** is a universal export tool for **every dataset on data.lacity.org**. The City of Los Angeles publishes **361 datasets** covering public safety, transportation, finance, planning, economic development, and recreation. This Actor lets you pull any of them by passing the Socrata 4x4 dataset ID, optionally adding SoQL filters (`$where`, `$select`, `$order`, `$q`), and downloading the result as CSV, Excel, JSON, or XML.

The catalog spans **every major LA civic data set**, including crime data from 2020 to present (`2nrs-mtv8`), the 2010-2019 crime archive (`63jg-8b9z`), building and safety permits (`nbyu-2ha9`), MyLA311 service requests (`7my7-7vrt`), parking citations (`pvwu-3di3`), traffic collisions (`6rrh-rzua`), active business registrations (`nxs9-385f`), city payroll, and many more. Output preserves the dataset's native schema and appends three metadata fields: `_datasetId`, `_datasetUrl`, and `_scrapedAt`.

| 🎯 Target Audience | 💡 Primary Use Cases |
|---|---|
| Civic researchers, journalists, prop-tech startups, GIS engineers, data scientists, public safety analysts, real-estate firms, urban planners, students | Civic dashboards, FOIA-style export, permit/business feeds, crime and 311 monitoring, journalism investigations, ML training data on municipal events |

---

### 📋 What the LA Open Data Scraper does

Four filtering knobs map straight to Socrata SoQL:

- 🆔 **Dataset selector.** Pick any of **361 datasets** by 4x4 ID. Find IDs in the URL of any dataset page on `data.lacity.org`.
- 🔍 **WHERE clause.** Standard SoQL `$where`, e.g. `crm_cd_desc='BURGLARY' AND date_occ>'2026-01-01'`.
- 📋 **SELECT clause.** Limit returned columns via `$select`.
- 📈 **ORDER clause.** Sort with `$order`, e.g. `date_occ DESC`.
- 🔎 **Full-text search.** Free-text `$q` across all string columns.

Each record returns the dataset's native columns verbatim (with Socrata's internal `:@computed_region_*` lookup columns stripped to keep the output clean), plus three appended metadata fields: `_datasetId`, `_datasetUrl`, and `_scrapedAt`. Pagination is automatic and capped at 1,000,000 rows.

> 💡 **Why it matters:** Los Angeles publishes one of the largest municipal open-data catalogs in the country, but the SODA API has its own query language, paging quirks, and computed-region noise. This Actor turns that into a clean, paginated export with no Socrata code on your side.

---

### 🎬 Full Demo

_🚧 Coming soon: a 3-minute walkthrough showing how to go from sign-up to a downloaded LA dataset._

---

### ⚙️ Input

<table>
<thead>
<tr><th>Input</th><th>Type</th><th>Default</th><th>Behavior</th></tr>
</thead>
<tbody>
<tr><td><code>datasetId</code></td><td>enum (4x4)</td><td><code>"vygi-vxyg"</code></td><td>Socrata 4x4 ID. Required. Enumerates all <strong>361 datasets</strong> published on data.lacity.org.</td></tr>
<tr><td><code>maxItems</code></td><td>integer</td><td><code>10</code></td><td>Records to return. Free plan caps at 10, paid plan at 1,000,000.</td></tr>
<tr><td><code>where</code></td><td>string (SoQL)</td><td><code>""</code></td><td>Socrata <code>$where</code> filter.</td></tr>
<tr><td><code>select</code></td><td>string (SoQL)</td><td><code>""</code></td><td>Comma-separated columns to return.</td></tr>
<tr><td><code>order</code></td><td>string (SoQL)</td><td><code>""</code></td><td>Sort, e.g. <code>date_occ DESC</code>.</td></tr>
<tr><td><code>query</code></td><td>string</td><td><code>""</code></td><td>Free-text full-text search (Socrata <code>$q</code>).</td></tr>
</tbody>
</table>

**Example: 500 most recent burglaries in 2026.**

```json
{
    "datasetId": "2nrs-mtv8",
    "maxItems": 500,
    "where": "crm_cd_desc='BURGLARY' AND date_occ>'2026-01-01'",
    "order": "date_occ DESC"
}
````

**Example: every building & safety permit issued for new construction in Hollywood.**

```json
{
    "datasetId": "nbyu-2ha9",
    "maxItems": 1000,
    "query": "Hollywood",
    "where": "permit_type='Bldg-New'"
}
```

> ⚠️ **Good to Know:** the input dataset list contains all **361 datasets currently exposed on data.lacity.org**. A small number are private (require Socrata authentication) and will return an HTTP 401 / 403 error record. Browse the full catalog and find the right 4x4 ID at [data.lacity.org](https://data.lacity.org).

***

### 📊 Output

Each record returns the **dataset's native schema verbatim** (Socrata internal `:@computed_region_*` columns are stripped) plus three metadata fields. Download as CSV, Excel, JSON, or XML.

#### 🧾 Schema (illustrative for crime dataset `2nrs-mtv8`)

| Field | Type | Example |
|---|---|---|
| 🆔 `dr_no` | string | `"211507896"` |
| 📅 `date_rptd` | ISO 8601 | `"2021-04-11T00:00:00.000"` |
| 📅 `date_occ` | ISO 8601 | `"2020-11-07T00:00:00.000"` |
| 🕒 `time_occ` | string | `"0845"` |
| 🚓 `area` / `area_name` | string | `"15" / "N Hollywood"` |
| 🔢 `crm_cd` / `crm_cd_desc` | string | `"354" / "THEFT OF IDENTITY"` |
| 👤 `vict_age` / `vict_sex` / `vict_descent` | string | `"31" / "M" / "H"` |
| 🏠 `premis_desc` | string | `"SINGLE FAMILY DWELLING"` |
| 📋 `status_desc` | string | `"Invest Cont"` |
| 📍 `location` | string | `"7800 BEEMAN AV"` |
| 📍 `lat` / `lon` | string | `"34.2124" / "-118.4092"` |
| 🆔 `_datasetId` | string | `"2nrs-mtv8"` |
| 🔗 `_datasetUrl` | string | `"https://data.lacity.org/d/2nrs-mtv8"` |
| 🕒 `_scrapedAt` | ISO 8601 | `"2026-05-13T10:00:00.000Z"` |

Every dataset has its own column set. The Actor passes through whatever Socrata returns for the dataset you picked.

#### 📦 Sample record (crime data)

<details>
<summary><strong>🚓 N Hollywood identity theft incident, DR 211507896</strong></summary>

```json
{
    "dr_no": "211507896",
    "date_rptd": "2021-04-11T00:00:00.000",
    "date_occ": "2020-11-07T00:00:00.000",
    "time_occ": "0845",
    "area": "15",
    "area_name": "N Hollywood",
    "rpt_dist_no": "1502",
    "crm_cd": "354",
    "crm_cd_desc": "THEFT OF IDENTITY",
    "vict_age": "31",
    "vict_sex": "M",
    "vict_descent": "H",
    "premis_desc": "SINGLE FAMILY DWELLING",
    "status": "IC",
    "status_desc": "Invest Cont",
    "location": "7800    BEEMAN                       AV",
    "lat": "34.2124",
    "lon": "-118.4092",
    "_datasetId": "2nrs-mtv8",
    "_datasetUrl": "https://data.lacity.org/d/2nrs-mtv8",
    "_scrapedAt": "2026-05-13T10:00:00.000Z"
}
```

</details>

***

### ✨ Why choose this Actor

| | Capability |
|---|---|
| 🗂️ | **361 datasets, one Actor.** Every public dataset on data.lacity.org enumerated in the input schema. |
| 🔍 | **Full SoQL filtering.** `$where`, `$select`, `$order`, `$q` exposed as input fields. |
| 🧹 | **Cleaned output.** Socrata `:@computed_region_*` internal columns stripped automatically. |
| 🔗 | **Dataset provenance.** Every record stamped with `_datasetId`, `_datasetUrl`, `_scrapedAt`. |
| ⚡ | **Fast.** 1,000-row pages, automatic pagination up to 1,000,000 rows. |
| 🚫 | **No API key.** The Socrata SODA API is public and unauthenticated for all public datasets. |

> 📊 LA's open-data catalog is one of the most active public-sector data publishers in the country, powering everything from civic-tech projects to academic research.

***

### 📈 How it compares to alternatives

| Approach | Cost | Coverage | Refresh | Filters | Setup |
|---|---|---|---|---|---|
| **⭐ LA Open Data Scraper** *(this Actor)* | $5 free credit, then pay-per-use | **All 361 LA datasets** | **Live per run** | full SoQL ($where, $select, $order, $q) | ⚡ 2 min |
| Manual CSV download from data.lacity.org | Free | One dataset at a time | Snapshot | None | 🐢 Manual |
| Raw Socrata SODA queries | Free | Full | Live | SoQL | 🛠️ Code required |
| Third-party civic-data aggregators | $99+/month | Mixed | Daily | Vendor-defined | ⏳ Hours |

Pick this Actor when you want a clean, filtered export of any LA dataset without writing a single line of Socrata code.

***

### 🚀 How to use

1. 📝 **Sign up.** [Create a free account with $5 credit](https://console.apify.com/sign-up?fpr=vmoqkp) (takes 2 minutes).
2. 🌐 **Open the Actor.** Go to the Los Angeles Open Data Scraper page on the Apify Store.
3. 🎯 **Pick a dataset.** Find the 4x4 ID on `data.lacity.org` (it's in every dataset URL) and paste it in.
4. 🔍 **Add optional filters.** Type a SoQL `$where`, `$order`, `$select`, or full-text `$q` if you want a slice.
5. 🚀 **Run it.** Click **Start** and let the Actor collect your data.
6. 📥 **Download.** Grab your results in the **Dataset** tab as CSV, Excel, JSON, or XML.

> ⏱️ Total time from signup to downloaded dataset: **3-5 minutes.** No coding required.

***

### 💼 Business use cases

<table>
<tr>
<td width="50%" valign="top">

#### 🏢 Real Estate and Construction

- Track every LA Department of Building and Safety permit
- Monitor business registrations by SIC code and ZIP
- Comparable cost analysis for development bids
- Tenant-mix research with active business filings

</td>
<td width="50%" valign="top">

#### 🚓 Public Safety and Insurance

- Build crime-density dashboards by LAPD area
- Underwrite policies with live incident data
- Risk-score parcels with traffic-collision history
- Track MyLA311 service-request volume per district

</td>
</tr>
<tr>
<td width="50%" valign="top">

#### 🚗 Mobility and Transportation

- Parking-citation density for curbside-pricing models
- Traffic-collision hot spots for route safety
- Permit data for film-shoot road closures
- DOT and street services intelligence

</td>
<td width="50%" valign="top">

#### 🗞️ Journalism and Civic Tech

- Investigate crime trends and reporting gaps
- Quantify business-formation trends year over year
- Build live-updating civic dashboards
- Power newsroom data-explainer features

</td>
</tr>
</table>

***

### 🔌 Automating LA Open Data Scraper

Control the scraper programmatically for scheduled runs and pipeline integrations:

- 🟢 **Node.js.** Install the `apify-client` NPM package.
- 🐍 **Python.** Use the `apify-client` PyPI package.
- 📚 See the [Apify API documentation](https://docs.apify.com/api/v2) for full details.

The [Apify Schedules feature](https://docs.apify.com/platform/schedules) lets you trigger this Actor on any cron interval. Hourly, daily, or weekly refreshes keep downstream databases in sync automatically.

***

### 🌟 Beyond business use cases

Data like this powers more than commercial workflows. The same structured records support research, education, civic projects, and personal initiatives.

<table>
<tr>
<td width="50%">

#### 🎓 Research and academia

- Urban-studies papers on policing, transit, displacement
- Public-health theses with MyLA311 and collision data
- Reproducible policy-impact studies with versioned pulls
- GIS coursework on real municipal datasets

</td>
<td width="50%">

#### 🎨 Personal and creative

- Neighborhood dashboards for your LAPD division
- Side projects mapping every film shoot in LA
- Civic-art and visualization exhibitions
- Hobby trackers for permit pipeline or 311 timing

</td>
</tr>
<tr>
<td width="50%">

#### 🤝 Non-profit and civic

- Public-safety reform orgs analyzing arrest data
- Mutual-aid networks monitoring MyLA311 categories
- Civic-tech hackathons with structured datasets
- Investigative journalism on city-government performance

</td>
<td width="50%">

#### 🧪 Experimentation

- Train classification ML models on 311 narratives
- Prototype agent pipelines that summarize city activity
- Test geocoding and address-normalization toolchains
- Validate civic-tech product hypotheses with live data

</td>
</tr>
</table>

***

### 🤖 Ask an AI assistant about this scraper

Open a ready-to-send prompt about this ParseForge actor in the AI of your choice:

- 💬 [**ChatGPT**](https://chat.openai.com/?q=How%20do%20I%20use%20the%20Los%20Angeles%20Open%20Data%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🧠 [**Claude**](https://claude.ai/new?q=How%20do%20I%20use%20the%20Los%20Angeles%20Open%20Data%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🔍 [**Perplexity**](https://perplexity.ai/search?q=How%20do%20I%20use%20the%20Los%20Angeles%20Open%20Data%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)
- 🅒 [**Copilot**](https://copilot.microsoft.com/?q=How%20do%20I%20use%20the%20Los%20Angeles%20Open%20Data%20Scraper%20by%20ParseForge%20on%20Apify%3F%20Show%20me%20input%20examples%2C%20output%20fields%2C%20common%20use%20cases%2C%20and%20how%20to%20integrate%20it%20into%20a%20workflow.)

***

### ❓ Frequently Asked Questions

#### 🧩 How does it work?

Paste the Socrata 4x4 ID of any LA dataset, optionally add SoQL filters and `maxItems`, click Start, and the Actor pages through the SODA API and emits the records verbatim with three appended metadata fields. No browser automation, no captchas, no setup.

#### 🆔 How do I find a dataset ID?

Browse the catalog at [data.lacity.org](https://data.lacity.org). Every dataset URL ends in a 4x4 ID like `2nrs-mtv8` (crime 2020-present) or `7my7-7vrt` (MyLA311). Paste that ID into the input form.

#### 🗂️ How many datasets are supported?

All **361 datasets currently exposed on data.lacity.org** are enumerated in the input dropdown. New datasets are added by the City regularly; reach out if you need a specific one that isn't yet in the list.

#### 🔍 What is SoQL?

SoQL is Socrata's SQL-like query language for the SODA API. The Actor exposes `$where`, `$select`, `$order`, and `$q` as input fields. Reference docs: [dev.socrata.com](https://dev.socrata.com/docs/queries/). A short cheat sheet: `$where=col='value'`, `$order=col DESC`, `$select=col1,col2`, `$q=search text`.

#### 🧹 Why are some columns missing from the output?

Socrata appends internal `:@computed_region_*` lookup columns to most datasets. These are noise for downstream analytics, so the Actor strips them automatically. Everything else in the dataset's native schema is passed through verbatim.

#### 🔄 How fresh is the data?

The City of Los Angeles updates each dataset on its own cadence (some daily, some weekly, some monthly). Every run of this Actor fetches the latest data available on data.lacity.org as of run time.

#### 🚫 Why did I get a 401 or 403 error?

A small number of datasets are private and require Socrata authentication. The Actor will return a clean `{error: ...}` record indicating which one. Public datasets work without any credentials.

#### ⏰ Can I schedule regular runs?

Yes. Use Apify Schedules to run this Actor on any cron interval (hourly, daily, weekly) and keep a downstream database in sync.

#### 💳 Do I need a paid Apify plan to use this Actor?

No. The free Apify plan is enough for testing and small runs (10 records per run). A paid plan lifts the limit and gives you access to scheduling, higher concurrency, and larger datasets.

#### ⚖️ Is this data legal to use?

Yes. LA Open Data is published under the City of Los Angeles Open Data Policy and is generally free to reuse with attribution. Specific datasets may carry additional notes on their landing page; check before commercial redistribution.

#### 🆘 What if I need help?

Our support team is here to help. Contact us through the Apify platform or use the Tally form linked below.

***

### 🔌 Integrate with any app

LA Open Data Scraper connects to any cloud service via [Apify integrations](https://apify.com/integrations):

- [**Make**](https://docs.apify.com/platform/integrations/make) - Automate multi-step workflows
- [**Zapier**](https://docs.apify.com/platform/integrations/zapier) - Connect with 5,000+ apps
- [**Slack**](https://docs.apify.com/platform/integrations/slack) - Get notified when a new record matches your filters
- [**Airbyte**](https://docs.apify.com/platform/integrations/airbyte) - Pipe LA datasets into your warehouse
- [**GitHub**](https://docs.apify.com/platform/integrations/github) - Trigger runs from commits and releases
- [**Google Drive**](https://docs.apify.com/platform/integrations/drive) - Export datasets straight to Sheets

You can also use webhooks to trigger downstream actions when a run finishes. Push fresh LA civic data into your CRM or analytics backend.

***

### 🔗 Recommended Actors

- [**🌉 San Francisco Open Data Scraper**](https://apify.com/parseforge/sf-open-data-scraper) - Same Socrata pattern, every SF dataset
- [**🏗️ Seattle Building Permits Scraper**](https://apify.com/parseforge/seattle-permits-scraper) - Seattle DCI permits
- [**🏠 Greatschools Scraper**](https://apify.com/parseforge/greatschools-scraper) - U.S. K-12 school ratings
- [**🏛️ James Edition Real Estate Scraper**](https://apify.com/parseforge/james-edition-real-estate-scraper) - Luxury international real estate
- [**📰 PR Newswire Scraper**](https://apify.com/parseforge/pr-newswire-scraper) - Press releases and corporate announcements

> 💡 **Pro Tip:** browse the complete [ParseForge collection](https://apify.com/parseforge) for more public-data scrapers.

***

**🆘 Need Help?** [**Open our contact form**](https://tally.so/r/BzdKgA) to request a new scraper, propose a custom data project, or report an issue.

***

> **⚠️ Disclaimer:** this Actor is an independent tool and is not affiliated with, endorsed by, or sponsored by the City of Los Angeles or Tyler Technologies / Socrata. All trademarks mentioned are the property of their respective owners. Only publicly available open data is collected.

# Actor input Schema

## `datasetId` (type: `string`):

Socrata 4x4 ID of any dataset hosted on data.lacity.org. Find the ID in the dataset URL (e.g. '2nrs-mtv8' for crime data from 2020 to present, 'nbyu-2ha9' for building & safety permits, '7my7-7vrt' for MyLA311 service requests, 'pvwu-3di3' for parking citations, '6rrh-rzua' for traffic collisions).

## `maxItems` (type: `integer`):

Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000

## `where` (type: `string`):

Optional Socrata SoQL $where clause. Example: "crm\_cd\_desc='BURGLARY' AND area\_name='Central'". See https://dev.socrata.com/docs/queries/where.html

## `select` (type: `string`):

Comma-separated list of columns to return. Default: all columns.

## `order` (type: `string`):

Sort order. Example: 'date\_occ DESC' or 'date\_rptd ASC'

## `query` (type: `string`):

Free-text search across all string columns of the dataset

## Actor input object example

```json
{
  "datasetId": "vygi-vxyg",
  "maxItems": 10
}
```

# Actor output Schema

## `overview` (type: `string`):

Overview of scraped data

## `fullData` (type: `string`):

Complete dataset

# 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 = {
    "datasetId": "vygi-vxyg",
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/la-open-data-scraper").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 = {
    "datasetId": "vygi-vxyg",
    "maxItems": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("parseforge/la-open-data-scraper").call(run_input=run_input)

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

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

```

## CLI example

```bash
echo '{
  "datasetId": "vygi-vxyg",
  "maxItems": 10
}' |
apify call parseforge/la-open-data-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=parseforge/la-open-data-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Los Angeles Open Data Scraper",
        "description": "Scrape any Los Angeles Open Data dataset via Socrata SODA API. Crime, business taxes, building permits, parking, 311 service requests and more. No API key required.",
        "version": "0.0",
        "x-build-id": "vEInjwggOBqA0Y6x2"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/parseforge~la-open-data-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-parseforge-la-open-data-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/parseforge~la-open-data-scraper/runs": {
            "post": {
                "operationId": "runs-sync-parseforge-la-open-data-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/parseforge~la-open-data-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-parseforge-la-open-data-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "required": [
                    "datasetId"
                ],
                "properties": {
                    "datasetId": {
                        "title": "Dataset ID (4x4)",
                        "enum": [
                            "nxs9-385f",
                            "fw6y-ht9f",
                            "u3bu-it6d",
                            "f4qm-39q9",
                            "bb9g-p6se",
                            "cq4z-inke",
                            "kkrh-b4e3",
                            "m6qi-ifup",
                            "9tzi-nz7g",
                            "6ux4-qj74",
                            "bpyg-ytsg",
                            "txn4-36ky",
                            "4ca8-mxuh",
                            "kszm-sdw4",
                            "ej2v-yd79",
                            "2qdj-cyiz",
                            "8cmr-fbcu",
                            "qv4c-k9xz",
                            "wjz9-h9np",
                            "46an-wabg",
                            "yru6-6re4",
                            "amvf-fr72",
                            "mbz9-j2zk",
                            "f232-7zb7",
                            "4qmh-sz39",
                            "skve-7mzv",
                            "ybqa-gmkn",
                            "9r7y-tdse",
                            "vygi-vxyg",
                            "xzdy-vzez",
                            "pwhu-m93q",
                            "fc3u-86zh",
                            "qer2-sxr5",
                            "c4sv-pw36",
                            "e67z-kt2n",
                            "dyxf-7hc4",
                            "pi9x-tg5x",
                            "b6ii-mhed",
                            "n3xg-rixm",
                            "gwh9-jnip",
                            "rken-a55j",
                            "u82d-eh7z",
                            "h8me-eag6",
                            "yaaf-cyfa",
                            "ysqd-apz7",
                            "7ts7-nh4y",
                            "9i2c-csvn",
                            "9k3p-zrda",
                            "mcip-sa6g",
                            "5m3t-xjex",
                            "67is-svtd",
                            "vnau-u5ph",
                            "bjvp-eqku",
                            "9rag-xmmd",
                            "q3ak-s5hy",
                            "3f9m-afei",
                            "bsvt-chkv",
                            "8qjh-sbs9",
                            "9w5z-rg2h",
                            "8spw-3fhx",
                            "j7mw-thyc",
                            "5y5q-d9ew",
                            "6qbs-9m8d",
                            "snhr-fa63",
                            "3aii-bde7",
                            "pt99-74gb",
                            "nbre-engz",
                            "6inw-egb2",
                            "b2qw-5tjn",
                            "c9di-tijr",
                            "e2zz-y53s",
                            "kkqy-ryqv",
                            "bdy2-fgym",
                            "5aw2-jx4k",
                            "wkek-kqw4",
                            "kziq-k4au",
                            "c8zs-6yn8",
                            "ckea-5u87",
                            "qwzb-77da",
                            "6rvp-amz7",
                            "ucyn-ru6w",
                            "nwj3-ufba",
                            "brvb-jr45",
                            "m6g2-gc6c",
                            "5mrt-4zhe",
                            "br3a-db9a",
                            "rwwd-gr2c",
                            "4xuf-944h",
                            "adam-59ei",
                            "kcsj-s69p",
                            "9z5d-hgrh",
                            "sw3c-x2hx",
                            "ee5q-u9aq",
                            "4n9f-iihs",
                            "jnwm-mx8g",
                            "jyyg-7bst",
                            "sq3x-ijwy",
                            "63jg-8b9z",
                            "2nrs-mtv8",
                            "8sbu-dvfy",
                            "vdjf-if28",
                            "uj6a-ab47",
                            "5h3p-n236",
                            "az2u-ixwi",
                            "tigc-6qke",
                            "c8jn-ua56",
                            "hnms-4szp",
                            "ax8j-dhzm",
                            "pnat-cnpj",
                            "rjdk-rz7f",
                            "5icv-hrai",
                            "4wd4-uzr6",
                            "8yaq-2fpu",
                            "9hxb-dad7",
                            "4g57-9wbx",
                            "95j2-9tdv",
                            "4a8d-4327",
                            "diev-46hg",
                            "u7aw-ramn",
                            "wn65-h6pe",
                            "xdjq-3qi6",
                            "yhrt-wk8c",
                            "4p38-zay2",
                            "gr27-eza8",
                            "hkig-2qjq",
                            "tfsb-fwmw",
                            "x9tj-p4jm",
                            "rnxp-tz2v",
                            "iz73-c344",
                            "aeva-nfqz",
                            "v5uj-jj3r",
                            "h5ci-ugt3",
                            "ce5i-q2bc",
                            "i5g3-9vuz",
                            "fhm9-882e",
                            "qq5r-inr7",
                            "secn-jf4e",
                            "qpi4-ig3x",
                            "a6cj-i5wu",
                            "8m62-bye6",
                            "acy8-72w9",
                            "qqur-fdui",
                            "9et4-6fpi",
                            "7w5j-7jjp",
                            "3kce-7yuf",
                            "9yda-i4ya",
                            "hi8w-jppr",
                            "r3up-67wh",
                            "6kqv-v7g7",
                            "rnb4-daiw",
                            "6s9d-et82",
                            "e2fp-yzdz",
                            "dw2y-59sj",
                            "k4k6-bwwv",
                            "qrkr-kfbh",
                            "c3g2-yzgc",
                            "m27g-4avd",
                            "6yv9-t9gq",
                            "pdbw-x3k8",
                            "yqyr-2qgp",
                            "29cn-rph9",
                            "2in3-5b7t",
                            "tsrc-szkh",
                            "mkf9-fagf",
                            "3gwn-arjr",
                            "cd49-p4un",
                            "9aw9-mn4p",
                            "pxeu-7j74",
                            "jsff-uc6b",
                            "w9vh-pj9e",
                            "895k-6zuw",
                            "nekp-vn63",
                            "63we-p3wv",
                            "ftgd-xwi4",
                            "822f-gjp4",
                            "ni7t-83qi",
                            "s49e-q6j2",
                            "jp2s-nfz4",
                            "e7h6-4a3e",
                            "cj8s-ivry",
                            "vt7b-3i5m",
                            "94wu-3ps3",
                            "s3st-6nwi",
                            "4ftr-pfem",
                            "hsmw-wwd6",
                            "r95y-gwez",
                            "t24g-hqix",
                            "hmiy-sxh5",
                            "2yrw-q8tw",
                            "m5ec-bb8m",
                            "p8nc-6hdi",
                            "pzs3-fue3",
                            "qyvz-diiw",
                            "n44u-wxe4",
                            "tnz4-ynvq",
                            "mymu-zi3s",
                            "2qnc-kq4g",
                            "5nzp-isg9",
                            "n9x9-zisb",
                            "ds2y-sb5t",
                            "2u8b-eyuu",
                            "eagk-wq48",
                            "vpax-89xu",
                            "ci3m-f23k",
                            "cr8f-uc4j",
                            "ukgg-rgf9",
                            "t6kt-2yic",
                            "iy4q-t9vr",
                            "4tmc-7r6g",
                            "i7pm-cnmm",
                            "urhh-yf63",
                            "mgue-vbsx",
                            "tss8-455b",
                            "xwgr-xw5q",
                            "ryvm-a59m",
                            "nayp-w2tw",
                            "r4ka-x5je",
                            "84iq-i2r6",
                            "cibt-wiru",
                            "u6ri-98iw",
                            "uq7m-rynj",
                            "xjgu-z4ju",
                            "y8y3-fqfu",
                            "k7nn-b2ep",
                            "gqf2-vm2j",
                            "5gp9-8nrb",
                            "bwdf-y5fe",
                            "3d4k-crby",
                            "t8kf-2y96",
                            "97ra-aqza",
                            "a4nt-4gca",
                            "m4ev-cuzz",
                            "utq2-nxpj",
                            "6rrh-rzua",
                            "r4uk-afju",
                            "cu97-7vhd",
                            "ptdy-3ivc",
                            "jg4k-s4ud",
                            "tp35-mfg9",
                            "63kx-necw",
                            "r8xf-vixa",
                            "dik5-hwp6",
                            "tx7r-x3hp",
                            "ajiv-uc63",
                            "d3a2-7j6v",
                            "g3qu-7q2u",
                            "j6u4-c4yh",
                            "ubph-b4it",
                            "7ecf-jj8x",
                            "sii9-rjps",
                            "j5g7-w4y7",
                            "d7jk-ufat",
                            "qf8m-dzta",
                            "w7j2-5kjf",
                            "s2f8-v3rp",
                            "trxm-jn3c",
                            "28qc-63jv",
                            "fvye-93wd",
                            "5242-pnmt",
                            "ih6g-qkwz",
                            "d4kt-8j3n",
                            "qyra-qm2s",
                            "4f5p-udkv",
                            "abxc-9sg7",
                            "4jt3-efvk",
                            "gbbb-cs88",
                            "3qv2-p4kj",
                            "h6ky-vznd",
                            "fdtv-2wce",
                            "ruu2-p7fw",
                            "bywz-284j",
                            "k98w-s24w",
                            "jdgw-bwcf",
                            "v7gk-cxxi",
                            "8yhj-2j8m",
                            "du8q-hww5",
                            "s5jy-jcce",
                            "jmt8-y5rm",
                            "2t3h-my34",
                            "aiix-duyv",
                            "geed-7eey",
                            "i9rh-q5gx",
                            "5a4i-e2zs",
                            "38a8-tm7u",
                            "b3i5-86hy",
                            "xhx7-hr4h",
                            "tsuv-4rgh",
                            "v3my-p6u5",
                            "gvpf-vb3s",
                            "s2gq-nz3r",
                            "46qe-t7np",
                            "krk7-ayq2",
                            "58cg-y94u",
                            "8mwm-e4ge",
                            "6n5x-dymz",
                            "t7bh-zmwj",
                            "im69-zvh3",
                            "x3nt-5eea",
                            "qwem-tyir",
                            "s36s-5b6x",
                            "jktk-4pit",
                            "uawy-cgqg",
                            "bkfc-yqhx",
                            "vxhy-r447",
                            "q3kc-wj3g",
                            "a5vt-xsyi",
                            "hf3r-utnq",
                            "h8mw-iegk",
                            "hc57-9a3j",
                            "msv5-mj8x",
                            "f4qc-fg29",
                            "j4zm-9kqu",
                            "xuce-e6ip",
                            "t5zm-4d79",
                            "29fd-3paw",
                            "ckya-qgys",
                            "s5e6-2pbm",
                            "jqan-regh",
                            "86ry-dcuc",
                            "7dww-jq9x",
                            "57hp-ynj6",
                            "cy8h-q3bu",
                            "rg5w-ui4c",
                            "fgtv-xbci",
                            "4hqz-rxff",
                            "twzm-wihy",
                            "4iim-t2y2",
                            "5sak-hbiy",
                            "hntu-mwxc",
                            "vt5t-mscf",
                            "avzn-825x",
                            "argd-k3xu",
                            "rckt-8prm",
                            "svt7-r3ww",
                            "d5tf-ez2w",
                            "dhqa-6x54",
                            "cbxc-q4bc",
                            "njpj-42dm",
                            "7yet-b6aj",
                            "iv7a-6rrq",
                            "rpp7-mevy",
                            "ci25-wgt7",
                            "45pp-x98f",
                            "xe35-4wsy",
                            "jz5f-87wj",
                            "d3th-bqdk",
                            "jx82-7rs5",
                            "746u-cr6b",
                            "si79-fpzd",
                            "jxqs-eipk",
                            "hwpe-qxka",
                            "nsdh-74d5",
                            "8qhs-wikn",
                            "x5zv-ey8w",
                            "u4wk-p2cm",
                            "8pn8-5zdt",
                            "ddvb-suge",
                            "cuid-a8rp",
                            "hfdw-5uq2",
                            "ikdx-vgub",
                            "jjxn-vhan"
                        ],
                        "type": "string",
                        "description": "Socrata 4x4 ID of any dataset hosted on data.lacity.org. Find the ID in the dataset URL (e.g. '2nrs-mtv8' for crime data from 2020 to present, 'nbyu-2ha9' for building & safety permits, '7my7-7vrt' for MyLA311 service requests, 'pvwu-3di3' for parking citations, '6rrh-rzua' for traffic collisions)."
                    },
                    "maxItems": {
                        "title": "Max Items",
                        "minimum": 1,
                        "maximum": 1000000,
                        "type": "integer",
                        "description": "Free users: Limited to 10 items (preview). Paid users: Optional, max 1,000,000"
                    },
                    "where": {
                        "title": "$where filter (SoQL)",
                        "type": "string",
                        "description": "Optional Socrata SoQL $where clause. Example: \"crm_cd_desc='BURGLARY' AND area_name='Central'\". See https://dev.socrata.com/docs/queries/where.html"
                    },
                    "select": {
                        "title": "$select columns",
                        "type": "string",
                        "description": "Comma-separated list of columns to return. Default: all columns."
                    },
                    "order": {
                        "title": "$order clause",
                        "type": "string",
                        "description": "Sort order. Example: 'date_occ DESC' or 'date_rptd ASC'"
                    },
                    "query": {
                        "title": "$q full-text search",
                        "type": "string",
                        "description": "Free-text search across all string columns of the dataset"
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
