Skip to content

Commit

Permalink
Update examples in README
Browse files Browse the repository at this point in the history
  • Loading branch information
lpellegr committed Jun 13, 2024
1 parent 586694d commit 3bbb0ca
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ pip install ipregistry
from ipregistry import IpregistryClient

client = IpregistryClient("YOUR_API_KEY")
ip_info = client.lookup_ip("54.85.132.205")
print(ip_info)
response = client.lookup_ip("54.85.132.205")
print(response.data)
```

#### Batch IP Lookup
Expand All @@ -39,8 +39,8 @@ print(ip_info)
from ipregistry import IpregistryClient

client = IpregistryClient("YOUR_API_KEY")
results = client.batch_lookup_ips(["54.85.132.205", "8.8.8.8", "2001:67c:2e8:22::c100:68b"])
for ip_info in results:
response = client.batch_lookup_ips(["54.85.132.205", "8.8.8.8", "2001:67c:2e8:22::c100:68b"])
for ip_info in response.data:
print(ip_info)
```

Expand All @@ -50,8 +50,8 @@ for ip_info in results:
from ipregistry import IpregistryClient

client = IpregistryClient("YOUR_API_KEY")
ip_info = client.origin_lookup_ip()
print(ip_info)
response = client.origin_lookup_ip()
print(response.data)
```

More advanced examples are available in the [samples](https://github.com/ipregistry/ipregistry-python/tree/master/samples)
Expand Down

0 comments on commit 3bbb0ca

Please sign in to comment.