geotoolbox_skill

This skill helps you work with PlaceDescriptor patterns for geocoding, MapKit integration, and multi-service location data.
  • Swift

56

GitHub Stars

1

Bundled Files

2 months ago

Catalog Refreshed

4 months ago

First Indexed

Readme & install

Copy the install command, review bundled files from the catalogue, and read any extended description pulled from the listing source.

Installation

Preview and clipboard use veilstrat where the catalogue uses aiagentskills.

npx veilstrat add skill rshankras/claude-code-apple-skills --skill geotoolbox

  • SKILL.md12.1 KB

Overview

This skill explains portable place representation using PlaceDescriptor from GeoToolbox and how to integrate it with MapKit for geocoding and cross-service identifiers. It shows how to build descriptors from coordinates, addresses, or MKMapItem, perform forward and reverse geocoding with async APIs, and attach multi-service place identifiers for interoperability.

How this skill works

PlaceDescriptor groups multiple PlaceRepresentation values (coordinate, address, commonName) and optional SupportingPlaceRepresentation entries (service identifiers). Use PlaceDescriptor(item: MKMapItem) to convert MapKit results directly. Perform forward and reverse geocoding with MKGeocodingRequest and MKReverseGeocodingRequest and convert MKMapItem results into PlaceDescriptor instances or build descriptors manually.

When to use it

  • You need a portable, serializable representation of a place for storage or network transfer.
  • Converting MKMapItem results from MapKit into a neutral place structure.
  • Forward geocoding: turn an address string into coordinates and a map item.
  • Reverse geocoding: resolve coordinates into an address or named place.
  • Maintaining cross-service identifiers (Apple Maps, Google, Foursquare) for the same place.

Best practices

  • Always import GeoToolbox when using PlaceDescriptor and MapKit for geocoding APIs.
  • Check optional properties (coordinate, address, commonName) for nil before use.
  • Prefer MKGeocodingRequest / MKReverseGeocodingRequest to get MKMapItem results rather than CLGeocoder/CLPlacemark.
  • Wrap CLLocationCoordinate2D in CLLocation for reverse geocoding requests.
  • Define constants for service identifier keys to avoid silent failures from typos.
  • Handle empty geocoding results and errors with async/await and do/catch.

Example use cases

  • Create a PlaceDescriptor from known coordinates and display its commonName and lat/lon.
  • Forward geocode a user-entered address, convert the first MKMapItem to a PlaceDescriptor, and attach service IDs.
  • Reverse geocode a tap on a map to show an address string and build a descriptor for sharing.
  • Migrate place data between mapping services by storing serviceIdentifiers in SupportingPlaceRepresentation.
  • Build a search result list by geocoding queries and formatting descriptors with nil-safe property access.

FAQ

Import GeoToolbox for PlaceDescriptor/representations, MapKit for MKGeocodingRequest and MKMapItem, and CoreLocation for CLLocation/CLLocationCoordinate2D.

Should I use CLGeocoder or MKGeocodingRequest?

Use MKGeocodingRequest / MKReverseGeocodingRequest when you need MKMapItem results and better MapKit integration; CLGeocoder returns CLPlacemark which lacks MapKit identifiers.

Built by
VeilStrat
AI signals for GTM teams
© 2026 VeilStrat. All rights reserved.All systems operational
geotoolbox skill by rshankras/claude-code-apple-skills | VeilStrat