> For the complete documentation index, see [llms.txt](https://edentech.gitbook.io/glover/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://edentech.gitbook.io/glover/flutter-app/google-map.md).

# Google Map

Google map was use to allow Customer/user picker different location on map for their delivery address.

For this to work, you would need to obtain a google map key api from google console. Here is a link to google console where you can get api key <https://cloud.google.com/maps-platform/>.

And don't forget to enable the following APIs in <https://console.cloud.google.com/google/maps-apis/>

* Maps SDK for Android
* Maps SDK for iOS
* Places API
* Geolocation API
* Geocoding API
* **Directions API**
* **Distance Matrix API (v1.3.2+)**
* And ensure to enable billing for the project.

### App Setup

Please follow the instructions below to add google map api key to the flutter project

#### Android  <a href="#android" id="android"></a>

Specify your API key in the application manifest `android/app/src/main/AndroidManifest.xml`:

```markup
<manifest ...
  <application ...
    <meta-data android:name="com.google.android.geo.API_KEY"
               android:value="YOUR KEY HERE"/>
```

#### iOS <a href="#ios" id="ios"></a>

Specify your API key in the application delegate `ios/Runner/AppDelegate.swift`:

```swift
import UIKit
import Flutter
import GoogleMaps

@UIApplicationMain
@objc class AppDelegate: FlutterAppDelegate {
  override func application(
    _ application: UIApplication,
    didFinishLaunchingWithOptions launchOptions: [UIApplicationLaunchOptionsKey: Any]?
  ) -> Bool {
    GMSServices.provideAPIKey("YOUR KEY HERE")
    GeneratedPluginRegistrant.register(with: self)
    return super.application(application, didFinishLaunchingWithOptions: launchOptions)
  }
}
```


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## 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://edentech.gitbook.io/glover/flutter-app/google-map.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.
