Dovineowuor / Phone-Number-Realtime-Tracker

This program is built to track a lost phone and number and show the actual geolocation of the registered sim in realtime.
2 stars 0 forks source link

Tracker #3

Open aldeaadam808951 opened 1 year ago

aldeaadam808951 commented 1 year ago

number = "9496896174"

import phonenumbers

import opencage

import folium

from phonenumbers import number

Extract country name

from phonenumbers import geocoder

devide phone number into different subsections

pep.number = phonenumbers.parse(number)

location = geocoder.description_for_number(pepnumber, "en")

print(location)

from phonenumbers import carrier

service_provider = phonenumbers.parse(number)

Extract service provider name

print(carrier.name_from_number(service_provider, "en"))

from opencage.geocoder import OpenCageGeocode

key = "#opencagekey"

geocoder = OpenCageGeocode(key)

query = str(location)

results = geocoder.geocode(query)

lat = results[0]['geometry']['lat']

lng = results[0]['geometry']['lng']

print(lat, lng)

print(results)

{

"cSpell.words": [

    "geocoder",

    "pepnumber",

    "phonenumbers",

    "phonenunbers"

]

}

Dovineowuor commented 1 year ago

What's the challenge with this?