All skills
mapbox avatar

/mapbox-android-patterns

@f5ae7de official
by mapboxmapbox/mapbox-agent-skills80 stars
17

Official integration patterns for Mapbox Maps SDK on Android. Covers installation, adding markers, user location, custom data, styles, camera control, and featureset interactions. Based on official Mapbox documentation.

Use this Skill: https://skilld.dev/gh/mapbox/mapbox-agent-skills/mapbox-android-patterns

This session only. Nothing lands on disk.

referencesannotations.md

≈273 tokens on demand. Your agent reads this file only when SKILL.md points to it.

Annotations: Circle, Polyline, Polygon

Additional annotation types beyond point markers.

Circle Annotations

val circleAnnotationManager = mapView.annotations.createCircleAnnotationManager()

val circle = CircleAnnotationOptions()
    .withPoint(Point.fromLngLat(-122.4194, 37.7749))
    .withCircleRadius(10.0)
    .withCircleColor("#FF0000")

circleAnnotationManager.create(circle)

Polyline Annotations

val polylineAnnotationManager = mapView.annotations.createPolylineAnnotationManager()

val polyline = PolylineAnnotationOptions()
    .withPoints(listOf(point1, point2, point3))
    .withLineColor("#0000FF")
    .withLineWidth(4.0)

polylineAnnotationManager.create(polyline)

Polygon Annotations

val polygonAnnotationManager = mapView.annotations.createPolygonAnnotationManager()

val points = listOf(listOf(coord1, coord2, coord3, coord1)) // Close the polygon

val polygon = PolygonAnnotationOptions()
    .withPoints(points)
    .withFillColor("#0000FF")
    .withFillOpacity(0.5)

polygonAnnotationManager.create(polygon)

Source: SKILL.md on GitHub

1 warning16d5 checks · Risk SAFE
  • Gen Agent Trust Hub16d

    The skill provides official integration patterns for the Mapbox Maps SDK for Android. It uses official Mapbox repositories and follows standard Android development best practices for secret management and permissions.

  • Socket16d

    No alerts

  • Snyk16d

    Risk: LOW · No issues

  • Runlayer7mo

    2/2 files flagged

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at f5ae7de. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 3 hours ago.

Activeupdated 2 months ago
  • mapbox
  • android
  • kotlin
  • jetpack-compose
  • maps
  • annotations
  • geolocation
  • gis

README badge

README badge for mapbox/mapbox-agent-skills/mapbox-android-patterns

Official patterns for integrating Mapbox Maps SDK v11 on Android with Kotlin, Jetpack Compose, and the View system. Covers initialization, markers, user location display, custom data, styles, camera control, and feature interactions.

Generated from the current SKILL.md.

Does this skill cover both Jetpack Compose and the View system?
Yes. The skill includes patterns for both Jetpack Compose and the traditional View system, with separate code examples for each approach.
What is the minimum Android SDK version required?
Android SDK 21 or higher is required.
Do I need to configure an access token before using Mapbox Maps?
Yes. You must create a Mapbox account, get an access token, and store it in `app/res/values/mapbox_access_token.xml` for the SDK to work.
Does this skill cover GeoJSON, custom layers, and user interactions?
The skill provides an overview and references to detailed patterns. Full coverage of GeoJSON sources, custom layers, and feature interactions is in the bundled reference files (custom-data.md, camera-styles.md, and interactions.md).
What version of Mapbox Maps SDK does this skill target?
Mapbox Maps SDK v11 for Android, with the most recent tested version being 11.18.1.

Generated from the current SKILL.md. These answers refresh after source changes.