locationiq
v0.0.3
Published
LocationIQ API
Downloads
2,156
Maintainers
Readme
LocationIQ
npm package for https://locationiq.com
Usage
$ npm i -S locationiq
// Javascript
const { LocatioIq } = require('locationiq');
// Typescript / ES6 Module
import { LocationIq } from 'locationiq';
TL;DR;
const locationiq = new require('locationiq')({
token: 'token'
});
// Query based search
locationiq.search('Street Av. Prof Aristóteles de Menezes, Santos, São Paulo, Brasil');
Search / Forward Geocoding
Simple search
locationiq.search('Av Aristoteles de Menezes, 40');
Structure search
locationiq.search({
street: 'Av Aristoteles de Menezes',
city: 'Santos',
state: 'São Paulo',
country: 'Brazil',
});
Postal code search
locationiq.search({
postalCode: '05415-001',
country: 'BR',
});