Longdo setup
How to drive the Longdo Map API3 SDK through MapConductor. Longdo is the strong choice for Thailand, and ships from its own Maven repository.
Before you start
Get an API key
Issue a key in the Longdo Map console. The SDK sends your application's package name for validation, so the key must be registered against that exact package name.
Add the Longdo repository
dependencyResolutionManagement {
repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
repositories {
google()
mavenCentral()
// Longdo Map API3 SDK repository
maven {
url = uri("https://maven.longdo.com/artifactory/libs-release-public")
}
}
}Add the dependencies
dependencies {
// Longdo Map API3 SDK
implementation("com.longdo.map:sdk3:1.3.0")
// MapConductor BOM pins every module below
implementation(platform("com.mapconductor:mapconductor-bom:1.2.0"))
implementation("com.mapconductor:core")
implementation("com.mapconductor:for-longdo")
}Hand over the API key
The module reads longdo.map.key from the manifest. You can also set it in code.
<manifest>
<uses-permission android:name="android.permission.INTERNET" />
<application>
<meta-data
android:name="longdo.map.key"
android:value="${LONGDO_API_KEY}" />
</application>
</manifest>// Alternative: set it in code before the first map is shown com.longdo.sdk3.LongdoMap.API_KEY = "YOUR_LONGDO_API_KEY"
VERIFY
What you should see
The setup is complete when a map centred on Bangkok renders.
@Composable
fun TestLongdo(modifier: Modifier = Modifier) {
val mapState = rememberLongdoMapViewState(
mapDesign = LongdoDesign.Normal,
cameraPosition = MapCameraPosition(
position = GeoPoint(13.7563, 100.5018),
zoom = 12.0,
),
)
LongdoMapView(
state = mapState,
modifier = modifier,
onMapLoaded = { /* map ready */ },
onMapClick = { point -> /* tapped at point */ },
)
}Map designs
LongdoDesign maps onto Longdo's base layers.
Troubleshooting
The map does not appear
- Check the key is registered against your app's package name — the SDK sends it for validation.
- Confirm the INTERNET permission is present.
The build fails
- Check that the map SDK coordinates and version match what your version catalog declares.
- Make sure the repository is declared in settings.gradle.kts — with repositoriesMode set to FAIL_ON_PROJECT_REPOS, per-module repositories blocks are ignored.
- If several map SDKs are present at once, look for dependency clashes with ./gradlew :app:dependencies.
Next
Markers, polylines, polygons, circles, ground images, raster layers and info bubbles all work through the shared API. Because Longdo's Android SDK runs Longdo Map JS API3 in a WebView, shapes are added to its internal MapLibre GL as GeoJSON sources with fill and line layers; hit-testing is done by the shared core's geodesic winding test.