EnergiQ API Documentation

The EnergiQ API provides programmatic access to well data, production history, permits, market prices, and analytics across Colorado, New Mexico, North Dakota, Texas, and West Virginia — covering over 1.6 million well records from COGCC, NM OCD, NDIC, Texas RRC, and WVDEP. All endpoints return JSON.

Data sources: COGCC · CO NDIC · ND RRC · TX NM OCD · NM WVDEP · WV
🆕 Base URL
https://api.flynlochanalytics.com/api
🔒 API Access: The badge on each endpoint shows what the server requires: Public (no token), Signed in (any valid token, including Free), or Pro+ (Pro plan or above; otherwise HTTP 403). Plan limits apply to results per query and exports (see Rate Limits). The EnergiQ web app may present some Signed-in endpoints (for example operator, basin and state detail, and nearby search) as Pro features; the API itself only requires sign-in for them. Your token is shown above once you're signed in.

🔑 Authentication

Requests to Signed in and Pro+ endpoints must include your JWT token in the Authorization header (Public endpoints need none). Obtain your token by logging in via the auth endpoint or copying it from the box above (visible when signed in).

POST /auth/login Public
Obtain a JWT access token. Token is valid for 7 days.
{
  "email":    "user@example.com",
  "password": "yourpassword"
}
{
  "token": "eyJhbGciOiJIUzI1NiIs...",
  "user":  { "id": "...", "email": "...", "name": "...", "role": "pro" }
}

Using the Token

curl https://api.flynlochanalytics.com/api/search/wells?state=TX&basin=Permian+Basin \
  -H "Authorization: Bearer YOUR_TOKEN"
import requests

TOKEN = "your_token_here"
BASE  = "https://api.flynlochanalytics.com/api"
headers = {"Authorization": f"Bearer {TOKEN}"}

# Search Permian Basin wells
r = requests.get(f"{BASE}/search/wells",
    params={"basin": "Permian Basin", "state": "TX", "status": "active", "page": 1},
    headers=headers)
data = r.json()
print(f"{data['total']:,} wells found")

🔍 Wells

GET /data/wells/:id Public
Get full well detail by well ID or API number. No sign-in is required. Returns the well record plus production_preview, public_assignments, formation_tops, completions, casing, frac_disclosures, frac_ingredients and frac_water_sources where available. The data_source field identifies where the well record came from (for example COGCC, NDIC or RRC; wells from other sources carry their own value).
ParameterTypeDescription
:idstringWell ID (internal) or API number, matched exactly as given. Stored API numbers are 12-digit for CO (e.g. 051233676800) and 10-digit for the other states (e.g. 3305301942).

Colorado (COGCC) example

GET /data/wells/051233676800

{
  "well": {
    "id": "e68071da-...",
    "api_number": "051233676800",
    "well_name":  "WELLS RANCH AE #05-63-1HN",
    "operator":   "NOBLE ENERGY INC",
    "state":      "CO",
    "basin":      "DJ Basin",
    "formation":  "NBRR",
    "status":     "active",
    "latitude":   40.51195,
    "longitude": -104.35634,
    "data_source": "COGCC",
    "depth_ft":   11177
  },
  "formation_tops": [
    { "formation": "PIERRE",   "top_ft": 3051, "cored": false },
    { "formation": "NIOBRARA", "top_ft": 6880, "cored": false }
  ],
  "completions": [
    { "completion_date": "2013-04-25", "measured_td_ft": 11177,
      "stages": 20, "total_proppant_lbs": 3472255,
      "ip_oil_bbl": 143, "ip_gas_mcf": 118 }
  ],
  "production_preview": [...]
}

North Dakota (NDIC) example

GET /data/wells/3305301942

{
  "well": {
    "api_number":  "3305301942",
    "well_name":   "CONTINENTAL #5502H",
    "operator":    "CONTINENTAL RESOURCES INC",
    "state":       "ND",
    "basin":       "Williston Basin",
    "formation":   "BAKKEN",
    "status":      "active",
    "data_source": "NDIC",
    "ndic_file_no": "25419",
    "field_name":  "REUNION BAY",
    "cum_oil_bbl": 1204318,
    "ip_oil_bopd": 1981,
    "ip_date":     "2012-06-15"
  },
  "formation_tops": [ ... ],
  "completions":    [ ... ]
}

