File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -29,8 +29,8 @@ pip install ipregistry
29
29
from ipregistry import IpregistryClient
30
30
31
31
client = IpregistryClient(" YOUR_API_KEY" )
32
- ip_info = client.lookup_ip(" 54.85.132.205" )
33
- print (ip_info )
32
+ response = client.lookup_ip(" 54.85.132.205" )
33
+ print (response.data )
34
34
```
35
35
36
36
#### Batch IP Lookup
@@ -39,8 +39,8 @@ print(ip_info)
39
39
from ipregistry import IpregistryClient
40
40
41
41
client = IpregistryClient(" YOUR_API_KEY" )
42
- results = client.batch_lookup_ips([" 54.85.132.205" , " 8.8.8.8" , " 2001:67c:2e8:22::c100:68b" ])
43
- for ip_info in results :
42
+ response = client.batch_lookup_ips([" 54.85.132.205" , " 8.8.8.8" , " 2001:67c:2e8:22::c100:68b" ])
43
+ for ip_info in response.data :
44
44
print (ip_info)
45
45
```
46
46
@@ -50,8 +50,8 @@ for ip_info in results:
50
50
from ipregistry import IpregistryClient
51
51
52
52
client = IpregistryClient(" YOUR_API_KEY" )
53
- ip_info = client.origin_lookup_ip()
54
- print (ip_info )
53
+ response = client.origin_lookup_ip()
54
+ print (response.data )
55
55
```
56
56
57
57
More advanced examples are available in the [ samples] ( https://github.com/ipregistry/ipregistry-python/tree/master/samples )
You can’t perform that action at this time.
0 commit comments