Skip to content

About

CocoMap map API SDK (Amap/Gaode · Tencent · Baidu) · 高德/腾讯/百度地图 API 多语言 SDK · JS Python Java Go

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Latest commit

 

History

6 Commits

Folders and files

Repository files navigation

CocoMap SDK

Official map Key quota ran out? Tired of maintaining three vendor SDKs?
Swap the Host. Keep the path. Ship today.

官方 Key 配额不够?多厂 SDK 各写一套太累?
只换 Host,路径不动,马上能用。

curl -sS 'https://map.culture09.xyz/v3/place/text?keywords=天河公园&city=广州' \
  -H 'Authorization: Bearer sk_coco_YOUR_KEY'

Website · 官网 · docs, console, try-it-out
文档 / 控制台 / 在线试调都在上面。

Website JavaScript Python Java Go License: MIT Amap Tencent Baidu

CocoMap API Docs


Why CocoMap

Pain With CocoMap
Daily Key quota burns out Shared pool + clear console usage
Amap / Tencent / Baidu each need their own client One client, three namespaces
Self-hosting a proxy (keys, bans, billing) Drop-in paths, ready to call
Agents & scripts need stable LBS Plain Bearer + curl, or typed SDK

Start with a Host swap; pick up the SDK when you want types.

中文: 配额打满、三厂各一套、自建代理又难又贵——换个 Host 就能跑;要类型安全再上 SDK。额度池、控制台、高德 / 腾讯 / 百度同一入口。


Install

Language Command
JavaScript npm i @cocomap/map
Python pip install cocomap
Java cd java && mvn -q install → com.cocomap:cocomap:2.0.0
Go go get github.com/COCOSTEAM/cocomap-sdk/go@latest

API base: https://map.culture09.xyz
Grab a trial key in the console(控制台可领试用额度).


Quick start

JavaScript

import { CocomapClient } from "@cocomap/map";

const client = new CocomapClient({
  apiKey: process.env.COCOMAP_API_KEY,
  baseUrl: "https://map.culture09.xyz",
});

const r = await client.amap.placeText({ keywords: "天河公园", city: "广州" });
console.log(r.data);

Python

from cocomap import CocomapClient

client = CocomapClient(api_key="sk_coco_YOUR_KEY")
print(client.amap.place_text(keywords="天河公园", city="广州").data)

Java

CocomapClient client = CocomapClient.builder()
    .apiKey("sk_coco_YOUR_KEY")
    .build();
System.out.println(client.getAmap().placeText(
    Map.of("keywords", "天河公园", "city", "广州")).getData());

Go

client, _ := cocomap.New(cocomap.WithAPIKey("sk_coco_YOUR_KEY"))
resp, _ := client.Amap.PlaceText(ctx, map[string]string{
    "keywords": "天河公园", "city": "广州",
})
fmt.Println(resp.Data)

Namespaces: client.amap / client.tencent / client.baidu
(Java: getAmap() … · Go: Amap …).
Every call sends X-Cocomap-Provider; response fields pass through from upstream.

三厂命名空间如上;响应透传上游字段,不强制统一 schema。


Preview

Docs Console
API docs Console
API Keys Login
API Keys Login
More screenshots · 更多截图

Dark docs
Admin


Host swap (no SDK)

Already on Amap HTTP? Change two lines:

- https://restapi.amap.com/v3/place/text?...
+ https://map.culture09.xyz/v3/place/text?...

- key=YOUR_AMAP_KEY
+ Authorization: Bearer sk_coco_YOUR_KEY

Tiny walkthrough: amap-host-swap-demo
腾讯 / 百度同理:路径跟官方,Host 换成 CocoMap,详见官网文档。


Layout

javascript/   @cocomap/map
python/       cocomap
java/         com.cocomap:cocomap
go/           github.com/COCOSTEAM/cocomap-sdk/go
docs/images/  screenshots

Synced from the main platform — see SYNC.md.


Keywords

amap · gaode · 高德地图 · baidu-map · tencent-map · geocoding · reverse-geocoding · poi · place-search · routing · directions · lbs · map-api · openapi · sdk


Links

MIT · © COCOSTEAM

About

CocoMap map API SDK (Amap/Gaode · Tencent · Baidu) · 高德/腾讯/百度地图 API 多语言 SDK · JS Python Java Go

Topics

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages