[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"blog-\u002Fblog\u002Fag-api-energy-api-build-applications-agriculture-energy-parcel-data":3},{"id":4,"title":5,"author":6,"body":7,"category":417,"cover":418,"date":419,"description":420,"extension":421,"meta":422,"navigation":423,"path":424,"seo":425,"stem":426,"tags":427,"__hash__":433},"blog\u002Fblog\u002Fag-api-energy-api-build-applications-agriculture-energy-parcel-data.md","Ag API and Energy API: Build Applications on Township Canada's Agricultural and Energy Parcel Data","Township Canada",{"type":8,"value":9,"toc":410},"minimark",[10,14,17,34,39,42,91,94,101,107,113,119,125,131,134,138,141,169,172,178,184,190,196,202,208,214,217,221,224,292,297,302,307,315,319,337,349,353,384,399,406],[11,12,13],"p",{},"You're building a farmland evaluation tool for a crop insurance company. For each quarter section a client submits, your app needs the soil productivity rating, five years of crop rotation history, and the current land capability class. That data exists, spread across the AAFC crop inventory portal, the AGRASID soil database, and the Canada Land Inventory. Collecting it by hand is slow. Scraping it is fragile. Neither approach scales when a client submits 200 quarter sections in a single batch.",[11,15,16],{},"The same problem shows up in energy. An O&G field operations team needs well counts, pipeline crossings, Crown tenure status, and trailing production for every LSD in a disposition area. The data sits in the AER's GeoView, Petrinex spreadsheets, and provincial tenure registries. Pulling it together for a single LSD is an afternoon. Doing it for a few hundred is a project.",[11,18,19,20,27,28,33],{},"Township Canada now has two developer APIs that solve both problems: the ",[21,22,26],"a",{"href":23,"rel":24},"https:\u002F\u002Fdeveloper.townshipcanada.com\u002Fag",[25],"nofollow","Ag API"," and the ",[21,29,32],{"href":30,"rel":31},"https:\u002F\u002Fdeveloper.townshipcanada.com\u002Fenergy",[25],"Energy API",". Each returns a structured parcel report for any legal land description in western Canada, authenticated with an API key, priced per request.",[35,36,38],"h2",{"id":37},"what-the-ag-api-returns","What the Ag API returns",[11,40,41],{},"One GET request to the Ag API returns the agriculture report for a quarter section. Here is a call for NW-14-39-27-W4, a parcel near Red Deer, Alberta:",[43,44,49],"pre",{"className":45,"code":46,"language":47,"meta":48,"style":48},"language-bash shiki shiki-themes material-theme-lighter vitesse-light vitesse-dark","curl \"https:\u002F\u002Fdeveloper.townshipcanada.com\u002Fag\u002Freport?legal_location=NW-14-39-27-W4\" \\\n  -H \"X-API-Key: YOUR_API_KEY\"\n","bash","",[50,51,52,76],"code",{"__ignoreMap":48},[53,54,57,61,65,69,72],"span",{"class":55,"line":56},"line",1,[53,58,60],{"class":59},"sYn-s","curl",[53,62,64],{"class":63},"sbYkP"," \"",[53,66,68],{"class":67},"sTbE_","https:\u002F\u002Fdeveloper.townshipcanada.com\u002Fag\u002Freport?legal_location=NW-14-39-27-W4",[53,70,71],{"class":63},"\"",[53,73,75],{"class":74},"se3Ec"," \\\n",[53,77,79,83,85,88],{"class":55,"line":78},2,[53,80,82],{"class":81},"sz9Cv","  -H",[53,84,64],{"class":63},[53,86,87],{"class":67},"X-API-Key: YOUR_API_KEY",[53,89,90],{"class":63},"\"\n",[11,92,93],{},"The response is a JSON object. Key sections include:",[11,95,96,100],{},[97,98,99],"strong",{},"Productivity",": the LSRS score (a 0 to 100 rating for dryland spring-cereal cropland, derived from AGRASID 4.1), the LSRS class (1 to 7), and the single factor capping it (climate, moisture, soil, water, or continuous cropping). Also includes the Canada Land Inventory capability class and its limiter. The LSRS productivity score is Township Canada's own translation of the official LSRS class to a numeric scale, available for Alberta quarter sections.",[11,102,103,106],{},[97,104,105],{},"Cropping",": the dominant crop, crop category, rotation pattern (such as \"Wheat-Canola-Peas\"), and a Shannon diversity index that rewards a varied rotation over a persistent monoculture. Built from the AAFC Annual Crop Inventory, covering up to 10 years of satellite-derived crop classification.",[11,108,109,112],{},[97,110,111],{},"Soil",": soil order, great group, subgroup, drainage class, and slope class. In Alberta, this comes from AGRASID; in Saskatchewan and British Columbia, from the respective provincial soil surveys.",[11,114,115,118],{},[97,116,117],{},"Land use",": the dominant AAFC land-use class, its IPCC classification, and a percentage breakdown of all land-use types on the parcel.",[11,120,121,124],{},[97,122,123],{},"Drought",": the current Canadian Drought Monitor class (D0 through D4) and the date it was assessed.",[11,126,127,130],{},[97,128,129],{},"Hydrology",": nearest watercourse and water body, with distances in metres and whether either is on the parcel.",[11,132,133],{},"For a farmland evaluation tool, the practical value is that a single call replaces four or five manual lookups. Your application can score a quarter section by combining the productivity rating, crop rotation diversity, soil drainage, and current drought conditions, all from one endpoint.",[35,135,137],{"id":136},"what-the-energy-api-returns","What the Energy API returns",[11,139,140],{},"The Energy API returns the energy report for a Legal Subdivision. Here is a call for LSD 7-10-13-9-W4, a parcel in the Western Canada Sedimentary Basin near Medicine Hat:",[43,142,144],{"className":45,"code":143,"language":47,"meta":48,"style":48},"curl \"https:\u002F\u002Fdeveloper.townshipcanada.com\u002Fenergy\u002Freport?legal_location=7-10-13-9-W4\" \\\n  -H \"X-API-Key: YOUR_API_KEY\"\n",[50,145,146,159],{"__ignoreMap":48},[53,147,148,150,152,155,157],{"class":55,"line":56},[53,149,60],{"class":59},[53,151,64],{"class":63},[53,153,154],{"class":67},"https:\u002F\u002Fdeveloper.townshipcanada.com\u002Fenergy\u002Freport?legal_location=7-10-13-9-W4",[53,156,71],{"class":63},[53,158,75],{"class":74},[53,160,161,163,165,167],{"class":55,"line":78},[53,162,82],{"class":81},[53,164,64],{"class":63},[53,166,87],{"class":67},[53,168,90],{"class":63},[11,170,171],{},"The response covers seven sections:",[11,173,174,177],{},[97,175,176],{},"Summary",": total well count on the LSD, broken down by status (active, suspended, abandoned, orphan, reclamation certified), plus pipeline segment count, total pipeline length on the parcel, and the dominant operator.",[11,179,180,183],{},[97,181,182],{},"Production",": trailing 12-month volumes for oil (m3), gas (e3m3), condensate, and water, with the number of producing wells and the dominant product type. Sourced from Petrinex volumetrics, refreshed monthly.",[11,185,186,189],{},[97,187,188],{},"Wells",": individual well rows with UWI, operator, product, status, licence date, and total depth. Covers wells from the AER in Alberta, the Ministry of Energy and Resources in Saskatchewan, the BC Energy Regulator, and Manitoba's provincial registry.",[11,191,192,195],{},[97,193,194],{},"Pipelines",": pipeline segments crossing the LSD, with substance, status, licence number, maximum operating pressure, H2S content, and segment length on the parcel.",[11,197,198,201],{},[97,199,200],{},"Facilities",": AER-registered facilities on the LSD, with category (battery, compressor, gas plant, injection, meter station), status, and operator.",[11,203,204,207],{},[97,205,206],{},"Tenure",": Crown PNG (petroleum and natural gas) and Crown mineral dispositions intersecting the parcel, with disposition number, holder, type, status, and expiry date. Coverage includes Alberta, Saskatchewan, British Columbia, and Manitoba.",[11,209,210,213],{},[97,211,212],{},"Alternative energy",": CCS pore-space tenure and geothermal tenure (Alberta only), if any intersect the LSD.",[11,215,216],{},"For a lease management application, this means you can flag every active well, every expiring tenure, and every pipeline crossing on a disposition area without touching a government portal. For an environmental screening tool, the abandoned and orphan well counts and facility inventory are available in a single response.",[35,218,220],{"id":219},"three-tiers-matched-to-what-youre-building","Three tiers, matched to what you're building",[11,222,223],{},"Both APIs share the same pricing structure:",[225,226,227,246],"table",{},[228,229,230],"thead",{},[231,232,233,237,240,243],"tr",{},[234,235,236],"th",{},"Tier",[234,238,239],{},"Price",[234,241,242],{},"Requests\u002Fmonth",[234,244,245],{},"Rate limit",[247,248,249,264,278],"tbody",{},[231,250,251,255,258,261],{},[252,253,254],"td",{},"Build",[252,256,257],{},"$50 CAD\u002Fmo",[252,259,260],{},"500",[252,262,263],{},"1 req\u002Fsec",[231,265,266,269,272,275],{},[252,267,268],{},"Scale",[252,270,271],{},"$250 CAD\u002Fmo",[252,273,274],{},"5,000",[252,276,277],{},"2 req\u002Fsec",[231,279,280,283,286,289],{},[252,281,282],{},"Enterprise",[252,284,285],{},"$1,250 CAD\u002Fmo",[252,287,288],{},"50,000",[252,290,291],{},"5 req\u002Fsec",[11,293,294,296],{},[97,295,254],{}," fits prototyping and small internal tools. At 500 requests per month, a team building a proof-of-concept farmland scoring tool or a well-screening dashboard has room to iterate without a large commitment.",[11,298,299,301],{},[97,300,268],{}," fits production applications with moderate volume. A crop insurance company pulling agriculture reports for 5,000 quarter sections per month, or a land acquisition team screening LSDs across a play area, lands here.",[11,303,304,306],{},[97,305,282],{}," fits high-volume integrations. An agri-tech platform serving dozens of farm management clients, or an O&G data service enriching its own database with Township Canada parcel data, gets 50,000 requests and a 5 req\u002Fsec rate limit.",[11,308,309,310,314],{},"Each API is a separate subscription. If your application needs both agricultural and energy data (for instance, an environmental due-diligence tool that checks soil contamination risk alongside well activity), subscribe to both. There is no combined bundle discount at the API level: the Ag API and Energy API are independent products from the ",[21,311,313],{"href":312},"\u002Fpricing#bundles","web app bundles",", which serve the interactive map and report interface.",[35,316,318],{"id":317},"how-these-relate-to-the-existing-apis","How these relate to the existing APIs",[11,320,321,322,326,327,331,332,336],{},"Township Canada's ",[21,323,325],{"href":324},"\u002Fapi","developer portal"," already includes four APIs: the ",[21,328,330],{"href":329},"\u002Fguides\u002Fapi-integration","Search API"," for geocoding legal land descriptions, the Autocomplete API for type-ahead suggestions, the ",[21,333,335],{"href":334},"\u002Fguides\u002Fbatch-api-guide","Batch API"," for bulk conversions, and the Maps API for survey grid vector tiles. Those APIs convert and locate. The Ag API and Energy API report: they return the parcel-level data that sits behind the Township Canada web app's parcel report sidebar.",[11,338,339,340,344,345,348],{},"If you're building an application that needs both location and data, you can combine them. Use the Search API to resolve a legal land description to coordinates, then call the Ag API or Energy API for the parcel report. Or use the Batch API to convert a CSV of legal land descriptions, then enrich each result with agriculture or energy data. All APIs share the same ",[21,341,343],{"href":342},"\u002Fguides\u002Fapi-key-management","API key management"," and the same ",[50,346,347],{},"X-API-Key"," header.",[35,350,352],{"id":351},"getting-started","Getting started",[354,355,356,364,377],"ol",{},[357,358,359,360,363],"li",{},"Create an API key in your ",[21,361,362],{"href":342},"account settings"," if you do not already have one.",[357,365,366,367,371,372,376],{},"Subscribe to the Ag API, the Energy API, or both from the developer portal at ",[21,368,370],{"href":23,"rel":369},[25],"developer.townshipcanada.com\u002Fag"," or ",[21,373,375],{"href":30,"rel":374},[25],"developer.townshipcanada.com\u002Fenergy",".",[357,378,379,380,383],{},"Make your first call with the ",[50,381,382],{},"legal_location"," parameter set to any quarter section (Ag API) or LSD (Energy API) in western Canada.",[11,385,386,387,390,391,398],{},"The full response schema and additional code examples in JavaScript, Python, and curl are on the ",[21,388,389],{"href":324},"API documentation page",". If you're building in TypeScript, the ",[21,392,394,397],{"href":393},"\u002Fblog\u002Ftownshipcanada-sdk-typescript-npm-package",[50,395,396],{},"townshipcanada"," npm package"," handles authentication and request formatting.",[11,400,401,402,376],{},"For background on the data behind these APIs, including where each dataset comes from and how often it refreshes, see ",[21,403,405],{"href":404},"\u002Fblog\u002Fwhats-behind-the-map-energy-agriculture-data-sources","What's Behind the Map: Township Canada's Energy and Agriculture Data Sources",[407,408,409],"style",{},"html pre.shiki code .sYn-s, html code.shiki .sYn-s{--shiki-light:#E2931D;--shiki-default:#59873A;--shiki-dark:#80A665}html pre.shiki code .sbYkP, html code.shiki .sbYkP{--shiki-light:#39ADB5;--shiki-default:#B5695977;--shiki-dark:#C98A7D77}html pre.shiki code .sTbE_, html code.shiki .sTbE_{--shiki-light:#91B859;--shiki-default:#B56959;--shiki-dark:#C98A7D}html pre.shiki code .se3Ec, html code.shiki .se3Ec{--shiki-light:#90A4AE;--shiki-default:#A65E2B;--shiki-dark:#C99076}html pre.shiki code .sz9Cv, html code.shiki .sz9Cv{--shiki-light:#91B859;--shiki-default:#A65E2B;--shiki-dark:#C99076}html .light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html.light .shiki span {color: var(--shiki-light);background: var(--shiki-light-bg);font-style: var(--shiki-light-font-style);font-weight: var(--shiki-light-font-weight);text-decoration: var(--shiki-light-text-decoration);}html .default .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .shiki span {color: var(--shiki-default);background: var(--shiki-default-bg);font-style: var(--shiki-default-font-style);font-weight: var(--shiki-default-font-weight);text-decoration: var(--shiki-default-text-decoration);}html .dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}html.dark .shiki span {color: var(--shiki-dark);background: var(--shiki-dark-bg);font-style: var(--shiki-dark-font-style);font-weight: var(--shiki-dark-font-weight);text-decoration: var(--shiki-dark-text-decoration);}",{"title":48,"searchDepth":78,"depth":78,"links":411},[412,413,414,415,416],{"id":37,"depth":78,"text":38},{"id":136,"depth":78,"text":137},{"id":219,"depth":78,"text":220},{"id":317,"depth":78,"text":318},{"id":351,"depth":78,"text":352},"product",null,"2026-08-23","Two new developer APIs give programmatic access to agriculture and energy parcel reports for any western Canadian quarter section or LSD. One call returns soil, crop rotation, wells, pipelines, tenure, and production data.","md",{},true,"\u002Fblog\u002Fag-api-energy-api-build-applications-agriculture-energy-parcel-data",{"title":5,"description":420},"blog\u002Fag-api-energy-api-build-applications-agriculture-energy-parcel-data",[428,429,430,431,432],"API","Developer","Agriculture","Energy","Product Launch","3nRw5FoDuvOlYvNU_IFCGQ_LlHb3gGXHMcJbnGJ1EU4"]