You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This section demonstrates how to use the `getAbuseContactInfo()` method of the SDK. This API helps security teams, hosting providers, and compliance professionals quickly identify the correct abuse reporting contacts for any IPv4 or IPv6 address.
1052
+
1053
+
You can retrieve data like the responsible organization, role, contact emails, phone numbers, and address to take appropriate mitigation action against abusive or malicious activity.
1054
+
1055
+
> [!NOTE]
1056
+
> Abuse Contact API is only available in the **Advanced Plan**.
1057
+
1058
+
Refer to the official [Abuse Contact API documentation](https://ipgeolocation.io/ip-abuse-contact-api.html#documentation-overview) for details on all available fields.
"address": "PO Box 3646\nSouth Brisbane, QLD 4101\nAustralia",
1094
+
"emails": [
1095
+
"helpdesk@apnic.net"
1096
+
],
1097
+
"phone_numbers": [
1098
+
"+61 7 3858 3100"
1099
+
]
1100
+
}
1101
+
}
1102
+
```
1103
+
### Lookup Abuse Contact with Specific Fields
1104
+
```typescript
1105
+
asyncfunction getAbuseContact() {
1106
+
try {
1107
+
const {data} =awaitapi.getAbuseContactInfo({
1108
+
ip: '1.2.3.4',
1109
+
fields: 'abuse.role,abuse.emails'
1110
+
});
1111
+
console.log(data);
1112
+
} catch (error) {
1113
+
console.error('Error fetching location:', error);
1114
+
}
1115
+
}
1116
+
getAbuseContact();
1117
+
```
1118
+
Sample Response:
1119
+
```json
1120
+
{
1121
+
"ip": "1.2.3.4",
1122
+
"abuse": {
1123
+
"role": "abuse",
1124
+
"emails": [
1125
+
"helpdesk@apnic.net"
1126
+
]
1127
+
}
1128
+
}
1129
+
```
1130
+
### Lookup Abuse Contact while Excluding Fields
1131
+
```typescript
1132
+
asyncfunction getAbuseContact() {
1133
+
try {
1134
+
const {data} =awaitapi.getAbuseContactInfo({
1135
+
ip: '9.9.9.9',
1136
+
excludes: 'abuse.handle,abuse.emails'
1137
+
});
1138
+
console.log(data);
1139
+
} catch (error) {
1140
+
console.error('Error fetching location:', error);
1141
+
}
1142
+
}
1143
+
getAbuseContact();
1144
+
```
1145
+
Sample Response:
1146
+
```json
1147
+
{
1148
+
"ip": "9.9.9.9",
1149
+
"abuse": {
1150
+
"route": "9.9.9.0/24",
1151
+
"country": "",
1152
+
"name": "Quad9 Abuse",
1153
+
"organization": "Quad9 Abuse",
1154
+
"role": "abuse",
1155
+
"kind": "group",
1156
+
"address": "1442 A Walnut Street Ste 501\nBerkeley\nCA\n94709\nUnited States",
1157
+
"phone_numbers": [
1158
+
"+1-415-831-3129"
1159
+
]
1160
+
}
1161
+
}
1162
+
```
1163
+
1049
1164
## Timezone API Examples
1050
1165
This section provides usage examples of the `getTimezoneInfo()` method from the typescript SDK, showcasing how to fetch timezone and time-related data using different query types — IP address, latitude/longitude, timezone ID, IATA code, ICAO code, or UN/LOCODE.
1051
1166
@@ -2009,120 +2124,6 @@ Sample Response:
2009
2124
}
2010
2125
```
2011
2126
2012
-
## Abuse Contact API Examples
2013
-
This section demonstrates how to use the `getAbuseContactInfo()` method of the SDK. This API helps security teams, hosting providers, and compliance professionals quickly identify the correct abuse reporting contacts for any IPv4 or IPv6 address.
2014
-
2015
-
You can retrieve data like the responsible organization, role, contact emails, phone numbers, and address to take appropriate mitigation action against abusive or malicious activity.
2016
-
2017
-
> [!NOTE]
2018
-
> Abuse Contact API is only available in the **Advanced Plan**.
2019
-
2020
-
Refer to the official [Abuse Contact API documentation](https://ipgeolocation.io/ip-abuse-contact-api.html#documentation-overview) for details on all available fields.
0 commit comments