> For the complete documentation index, see [llms.txt](https://docs.eseye.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.eseye.com/api-reference/location-api/mast-location/locate-a-cell-tower.md).

# Locate a cell tower

Interrogates the network for the latitude, longitude, country name, country code, operator name, and time zone of a specific cell tower. If the tower is unavailable, returns the last recorded values for that tower.

Identify the location area using either `lac` or `lai`, and the cell using either `cellid` or `ci`.

**Optional fields**

Send `null` without quotes for any object you do not want to set. The value remains as previously set. To set a new value, replace `null` with the value in quotes. To remove an existing value, send an empty string.

```json
{"openapi":"3.1.0","info":{"title":"Location API","version":"1.0"},"tags":[{"name":"Mast location"}],"servers":[{"url":"https://location.eseye.com","description":"Production"}],"security":[{"sessionCookie":[]}],"components":{"securitySchemes":{"sessionCookie":{"type":"apiKey","in":"cookie","name":"PHPSESSID","description":"The session cookie established when the user logs in. Sent as\n`Cookie: PHPSESSID=<CookieNumber>`.\n\nThe Location API username and password are sent separately, in the request\nbody of each call.\n"}},"schemas":{"LocateMastRequest":{"allOf":[{"$ref":"#/components/schemas/Credentials"},{"type":"object","properties":{"request_id":{"type":"string","description":"A request identifier for tracking responses."},"mast":{"$ref":"#/components/schemas/MastRequestIdentifiers"}},"required":["mast"]}]},"Credentials":{"type":"object","properties":{"username":{"type":"string","description":"The Eseye-assigned Location API username."},"password":{"type":"string","format":"password","description":"The Eseye-assigned Location API password."}},"required":["username","password"]},"MastRequestIdentifiers":{"type":"object","description":"Details about the specific cell tower.","properties":{"mcc":{"type":"string","description":"The Mobile Country Code, which identifies the country where the cell tower\nexists, in three-digit numeric format.\n"},"mnc":{"type":"string","description":"The Mobile Network Code, which identifies the network operator of the\nnetwork that uses the cell tower, in two-digit numeric format.\n"},"lac":{"type":"string","description":"The Location Area Code of the cell tower, in decimal format. Tracks the\nphysical location of the SIM within the network. Use either this parameter\nor `lai`.\n"},"lai":{"type":"string","description":"The Location Area Identity of the cell tower, in hexadecimal format. Tracks\nthe physical location of the SIM within the network. Use either this\nparameter or `lac`.\n"},"cellid":{"type":"string","description":"Cell Identification, in hexadecimal format. Identifies the cell tower in a\nlocation area. Use either this parameter or `ci`.\n"},"ci":{"type":"string","description":"The Cell Identification, in hexadecimal format. Identifies the cell tower in\na location area. Use either this parameter or `cellid`.\n"}},"required":["mcc","mnc"],"allOf":[{"anyOf":[{"required":["lac"]},{"required":["lai"]}]},{"anyOf":[{"required":["cellid"]},{"required":["ci"]}]}]},"LocateMastResponse":{"type":"object","properties":{"status":{"$ref":"#/components/schemas/Status"},"request_id":{"type":"string","description":"The returned request identifier, for tracking responses."},"mast":{"type":"object","description":"Details about the cell tower.","properties":{"mcc":{"type":"string","description":"The Mobile Country Code, which identifies the country where the cell\ntower exists, in three-digit numeric format.\n"},"mnc":{"type":"string","description":"The Mobile Network Code, which identifies the network operator of the\nnetwork that uses the cell tower, in two-digit numeric format.\n"},"lai":{"type":"string","description":"Location Area Identity of the cell tower, in hexadecimal format. Tracks\nthe physical location of the SIM within the network.\n"},"ci":{"type":"string","description":"The Cell Identification, in hexadecimal format. Identifies the cell\ntower in a location area.\n"},"lat":{"type":"number","format":"double","description":"Cell tower latitude value."},"lon":{"type":"number","format":"double","description":"Cell tower longitude value."},"countryname":{"type":"string","description":"The name of the country the cell tower is in."},"countrycode":{"type":"string","description":"The country ISO 3166 Alpha-2 code."},"operatorname":{"type":"string","description":"The name of the network operator using the cell tower."},"timezone":{"type":"string","description":"The TZ database name of the time zone where the cell tower exists.\n"}}}}},"Status":{"type":"object","description":"Details about the request status.","properties":{"status":{"type":"string","description":"`OK` when the request processed successfully, `ERR` when the request failed.\n","enum":["OK","ERR"]},"errorCode":{"type":"string","description":"Empty when the request processed successfully. Otherwise the specific error\ncode.\n"},"errorMessage":{"type":"string","description":"Empty when the request processed successfully. Otherwise an explanation of\nthe error.\n"}}}}},"paths":{"/index/locatemast":{"post":{"operationId":"locateMast","tags":["Mast location"],"summary":"Locate a cell tower","description":"Interrogates the network for the latitude, longitude, country name, country\ncode, operator name, and time zone of a specific cell tower. If the tower is\nunavailable, returns the last recorded values for that tower.\n\nIdentify the location area using either `lac` or `lai`, and the cell using\neither `cellid` or `ci`.\n\n**Optional fields**\n\nSend `null` without quotes for any object you do not want to set. The value\nremains as previously set. To set a new value, replace `null` with the value in\nquotes. To remove an existing value, send an empty string.\n","requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LocateMastRequest"}}}},"responses":{"200":{"description":"The request was processed. Check `status.status` to determine whether the\nlookup succeeded.\n","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LocateMastResponse"}}}}}}}}}
```


---

# 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, and the optional `goal` query parameter:

```
GET https://docs.eseye.com/api-reference/location-api/mast-location/locate-a-cell-tower.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

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.
