# Find Events by Latitude/Longitude and Radius

For this example, we will find conferences and expos that happened within a 2 mile radius of a specific location, in April 2018.

{% hint style="success" %}
It is difficult working out a suitable radius around your location so to make it easier please use our [Predicted Impact Area API](/api/impact-area/get-impact-area.md) to determine the optimal area around your business.
{% endhint %}

The Events endpoint supports the use of a `within` parameter to allow you to set specific latitude and longitude coordinates and search for events which occur within a radius from that point.

This can be used to find all the *conferences and expos*, `category=conferences,expos`, *within 2 miles* of my location, `within=2mi@-37.80036998,144.9715749`, that happened during *April of 2018*,`active.gte=2018-04-01&active.lte=2018-04-30`

```python
import requests

response = requests.get(
    url="https://api.predicthq.com/v1/events/",
    headers={
      "Authorization": "Bearer $ACCESS_TOKEN",
      "Accept": "application/json"
    },
    params={
        "within" : "2mi@-37.80036998,144.9715749",
        "active.gte" : "2018-04-01",
        "active.lte" : "2018-04-30",
        "category" : "conferences,expos",
        "sort" : "rank"
    }
)

print(response.json())
```

A snippet of the results are shown below:

```json
{
  "count": 734,
  "results": [
    {
      "id": "SwBTYbfiAHYDdbkUi7",
      "title": "Great Debate: Political Interest Society vs History Society",
      "category": "conferences",
      ...
    }
  ]
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.predicthq.com/getting-started/guides/geolocation-guides/searching-by-location/find-events-by-latitude-longitude-and-radius.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
