curl -X POST "https://plaza.fyi/api/v1/geocode/autocomplete" \
-H "X-API-Key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"limit": 10
}'
const response = await fetch("https://plaza.fyi/api/v1/geocode/autocomplete", {
method: "POST",
headers: {
"X-API-Key": "YOUR_API_KEY",
"Content-Type": "application/json",
},
body: JSON.stringify({
"limit": 10
}),
});
const result = await response.json();
console.log(result);
import requests
response = requests.post(
"https://plaza.fyi/api/v1/geocode/autocomplete",
headers={"X-API-Key": "YOUR_API_KEY"},
json={
"limit": 10
},
)
print(response.json())
package main
import (
"fmt"
"io"
"net/http"
"strings"
)
func main() {
payload := "{\"limit\":10}"
req, err := http.NewRequest("POST", "https://plaza.fyi/api/v1/geocode/autocomplete", strings.NewReader(payload))
if err != nil {
panic(err)
}
req.Header.Set("X-API-Key", "YOUR_API_KEY")
req.Header.Set("Content-Type", "application/json")
resp, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
body, err := io.ReadAll(resp.Body)
if err != nil {
panic(err)
}
fmt.Println(string(body))
}