text: import axios from 'axios'
  
  const poiLookup = async ({key,query}) => {
    const url = `https://open.mapquestapi.com/nominatim/v1/search.php?key=${key}&format=json&q=${query}&addressdetails=1&limit=3&viewbox=-1.99%2C52.02%2C0.78%2C50.94&exclude_place_ids=41697`
    const response = await axios.post(url)
    return response.data
  }
  
  const route = async (context) => {
    const url = `http://open.mapquestapi.com/directions/v2/route?key=${context.key}&from=${context.origin}&to=${context.destination}`
    const response = await axios.post(url)
    return response.data
  }
  
  const routeShape = async (context) => {
    const url = `http://open.mapquestapi.com/directions/v2/routeshape?key=${context.key}&sessionId=${context.sessionId}&fullShape=true`
    const response = await axios.post(url)
    return response.data
  }
  
  const mapService = {
    poiLookup,
    route,
    routeShape,
  }
  
  export default mapService