Execute an Overpass QL query
client.Query.Overpass(ctx, body) (*FeatureCollection, error)
POST/api/v1/overpass
Execute an Overpass QL query
package main
import (
"context"
"fmt"
"github.com/plazafyi/plaza-go"
"github.com/plazafyi/plaza-go/option"
)
func main() {
client := githubcomplazafyiplazago.NewClient(
option.WithAPIKey("My API Key"),
)
featureCollection, err := client.Query.Overpass(context.TODO(), githubcomplazafyiplazago.QueryOverpassParams{
OverpassQuery: githubcomplazafyiplazago.OverpassQueryParam{
Data: githubcomplazafyiplazago.F("data"),
},
})
if err != nil {
panic(err.Error())
}
fmt.Printf("%+v\n", featureCollection.Features)
}