Texas (RRC) example

GET /data/wells/[tx-well-id]

{
  "well": {
    "api_number":      "42-317-...",
    "well_name":       "PIONEER 1H",
    "operator":        "PIONEER NATURAL RESOURCES",
    "state":           "TX",
    "county":          "Midland",
    "basin":           "Permian Basin",
    "data_source":     "RRC",
    "rrc_lease_no":    "12345",
    "rrc_district_no": "08",
    "status":          "active",
    "latitude":        31.9874,
    "longitude":      -102.0712
  },
  "formation_tops": [],
  "completions":    []
}
TX Note: Formation tops and completion data are not yet available for Texas wells. Well-level production for TX is lease-level (see the production endpoint below); state and basin trends use county-level data — see the Production section for details.
GET /data/wells/:id/production Pro+
Full monthly production history for a well (oil BBL, gas MCF, water BBL), newest first. Use the internal well ID (the id in the well record) for :id. Optional from and to query parameters limit the range (a date such as 2024-01-01). Each row includes a source, and rows for non-Texas wells also include ngl_mcf.
For Texas wells that have an RRC lease and district number, the response is lease-level (it may include several wells on the lease): :id may also be an API number, periods are YYYY-MM, from/to take YYYY-MM, water is reported as 0, there is no ngl_mcf, and the body adds source and note fields.
GET /data/wells/e68071da-.../production

{
  "well_id": "e68071da-...",
  "production": [
    { "period": "2024-12-01", "oil_bbl": "2312", "gas_mcf": "23847", "water_bbl": "1104", "ngl_mcf": "0", "source": "..." },
    { "period": "2024-11-01", "oil_bbl": "2689", "gas_mcf": "27713", "water_bbl": null, "ngl_mcf": "0", "source": "..." }
  ]
}
GET /data/formation-tops/download Signed in
Download formation tops as CSV (at most 50,000 rows per request; HTTP 404 if nothing matches). Coverage varies by state (see Data Coverage); formation tops are not yet available for Texas.
ParameterTypeDescription
api_liststringComma-separated API numbers (prefix match)
operatorstringOperator name (partial match)
basinstringBasin name (partial match)
formationstringFormation name (partial match)

📈 Production

Monthly production is available at the well level for Colorado, New Mexico, North Dakota and West Virginia. For Texas, /data/wells/:id/production returns lease-level volumes for wells with an RRC lease number, and state and basin trends use county-level RRC data.

GET /analytics/top-wells Pro+
Top producing wells by BOE, oil, or gas for a given trailing period and basin. Combines wells with well-level production (the production table) and Texas wells that are the only well on their RRC lease (lease-level volumes, data_source RRC).
ParameterTypeDescription
typestringboe, oil, or gas (default: oil)
basinstringBasin name, matched exactly (optional — omit for all basins)
operatorstringOperator name, matched exactly as stored (optional)
monthsnumberTrailing months to sum (default 1, max 12)
limitnumberNumber of wells to return (default 20, max 100)
GET /analytics/top-wells?type=boe&basin=DJ+Basin&months=6&limit=20

{
  "wells": [
    { "id": "...", "well_name": "CIVITAS 44-25H", "operator": "CIVITAS RESOURCES INC",
      "basin": "DJ Basin", "county": "Weld", "formation": "NBRR",
      "total_value": "184210", "avg_monthly": "30701.67", "latest_period": "2024-12-01",
      "months_reported": "6", "data_source": "CO/ND/WV" }
  ],
  "total": 1,
  "type": "boe",
  "unit": "BOE",
  "months": 6,
  "filters": { "basin": "DJ Basin", "operator": null }
}
Each well also carries the identifying fields api_number, api_root, well_type, status, latitude, longitude and spud_date. Unfiltered requests may be served from a cache (from_cache).

📊 Analytics

