# East Baton Rouge Contracts - Vendor Diversity & Line Items (`j0401/ebr-contracts`) Actor

East Baton Rouge Parish purchase orders and contracts (~92,200 documents, $3.4bn): who won what, from which department, for how much, plus each vendor's diversity classification and the line items behind any document.

- **URL**: https://apify.com/j0401/ebr-contracts.md
- **Developed by:** [Wenhao Yang](https://apify.com/j0401) (community)
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.03 / 1,000 east baton rouge purchase order / contract records

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

## East Baton Rouge Contracts - Purchase Orders, Vendors & Diversity

Every purchase order and contract the City of Baton Rouge and East Baton Rouge
Parish have issued, straight from the City-Parish's own open data portal.
**~92,200 documents totalling ~$3.39bn**, with **~341,600 rows including the
line items behind them** (measured 2026-09-28), from 2002 to this week - and
growing weekly, because this is a live feed.

### Low cost

**From $0.00005 per record, down to $0.00003 at Gold.** Pay only for the
records you actually receive - the whole register stays queryable, you are
never billed for the scan behind it.

### What you get

- **Which document** - the document number, the type (Public Works,
  Professional Services, General, Blanket, Lease, RFP/Bid, ), the kind
  (purchase order or contract) and the status, plus the requisition it came from
- **Who** - the vendor name, its address, and the vendor's class, type and status
- **How much** - the document total, the amount actually vouched, and the item
  count
- **Which department** - the buying department and the cost centre, both by
  name and by number
- **When** - the document date, plus the contract's start, expiration and
  extension dates where it has them
- **The supplier's diversity classification** - eleven clean Y/N flags:
  minority-owned, disadvantaged (DBE), disabled-veteran, small-disabled-veteran
  and independent-contractor, plus the small-business variants for minority,
  minority-woman, disadvantaged, veteran, woman and non-minority - and the
  vendor's gender and ethnicity where the Parish records them
- **The line items** - for each document, the item description, quantity, unit
  of measure, unit cost and total cost, with the commodity code and description
  and the expense type

### Modes

- **documents** (default) - one row per purchase order or contract
- **lines** - one row per line item behind those documents
- **aggregate** - counts by department, document type, document status, vendor state or
  vendor class

### Filters

Document number, requisition number, vendor name, department, cost centre,
document type, status, vendor class / state / city, commodity code, item
description, an amount range, a true document-date range, and all eleven
vendor-diversity flags (each takes Y, N or blank).

### Example inputs

**Large public-works awards**

```json
{ "documentType": "Public Works", "minAmount": 1000000, "maxResults": 25 }
```

**Minority-owned vendor awards this year**

```json
{ "minorityOwned": "Y", "inputFrom": "2026-01-01", "maxResults": 50 }
```

**Woman-owned small business, in one department**

```json
{ "smallWomanOwned": "Y", "department": "TRAN" }
```

**Everything one vendor has been awarded**

```json
{ "vendorName": "GRAINGER", "maxResults": 100 }
```

**The line items behind one contract**

```json
{ "documentNumber": "800007099", "mode": "lines" }
```

**Spend by department**

```json
{ "mode": "aggregate", "groupBy": "department" }
```

### Example output

**One contract header** - `documentNumber=800007099`, `mode=documents`:

```json
{
 "platform": "ebr-contracts",
 "source": "east-baton-rouge-parish-contracts",
 "mode": "documents",
 "recordType": "document",
 "groupKey": "",
 "groupCount": "",
 "groupBy": "",
 "recordKind": "H",
 "documentNumber": "800007099",
 "documentType": "Public Works",
 "documentKind": "C",
 "documentTypeCode": "13",
 "documentStatus": "Posted",
 "documentStatusCode": "8",
 "description": "PLANK RD CORRIDOR SEG 2-DAWSON DR-HARDING)",
 "requisitionNumber": "1943",
 "inputDate": "2026-09-25",
 "totalAmount": "2571147.43",
 "vouchedAmount": "1389033.8",
 "annualContractRef": "",
 "totalItems": "3",
 "estimatedStartDate": "2025-06-06",
 "initialExpirationDate": "2026-04-14",
 "extendedThroughDate": "2026-05-10",
 "departmentNumber": "7120",
 "department": "TRAN & DRAIN",
 "costCenter": "7120",
 "costCenterName": "ENGINEERING",
 "vendorName": "COMMAND CONSTRUCTION INDUSTRIES LLC",
 "vendorName2": "",
 "vendorCity": "METAIRIE",
 "vendorState": "LA",
 "vendorZip": "70002",
 "vendorType": "CONVERSION",
 "vendorStatus": "A",
 "vendorClass": "",
 "vendorGender": "FEMALE",
 "vendorEthnicity": "ETHNICITY NOT SPECIFIED",
 "vendorGeographicCode": "INS",
 "minorityOwned": "N",
 "disadvantagedOwned": "Y",
 "disabledVeteranOwned": "N",
 "smallDisabledVeteran": "N",
 "smallMinorityOwned": "N",
 "smallMinorityWomanOwned": "N",
 "smallDisadvantagedOwned": "N",
 "smallVeteranOwned": "N",
 "smallWomanOwned": "Y",
 "smallNonMinorityOwned": "N",
 "independentContractor": "N",
 "itemNumber": "0",
 "itemDescription": "",
 "itemQuantity": "",
 "itemUnitOfMeasure": "",
 "itemUnitCost": "",
 "itemTotalCost": "",
 "commodityCode": "",
 "commodityDescription": "",
 "expenseType": "",
 "expenseTypeDescription": "",
 "sourceUpdatedAt": "2026-09-27"
}
```

**A line item** - the same document, `mode=lines`. The key set is identical to
the row above; the header-only fields come back empty and the item fields are
filled:

```json
{
 "mode": "lines",
 "recordType": "line",
 "recordKind": "D",
 "documentNumber": "800007099",
 "documentType": "Public Works",
 "itemNumber": "1",
 "itemDescription": "**PER RESOLUTION 58599 PLANK ROAD CORRIDOR ENHANCEMENT **",
 "itemQuantity": "1",
 "itemUnitOfMeasure": "JOB",
 "itemUnitCost": "2257313.5",
 "itemTotalCost": "2257313.5",
 "commodityCode": "91327",
 "commodityDescription": "CONSTRUCTION, HIGHWAY AND ROAD",
 "totalAmount": "0",
 "totalItems": "1",
 "vouchedAmount": "",
 "vendorName": "COMMAND CONSTRUCTION INDUSTRIES LLC",
 "disadvantagedOwned": "Y",
 "smallWomanOwned": "Y"
}
```

**`mode=aggregate`, `groupBy=department`** - one count row per department:

```
FLEET        32,324
ENV SERV     11,273
BLDG&GROUND   7,029
BUSINESS OPS  5,668
EMS           5,665
DHDS          4,532
POLICE        4,028
```

### Notes on the data, from the source

- **This table is two grains in one, and the actor never mixes them.** The rows
  marked `H` are the document headers; the ones marked `D` are the line items.
  Measured at ~92,200 headers against ~249,400 detail rows, the header count
  equals the distinct document count exactly - **there is one header per
  document and never two** - and the detail rows cover all but about 20 of
  those documents. `mode=documents` serves the headers (what you mean by "a
  contract") and `mode=lines` serves the items.
- **The money does not overlap between the two grains.** `totalAmount` is the
  document total and carries a value on header rows only - on **every** detail
  row it is exactly 0, and a line's own money is in `itemTotalCost`. Reading
  the two together would double-count or zero out depending on the row, so
  `minAmount` / `maxAmount` filter the document total on the header grain.
- **About $3.39bn of documents, $1.75bn vouched** (measured 2026-09-28). No
  header carries a negative amount; a few dozen are exactly zero.
- **A requisition is usually released as several documents.** The documents
  hang off roughly 18,200 distinct requisitions.
- **The diversity flags count documents, not line items.** A detail row repeats
  its document's flags, so the whole-table counts run 2-5x higher than the
  document counts - 2,405 woman-owned small-business *documents* against 8,540
  flag-carrying *rows*. Every figure quoted here and in the input descriptions
  is the **document (header) count**, which is what this actor's default mode
  returns: 2,557 minority-owned, 1,009 disadvantaged, 24 disabled-veteran,
  1,060 small-minority, 1,674 small-minority-woman, 440 small-disadvantaged,
  574 small-veteran, 2,405 small-woman, 82 small-non-minority and 3,247
  independent-contractor documents.
- **The vendor profile is not complete, and the gaps are normal.** The vendor
  class is on about 48% of documents, gender on 29%, ethnicity on 34% and the
  geographic code on 57% - they exist only for vendors with a profile on file.
  Blank means "not recorded", not "not applicable".
- **`annualContractRef` is a document number, not a yes/no flag** despite the
  source's column name ("ANNUAL CONTRACT"). Populated on roughly 12,870
  documents, it names the annual contract the order draws against. It is
  carried but is not offered as a filter, because it is an opaque number a
  caller cannot know in advance.
- **The contract-term dates exist only for contracts proper**, not for ordinary
  purchase orders: of the ~92,200 documents this actor returns, 3,961 carry a
  start date, 3,885 an initial-expiration date and 515 an extension date -
  about **4.3%, 4.2% and 0.6%** of documents (1.16%, 1.14% and 0.15% of all
  341,621 rows). The document date (`inputDate`, 2002-07-12 to today) is the one
  date on every row, and the only date range offered as a filter.
- **A handful of documents carry no vendor name and no diversity flag** (6 rows
  measured 2026-09-28); one header has no department.
- **The source spreads the document type over three columns** - a one-letter
  kind (`P` purchase order / `C` contract), a short code, and a readable label.
  The readable label is what `documentType` returns and what the filter
  matches, so the field and the filter mean the same thing; the letter and code
  are carried alongside as `documentKind` and `documentTypeCode`.
- Invalid filter inputs (a `%` in a search, a non-numeric document number, a
  flag that is not Y or N, a malformed date) are rejected rather than passed to
  the source.

### Coverage and freshness

East Baton Rouge Parish purchase orders and contracts, kept current by the
City-Parish on a live feed - a new document lands within days, so counts quoted
here are a dated snapshot rather than a fixed total. The newest document date
at the time of writing was 2026-09-26. Every record carries `sourceUpdatedAt`;
the actor also carries a count guard, a whole-corpus field-coverage guard and a
**grain guard** that verifies the one-header-per-document assumption on every
default run, so a source that collapses or changes shape fails loudly instead
of returning an empty page as success.

# Actor input Schema

## `mode` (type: `string`):

documents = one row per purchase order or contract (default). lines = one row per line item. aggregate = one count row per group (see groupBy).

## `documentNumber` (type: `string`):

Exact document number, e.g. '800007099'. Blank = any.

## `requisitionNumber` (type: `string`):

Exact requisition number. One requisition is usually released as several documents. Blank = any.

## `vendorName` (type: `string`):

Vendor name substring, e.g. 'DELL' or 'GRAINGER'. Blank = any.

## `department` (type: `string`):

Buying department substring, e.g. 'POLICE', 'FLEET', 'TRAN'. Blank = any.

## `costCenterName` (type: `string`):

Cost centre name substring. Blank = any.

## `documentType` (type: `string`):

Substring, e.g. 'Public Works', 'Professional Serv', 'Blanket', 'Normal'.

## `status` (type: `string`):

Substring, e.g. 'Closed' (the common case), 'Posted', 'Printed', 'Approved'. Blank = any.

## `vendorClass` (type: `string`):

Exact vendor class code, e.g. 'CORP', 'LLC', 'PSHP'. Populated on about half the documents. Blank = any.

## `vendorState` (type: `string`):

Two-letter vendor state, e.g. 'LA'. About 70% of documents go to an in-state vendor. Blank = any.

## `vendorCity` (type: `string`):

Vendor city substring. Blank = any.

## `commodityCode` (type: `string`):

Commodity code prefix, matched against line items. Blank = any.

## `itemDescription` (type: `string`):

Line-item description substring, matched against line items. Blank = any.

## `minAmount` (type: `number`):

Lowest document total, inclusive. Leave blank for any.

## `maxAmount` (type: `number`):

Highest document total, inclusive. Leave blank for any.

## `inputFrom` (type: `string`):

Earliest document input date (YYYY-MM-DD). Blank = any.

## `inputTo` (type: `string`):

Latest document input date (YYYY-MM-DD), inclusive. Blank = any.

## `minorityOwned` (type: `string`):

Supplier diversity flag (2,557 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `disadvantagedOwned` (type: `string`):

Supplier diversity flag (1,009 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `disabledVeteranOwned` (type: `string`):

Supplier diversity flag (24 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallDisabledVeteran` (type: `string`):

Supplier diversity flag (102 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallMinorityOwned` (type: `string`):

Supplier diversity flag (1,060 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallMinorityWomanOwned` (type: `string`):

Supplier diversity flag (1,674 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallDisadvantagedOwned` (type: `string`):

Supplier diversity flag (440 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallVeteranOwned` (type: `string`):

Supplier diversity flag (574 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallWomanOwned` (type: `string`):

Supplier diversity flag (2,405 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `smallNonMinorityOwned` (type: `string`):

Supplier diversity flag (82 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `independentContractor` (type: `string`):

Supplier diversity flag (3,247 documents marked Y). Y = only those flagged, N = only those not flagged. Blank = any.

## `maxResults` (type: `integer`):

Maximum records to return in documents/lines mode (1-10000). Default 50.

## `groupBy` (type: `string`):

aggregate mode only: the dimension to count by.

## Actor input object example

```json
{
  "mode": "documents",
  "documentNumber": "",
  "requisitionNumber": "",
  "vendorName": "",
  "department": "",
  "costCenterName": "",
  "documentType": "",
  "status": "",
  "vendorClass": "",
  "vendorState": "",
  "vendorCity": "",
  "commodityCode": "",
  "itemDescription": "",
  "inputFrom": "",
  "inputTo": "",
  "minorityOwned": "",
  "disadvantagedOwned": "",
  "disabledVeteranOwned": "",
  "smallDisabledVeteran": "",
  "smallMinorityOwned": "",
  "smallMinorityWomanOwned": "",
  "smallDisadvantagedOwned": "",
  "smallVeteranOwned": "",
  "smallWomanOwned": "",
  "smallNonMinorityOwned": "",
  "independentContractor": "",
  "maxResults": 50,
  "groupBy": "department"
}
```

# Actor output Schema

## `recordsUrl` (type: `string`):

East Baton Rouge purchase orders and contracts - as JSON

## `datasetUrl` (type: `string`):

No description

## `runUrl` (type: `string`):

No description

# API

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

## JavaScript example

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

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

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("j0401/ebr-contracts").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 = {}

# Run the Actor and wait for it to finish
run = client.actor("j0401/ebr-contracts").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 '{}' |
apify call j0401/ebr-contracts --silent --output-dataset

```

## MCP server setup

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

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/9K0HpUvV56AFCvpvZ/builds/wdWAJucWEbgtrDXld/openapi.json
