{"id":20766435,"url":"https://github.com/agrc/masquerade","last_synced_at":"2026-03-10T19:01:26.933Z","repository":{"id":43652844,"uuid":"282926471","full_name":"agrc/masquerade","owner":"agrc","description":"Disguise UGRC's Web API endpoints as an Esri locator service","archived":false,"fork":false,"pushed_at":"2026-02-13T19:19:40.000Z","size":606,"stargazers_count":1,"open_issues_count":8,"forks_count":0,"subscribers_count":6,"default_branch":"main","last_synced_at":"2026-02-14T02:26:12.746Z","etag":null,"topics":["government-app","http-api","terraform-managed"],"latest_commit_sha":null,"homepage":"https://github.com/agrc/masquerade#readme","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/agrc.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2020-07-27T14:44:35.000Z","updated_at":"2026-02-13T19:18:58.000Z","dependencies_parsed_at":"2024-04-29T23:46:12.831Z","dependency_job_id":"a70a22f6-4102-4a27-b272-e37aebaf3b9f","html_url":"https://github.com/agrc/masquerade","commit_stats":null,"previous_names":[],"tags_count":70,"template":false,"template_full_name":null,"purl":"pkg:github/agrc/masquerade","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agrc%2Fmasquerade","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agrc%2Fmasquerade/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agrc%2Fmasquerade/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agrc%2Fmasquerade/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/agrc","download_url":"https://codeload.github.com/agrc/masquerade/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/agrc%2Fmasquerade/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30348851,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T15:55:29.454Z","status":"ssl_error","status_checked_at":"2026-03-10T15:54:58.440Z","response_time":106,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["government-app","http-api","terraform-managed"],"created_at":"2024-11-17T11:23:40.357Z","updated_at":"2026-03-10T19:01:26.898Z","avatar_url":"https://github.com/agrc.png","language":"Python","readme":"# Masquerade\n\n[![Test and Deploy](https://github.com/agrc/masquerade/actions/workflows/push.yml/badge.svg)](https://github.com/agrc/masquerade/actions/workflows/push.yml)\n[![codecov](https://codecov.io/gh/agrc/masquerade/branch/main/graph/badge.svg?token=R97EAY9FB1)](https://codecov.io/gh/agrc/masquerade)\n\nA proxy service that impersonates an Esri locator using UGRC data and web services. Use the following URL in Esri products anywhere you would use a [geocode service](https://www.esri.com/en-us/arcgis/products/arcgis-platform/services/geocoding-search).\n\n\u003e [https://masquerade.ugrc.utah.gov/arcgis/rest/services/UtahLocator/GeocodeServer](https://masquerade.ugrc.utah.gov/arcgis/rest/services/UtahLocator/GeocodeServer)\n\n## Capabilities\n\n- Single line address geocoding (convert an address to an x,y coordinate). Powered by the [UGRC web API](https://api.mapserv.utah.gov/#geocoding).\n- Provides typeahead suggestions from the following datasets in [Open SGID](https://gis.utah.gov/sgid/open-sgid/) and returns the centroid:\n\n| Name                                                                                                                    | Dataset                                         | Search Field |\n| ----------------------------------------------------------------------------------------------------------------------- | ----------------------------------------------- | ------------ |\n| [Utah House Districts 2022 to 2032](https://opendata.gis.utah.gov/maps/utah-house-districts-2022-to-2032)               | `political.house_districts_2022_to_2032`        | `dist`       |\n| [Utah School Board Districts 2022 to 2032](https://opendata.gis.utah.gov/maps/utah-school-board-districts-2022-to-2032) | `political.school_board_districts_2022_to_2032` | `dist`       |\n| [Utah Senate Districts 2022 to 2032](https://opendata.gis.utah.gov/maps/utah-senate-districts-2022-to-2032)             | `political.senate_districts_2022_to_2032`       | `dist`       |\n| [Utah US Congress Districts 2022 to 2032](https://opendata.gis.utah.gov/maps/utah-us-congress-districts-2022-to-2032)   | `political.us_congress_districts_2022_to_2032`  | `district`   |\n| [Utah Address Points](https://opendata.gis.utah.gov/datasets/utah-address-points)                                       | `location.address_points`                       | `name`       |\n| [Utah County Boundaries](https://opendata.gis.utah.gov/datasets/utah-county-boundaries)                                 | `boundaries.county_boundaries`                  | `name`       |\n| [Utah Municipal Boundaries](https://opendata.gis.utah.gov/maps/utah-municipal-boundaries)                               | `boundaries.municipal_boundaries`               | `name`       |\n| [Utah ZIP Code Areas](https://opendata.gis.utah.gov/maps/utah-zip-code-areas)                                           | `boundaries.zip_code_areas`                     | `zip5`       |\n| [Utah GNIS Place Names](https://opendata.gis.utah.gov/maps/utah-gnis-place-names)                                       | `location.gnis_place_names`                     | `name`       |\n\n_Give Masquerade's awesome searching capabilities a try in this [simple web app](https://arcg.is/0na9Lf0)._\n\n### Supported Esri Geocode Service Operations\n\n✅ Find Address Candidates\n\n✅ Geocode Addresses\n\n✅ Reverse Geocode\n\n✅ Suggest\n\n[Esri REST API Reference](https://developers.arcgis.com/rest/services-reference/enterprise/geocode-service.htm)\n\n## Common Use Cases\n\n### ArcGIS Pro\n\n#### Locate Pane\n\nIf you are looking for a way to quickly navigate your map to Utah addresses or points of interest within ArcGIS Pro, Masquerade can help. By adding [UGRC's \"Utah Locator (Masquerade)\"](https://utah.maps.arcgis.com/home/item.html?id=f19e6205b9bd49e8a39ed51ddd58164a) (hosted in ArcGIS Online) [to your project](https://pro.arcgis.com/en/pro-app/latest/help/data/geocoding/add-locators-to-a-project.htm) it becomes available to use within the [Locate pane](https://pro.arcgis.com/en/pro-app/latest/help/data/geocoding/find-places-on-the-map.htm). To accomplish this, follow these steps:\n\n1. Add the locator to your project by right-clicking in the \"Locators\" folder and selecting \"Add Locator\"\n1. Browse to Portal -\u003e ArcGIS Online and then search for \"Masquerade\"\n1. Select \"Utah Locator (Masquerade)\"\n1. Open any map and then go to the \"Locate\" pane\n1. Click on the settings options drop-down button to the left of the search bar and verify that \"Utah Locator (Masquerade)\" is selected.\n1. Start typing in the search box and type-ahead suggestions will start appearing. Click on any suggestion to zoom the map to it.\n1. For geocoding single line addresses that do not show up in the type-ahead suggestions, type in the complete address with a zip or city and press enter. (e.g. `123 S Main Street, Holladay`).\n\nYou should see typeahead suggestions from all of the [Open SGID](https://gis.utah.gov/sgid/open-sgid/) tables above. Here are a few examples:\n\n![addresses](./screenshots/addresses.png)\n\n![cities](./screenshots/cities.png)\n\n![place names](./screenshots/place-names.png)\n\n![political districts](./screenshots/political-districts.png)\n\n#### Batch Geocoding\n\nOnce Masquerade has been added as a locator to your project, you can also use it as an input address locator with the [Geocode Addresses geoprocessing tool](https://pro.arcgis.com/en/pro-app/latest/tool-reference/geocoding/geocode-addresses.htm) for batch geocoding of address data. This makes Masquerade an easier alternative to the [Geocoding Toolbox](https://github.com/agrc/geocoding-toolbox).\n\n### Web AppBuilder/Experience Builder\n\nMasquerade can be used to power the search widget in [Web AppBuilder](https://doc.arcgis.com/en/web-appbuilder/latest/create-apps/widget-search.htm) or [Experience Builder](https://developers.arcgis.com/experience-builder/guide/search-widget/). To configure, use the following URL as the \"Geocoder URL\" (WAB) or \"Locator URL\" (EB) value in the search widget settings:\n\n\u003e [https://masquerade.ugrc.utah.gov/arcgis/rest/services/UtahLocator/GeocodeServer](https://masquerade.ugrc.utah.gov/arcgis/rest/services/UtahLocator/GeocodeServer)\n\n## Alternatives\n\n### UGRC API Client Desktop Application\n\nIf you are not already using Esri products, you likely want to check out the [Official UGRC API Client](https://gis.utah.gov/introducing-the-official-ugrc-api-client/). This is a streamlined, stand-alone desktop application that requires no Esri products or licenses.\n\n## Development\n\nThis project is set up to use the [VSCode Dev Containers extension](https://code.visualstudio.com/docs/devcontainers/containers).\n\n### URLs\n\n| Environment | URL                                                                                                                                                                                    |\n| ----------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |\n| Production  | [https://masquerade.ugrc.utah.gov/arcgis/rest/services/UtahLocator/GeocodeServer](https://masquerade.ugrc.utah.gov/arcgis/rest/services/UtahLocator/GeocodeServer)                     |\n| Staging     | [https://masquerade-gcedbtv4sa-uc.a.run.app/arcgis/rest/services/UtahLocator/GeocodeServer](https://masquerade-gcedbtv4sa-uc.a.run.app/arcgis/rest/services/UtahLocator/GeocodeServer) |\n| Local       | [https://localhost:5000/arcgis/rest/services/UtahLocator/GeocodeServer](https://localhost:5000/arcgis/rest/services/UtahLocator/GeocodeServer)                                         |\n\n### One-time Setup\n\n1. VSCode -\u003e \"Dev Containers: Open Folder in Container\"\n1. create `.env` (using `.env.sample` as a template) and populate the `WEB_API_KEY` variable with a newly created api key. Use type: `browser` and referer: `masquerade.agrc.utah.gov`.\n\n#### MacOS\n\n1. install [mkcert](https://github.com/FiloSottile/mkcert) `brew install mkcert`\n1. create locally-trusted cert (from root): `mkcert -key-file key.pem -cert-file cert.pem localhost 127.0.0.1 10.211.55.2`\n   - `10.211.55.2` is the default ip for the Parallels host machine\n1. install the mkcert CA on your local machine\n   - `mkcert -install`\n1. install the mkcert CA on another VM\n   - copy `rootCA.pem` and `rootCA-key.pem` from the directory that is the output of `mkcert -CAROOT`\n   - paste these files into a file on the VM\n   - install mkcert on the VM\n   - run `set CAROOT=\u003cpasted directory\u003e \u0026\u0026 mkcert -install` on the VM (windows terminal works better than a console emulator)\n\n#### Windows\n\n1. install [mkcert](https://github.com/FiloSottile/mkcert) `choco install mkcert`\n1. run `mkcert -install`\n1. create locally-trusted cert (from root): `mkcert -key-file key.pem -cert-file cert.pem localhost 127.0.0.1`\n\n#### CI/CD\n\n1. Run [the terraform code associated with this project](https://github.com/agrc/gcp-terraform/tree/main/masquerade).\n1. Create `dev` and `prod` environments in GitHub repo.\n1. Create repo-wide secrets:\n\n   - `WEB_API_KEY`\n   - `CODECOV_TOKEN`\n\n1. create secrets in github for each environment\n\n   - `PROJECT_ID`\n   - Secrets contained in `github-actions-secrets-[prod/dev].txt` (output from terraform)\n\n### Tests\n\n`python -m pytest`\n\n### Lint\n\n`ruff check .`\n\n### Development Server\n\n1. VSCode -\u003e \"Start Debugging\"\n\n[Here is a web app](https://experience.arcgis.com/experience/64558a178c6a4b5692e4e11eb8038957) that is pointed at `https://localhost:5000/` that can be used for testing. It also has widgets pointed at the production and staging environments.\n\n### Deployment to GCP\n\nWhen changes are pushed to either the `main` (production) or `staging` branches, the project is automatically built and deployed to the appropriate GCP project (pending passing tests).\n\n### Analytics\n\n[Data Studio](https://datastudio.google.com/s/pUR8vYLVHvs)\n","funding_links":[],"categories":[],"sub_categories":[],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fagrc%2Fmasquerade","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fagrc%2Fmasquerade","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fagrc%2Fmasquerade/lists"}