canonical: https://jentic.com/apis/gov.bc.ca/geocoder

# Gov Bc Ca Geocoder REST API

The BC Address Geocoder REST API cleans, corrects, completes, geocodes, and reverse geocodes British Columbia physical addresses, intersections, and the occupants associated with them. It exposes single-address geocoding, bulk autocomplete, and proximity searches such as nearest site, occupants near a point, and intersections near a point. Several endpoints accept a path-level outputFormat extension (such as .json or .geojson). Authentication is by API key passed in the apikey header.

## For AI agents

Geocode and reverse-geocode British Columbia addresses, occupants, and intersections, with proximity search around a coordinate.

## Scope

Does not handle routing, turn-by-turn directions, or addresses outside British Columbia - use for BC address geocoding, reverse geocoding, and proximity search only.

## Capabilities

- Geocode a single BC physical or intersection address into coordinates
- Reverse geocode a coordinate to the nearest BC site, occupant, or intersection
- Find sites, occupants, or intersections within a radius of a point
- Find sites, occupants, or intersections inside a polygon or bounding box
- Look up occupants tied to a BC physical address
- Return geocoding results in JSON, GeoJSON, or other supported output formats
- Validate and standardise BC street addresses before storing them

## Use cases

### Address Validation at Form Submission

When a user submits a BC service request form, validate and standardise the address before storing it. GET /addresses.{outputFormat} accepts a free-form address string and returns the cleaned, geocoded result with confidence scores. This prevents downstream failures when the address is later used for routing or service delivery.

Example prompt: Geocode '4730 Kingsway, Burnaby BC' as JSON and return the latitude, longitude, and match confidence score.

### Nearest Service Centre Locator

Help a user find the nearest BC government service site to their current location. GET /sites/nearest.{outputFormat} accepts a coordinate and returns the closest registered site, while GET /occupants/nearest.{outputFormat} returns the closest occupant such as a specific business or office. Useful for self-service tools embedded in BC web properties.

Example prompt: Find the nearest occupant to latitude 48.428 longitude -123.366 and return its name and the distance in metres.

### Spatial Query for Outreach

Identify every site or occupant inside a polygon for a targeted outreach campaign. GET /sites/within.{outputFormat} and GET /occupants/within.{outputFormat} accept polygon geometry and return matching records. The same endpoints support a near-point variant for radius queries within an outreach zone.

Example prompt: List all sites within 500 metres of latitude 49.282 longitude -123.115 and return their addresses.

### AI Agent Address Resolver

An AI agent built on Jentic resolves user-submitted BC addresses into canonical coordinates and standardised street strings. The agent searches Jentic for 'geocode a bc address', loads the GET /addresses operation, and executes with the user input. The apikey header is injected by Jentic so the secret stays in the vault.

Example prompt: Use Jentic to search 'geocode a bc address' and resolve '800 Hornby St Vancouver' to coordinates and a cleaned address.

## Key endpoints

| Method | Path | Description |
| --- | --- | --- |
| GET | /addresses.{outputFormat} | Geocode a free-form BC address |
| GET | /occupants/addresses.{outputFormat} | Look up occupants tied to a BC address |
| GET | /sites/nearest.{outputFormat} | Find the nearest BC site to a coordinate |
| GET | /occupants/nearest.{outputFormat} | Find the nearest occupant to a coordinate |
| GET | /intersections/nearest.{outputFormat} | Find the nearest intersection to a coordinate |
| GET | /sites/within.{outputFormat} | Find all sites inside a polygon |
| GET | /sites/near.{outputFormat} | Find sites within a radius of a point |

## Key resources

- **sites** — Geocode, reverse-geocode, and search BC physical address sites
- **intersections** — Geocode and proximity-search BC street intersections
- **occupants** — Look up occupants tied to BC addresses and search them spatially
- **parcels** — Resources for BC parcel-level geocoding

## Why Jentic

- **Setup:** Wiring the BC Geocoder REST API by hand means choosing among its production, test, and delivery hosts, setting the apikey header, and passing the output format as a path segment on every call. Through Jentic you install once, import the BC Geocoder from the API Directory, store the key once, and your agent calls it.
- **Permission scoping:** The geocoder's address and site lookups take their query in parameters rather than a resource id in the path, so limit the agent to the operations it needs, such as geocoding an address or finding the nearest site. You choose the operations it may call, so the agent cannot reach anything you have not included.
- **Credential handling:** Your BC Geocoder apikey is stored once, encrypted, by your own Jentic One instance and injected as the apikey header at execution time. It never enters the agent's prompt, logs, or context.
- **Discovery method:** Agents search Jentic by intent such as 'geocode a bc address' or 'find the nearest occupant', and Jentic returns the matching geocoder operation with its outputFormat path parameter typed so the agent calls the right endpoint without reading the docs.

## Related APIs

- **Positionstack API** — Positionstack offers global forward and reverse geocoding rather than BC-authoritative results
- **TomTom Search API** — TomTom Search supports global geocoding, autocomplete, and POI search
- **BC Geographical Names Web Service** — Pair with bcgnws to enrich geocoded points with the named features around them

## FAQ

### What authentication does the BC Geocoder API use?

The BC Geocoder API uses an API key passed in the apikey header. Keys are issued through the BC API Directory and tied to a GitHub or IDIR account. When called through Jentic, the apikey is held in Jentic's encrypted vault and injected into the apikey header at request time.

### Can I reverse geocode a coordinate with the BC Geocoder API?

Yes. GET /sites/nearest.{outputFormat} returns the nearest BC site to a supplied coordinate, GET /occupants/nearest.{outputFormat} returns the nearest occupant, and GET /intersections/nearest.{outputFormat} returns the nearest street intersection. All three are reverse-geocoding shapes with different result types.

### What are the rate limits for the BC Geocoder API?

Specific limits are not declared in the OpenAPI spec. The BC API Directory documents tier-based throttling tied to the issued API key, so plan for modest sustained throughput per key and back off on HTTP 429 responses.

### How do I geocode a BC address through Jentic?

Search Jentic for 'geocode a bc address', load the GET /addresses.{outputFormat} operation, and execute with the address string and outputFormat path parameter (typically json or geojson). With pip install jentic the call returns coordinates and the cleaned address.

### Does the BC Geocoder API support spatial queries inside a polygon?

Yes. GET /sites/within.{outputFormat}, GET /occupants/within.{outputFormat}, and GET /intersections/within.{outputFormat} accept polygon or bounding-box geometry and return all matching records inside it. Pair with /sites/near for radius queries around a point.

### Can I limit what my agent is allowed to do with the BC Geocoder API?

Yes. Because you run Jentic One yourself, your own rules decide which BC Geocoder operations and credentials the agent may use. You can allow only the calls it actually needs, such as geocoding a free-form address with GET /addresses.{outputFormat} or finding the nearest site with GET /sites/nearest.{outputFormat}, while withholding occupant lookups or within-polygon spatial queries. Since these lookups take their input as query parameters rather than a resource id in the path, the agent can only reach the operations you have included and nothing more.