GET /analytics/operators Signed in
List operators with well counts, active producing wells, and 12-month production. Supports reported (as-filed) and current (post-M&A rollup) views.
ParameterTypeDescription
sortstringname (default), wells, active, new
limitnumberResults per page (default 100, max 500)
offsetnumberPagination offset
qstringPartial name match
modestringreported (default) or current — current merges acquired entities via MDM
basinstringFilter by basin (partial match)
GET /analytics/operators?mode=current&sort=active&limit=10

{
  "operators": [
    { "operator": "Civitas Resources", "well_count": 12840, "producing_wells": 4721,
      "oil_mbbl_12mo": 28340, "gas_mmcf_12mo": 94120,
      "new_wells_18mo": 312, "legacy_count": 5 }
  ],
  "total": 847,
  "mode": "current"
}
GET /analytics/operators/:name Signed in
Operator detail: production trend (24 months), top wells, formations breakdown, basin breakdown. Based on reported operator name (as filed with state agency).
GET /analytics/operators/:name/parent Signed in
Current operator (post-acquisition) detail. Aggregates all legacy entity names under the parent. Includes a legacy_entities breakdown table showing pre-acquisition operator names and their well counts.
GET /analytics/operators/Civitas%20Resources/parent

{
  "parent_company": "Civitas Resources",
  "ticker": "CIVI",
  "aliases": [
    { "operator_name": "BONANZA CREEK ENERGY", "acquisition_date": "2021-06-07" },
    { "operator_name": "EXTRACTION OIL & GAS", "acquisition_date": "2021-11-01" },
    { "operator_name": "HIGHPOINT RESOURCES", "acquisition_date": "2022-04-01" }
  ],
  "legacy_entities": [...],
  "prod_trend": [...],
  "top_wells": [...],
  "formations": [...]
}
GET /analytics/basins Signed in
All basins with well counts, producing wells, operator counts, and 12-month production. Includes CO, ND, and TX basins. TX production from county-level data.
GET /analytics/basins/:name Signed in
Basin detail: production trend, top operators, top wells (CO/ND), formations. For TX basins (Permian, Eagle Ford, etc.), production trend uses county-level RRC data.
GET /analytics/basins/Permian%20Basin

{
  "name":            "Permian Basin",
  "state":           "TX",
  "well_count":      527639,
  "producing_wells": 154823,
  "operator_count":  2847,
  "oil_mmbbl_12mo":  2140.3,
  "gas_bcf_12mo":    5821.4,
  "prod_trend": [
    { "period": "2024-12-01", "oil_bbl": 178420000, "gas_mcf": 485200000 }
  ],
  "top_operators": [...],
  "formations": [...]
}
GET /analytics/states Signed in
All states with summary stats, one entry per state in the platform's state statistics table.
GET /analytics/states/:code Signed in
State detail: production trend, basin breakdown, top operators, recent permits, top wells. TX production from county-level RRC data.
ParameterTypeDescription
:codestringState code (for example CO, NM, ND, TX, WV)
GET /analytics/states/TX

{
  "state":           "TX",
  "well_count":      1195235,
  "producing_wells": 154823,
  "operator_count":  4218,
  "basin_count":     6,
  "oil_mmbbl_12mo":  2140.3,
  "gas_bcf_12mo":    5821.4,
  "prod_trend":      [...],
  "basins":          [...],
  "top_operators":   [...]
}
GET /analytics/totals Signed in
Platform-wide totals: total well count, producing wells, total operators. Used for summary tiles.

📄 Permits

GET /analytics/permits Signed in
Recent drilling permits with operator, location, and status. Available for Colorado (COGCC), North Dakota (NDIC), and West Virginia (WVDEP). Texas permit data is not integrated.
ParameterTypeDescription
statestringCO, ND, or WV (default: all)
operatorstringFilter by operator (partial match)
basinstringFilter by field / basin name
well_namestringFilter by well name or API label
daysnumberPermits in the last N days (default: no date limit)
limitnumberMax results (default 50, max 200)
offsetnumberPagination offset
GET /analytics/permits?state=ND&days=14&limit=20

