| .github/workflows | ||
| src | ||
| .editorconfig | ||
| .eslintignore | ||
| .eslintrc | ||
| .gitignore | ||
| .npmrc | ||
| esbuild.config.mjs | ||
| LICENSE | ||
| manifest.json | ||
| package-lock.json | ||
| package.json | ||
| README.md | ||
| styles.css | ||
| tsconfig.json | ||
| version-bump.mjs | ||
| versions.json | ||
Obsidian Geocoding Properties
Insert address / location data from geocoding APIs as Obsidian properties.
Usage
The plugin operates on the active note. It queries the configured geocoding API using the search property order defined in the plugin settings. By default, the search term is resolved using the following priority list:
- The current note's
addressproperty, if set - The current note's
titleproperty, if set - The current note's name
You can override this order in the settings if you prefer a different set of properties.
The plugin provides two commands:
Insert properties into current note: prompts you to edit the search term and confirm before querying the API. If a term is too broad, the API may return too many results or zero results, so it often helps to add additional information (city, state, country) to the term.Insert properties into current note (no confirmation): skips confirmation and queries the API directly using the search term.
After selecting a result, the active note's frontmatter will be updated with the properties specified in the plugin's settings.
Settings
Properties
Each property can be enabled or disabled, and you can also specify a custom key for each property:
address: The formatted address returned by the API (format is not guaranteed and varies by API)lat: The latitude of the locationlng: The longitude of the locationlocation: The coordinates of the location in an obsidian-leaflet-compatible[lat, lng]formatmap_link: A link to an online map to the location using the configured map providermap_view_link: A link in in an obsidian-map-view-compatible[](geo:lat,lng)format
Property settings
Search property order
Controls which properties should be checked (and in what order) when building the geocoding search term. Provide a comma-separated list of property names; include name anywhere in the list to fall back to the note's filename.
Override existing properties
Controls whether existing properties should be overwritten when inserting (defaults to false).
Map provider
Controls which map provider should be used when inserting the map_link property (defaults to Google Maps):
API settings
API provider
The plugin currently supports two geocoding APIs:
Free Geocoding API
This is the default API. It's free, but accuracy is not guaranteed, and you may be subjected to rate limiting as a free user. (It also tends to show multiple entries for the same location.)
You'll need to register an account and get a free API key to use this service.
Google Geocoding API
This is a paid API (the cost per request is low, but it's not free). Setup is non-trivial, but accuracy is higher and rate limits are more generous.
You'll need to set up a Google Cloud project and enable the Geocoding API. You'll also need to create an API key and set up a billing account and enable billing for your project.
API key
You'll need to set your API key here.
Please be careful with your API key! I do not have access to the key, but it's stored as plaintext in your Obsidian vault, and anyone with access to the key can make requests on your behalf (which will be charged to your account if you've set up billing for the configured API).