{
  "permits": [
    { "api_number": "33-053-...", "operator": "CONTINENTAL RESOURCES INC",
      "well_name": "RENEWAL 1-17H", "county": "Mountrail", "state": "ND",
      "permit_date": "2026-04-02", "formation": "BAKKEN", "status": "approved" }
  ],
  "total": 47
}

💲 Market Prices

GET /market/prices Public
Current WTI, Brent, Henry Hub and LLS spot prices plus Dow Jones and NASDAQ index quotes. Each commodity price comes from FRED or EIA, whichever has the more recent date, and carries its own source and date (index quotes carry a date and daily change). Cached 15 minutes. No sign-in is required.
{
  "wti":   { "price": 71.24, "date": "2026-04-10", "unit": "USD/BBL" },
  "brent": { "price": 74.83, "date": "2026-04-10", "unit": "USD/BBL" },
  "gas":   { "price":  2.94, "date": "2026-04-10", "unit": "USD/MMBtu" }
}
GET /market/prices/history Public
Historical price data for a commodity symbol (WTI, BRENT, HH). Stored daily history (FRED and EIA sources; each row has a source); up to 730 days. Response: symbol, history, count.
ParameterTypeDescription
symbolstringWTI (default), BRENT, or HH
daysnumberDays of history (default and maximum 730)
GET /market/earnings/:symbol Public
Historical EPS, forward estimates, and fundamentals for an E&P equity ticker. Sourced from Alpha Vantage (fundamentals, daily cache) and Yahoo Finance (live price).
GET /market/earnings/XOM

{
  "symbol": "XOM",
  "history": [
    { "period": "-4q", "date": "2025-12-31", "eps_actual": 1.67,
      "eps_est": 1.56, "eps_diff": 0.11, "surprise_pct": 7.05 }
  ],
  "stats": { "trailing_eps": 7.84, "forward_pe": 14.2, "revenue_growth": 0.032 }
}

📋 Reports

POST /reports/due-diligence Pro+
Generate a PDF due diligence report for an operator. Returns a PDF download or emails it to your account address. Requires one of operator, parent_company or well_ids.
{
  "operator":   "Civitas Resources",
  "ticker":     "CIVI",
  "send_email": false,
  "sections": {
    "summary":    true,
    "production": true,
    "revenue":    true,
    "permits":    true,
    "regulatory": true,
    "completion": true,
    "formations": true,
    "equity":     true
  }
}
When send_email: false, returns the PDF as a binary download. When true, emails to your account address and returns {"success": true, "emailed": true, "filename": "..."}.

⚠ Error Codes

StatusCodeMeaning
400Bad RequestMissing or invalid parameters
401UnauthorizedMissing, invalid, or expired token
403ForbiddenYour plan doesn't include this endpoint
404Not FoundResource doesn't exist
429Rate LimitedToo many requests — slow down
500Server ErrorSomething went wrong on our end
{ "error": "Pro plan required", "message": "Upgrade to Pro to use this feature", "upgrade": "/#pricing", "required_plan": "pro" }

⏱ Rate Limits

PlanSearch results per queryExports per day
Free10Exports require Pro
Pro50050
Custom5001,000

Search requests (/search/wells) are limited to 60 per minute per signed-in account (anonymous callers: per IP address); failed sign-in attempts are limited to 5 per 15 minutes per IP address; a request over either limit returns 429 with a Retry-After header. Daily export counts are monitored and reviewed rather than hard-stopped. If you need higher limits, contact support@flynlochanalytics.com.

🗺 Data Coverage

StateSourceWellsProductionFormation TopsPermits
CO COGCC ~90K Well-level monthly 298K rows ✓ COGCC
ND NDIC ~44K Well-level monthly (scout scrape) 208K rows ✓ NDIC
NM NM OCD ~143K Well-level monthly Available Not offered
WV WVDEP ~119K Well-level monthly Available ✓ WVDEP
TX RRC ~1.2M Lease-level monthly (well-level endpoint) · county-level (state and basin trends) Pending Pending

Data is updated weekly for CO and ND via automated pipelines. Texas RRC data is downloaded and loaded manually from RRC bulk files, so its freshness varies. Questions about data freshness: support@flynlochanalytics.com.