Skip to content

OpenAPI schema sync (v2.6.0) #109

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Apr 28, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions .changeset/shiny-ghosts-sin.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
'fingerprint-pro-server-api-java-sdk': minor
---

**events-search**: Event search now supports two new filter parameters: `ip_blocklist`, `datacenter`
2 changes: 1 addition & 1 deletion .schema-version
Original file line number Diff line number Diff line change
@@ -1 +1 @@
v2.5.0
v2.6.0
12 changes: 9 additions & 3 deletions docs/FingerprintApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -439,8 +439,10 @@ public class FingerprintApiExample {
Boolean clonedApp = true; // Boolean | Filter events by Cloned App Detection result. > Note: When using this parameter, only events with the `products.clonedApp.data.result` property set to `true` or `false` are returned. Events without a `products.clonedApp` Smart Signal result are left out of the response.
Boolean emulator = true; // Boolean | Filter events by Android Emulator Detection result. > Note: When using this parameter, only events with the `products.emulator.data.result` property set to `true` or `false` are returned. Events without a `products.emulator` Smart Signal result are left out of the response.
Boolean rootApps = true; // Boolean | Filter events by Rooted Device Detection result. > Note: When using this parameter, only events with the `products.rootApps.data.result` property set to `true` or `false` are returned. Events without a `products.rootApps` Smart Signal result are left out of the response.
String vpnConfidence = "high,"; // String | Filter events by VPN Detection result confidence level. `high` - events with high VPN Detection confidence. `medium` - events with medium VPN Detection confidence. `low` - events with low VPN Detection confidence. > Note: When using this parameter, only events with the `products.vpn.data.confidence` property set to a valid value are returned. Events without a `products.vpn` Smart Signal result are left out of the response.
String vpnConfidence = "high"; // String | Filter events by VPN Detection result confidence level. `high` - events with high VPN Detection confidence. `medium` - events with medium VPN Detection confidence. `low` - events with low VPN Detection confidence. > Note: When using this parameter, only events with the `products.vpn.data.confidence` property set to a valid value are returned. Events without a `products.vpn` Smart Signal result are left out of the response.
Float minSuspectScore = 3.4F; // Float | Filter events with Suspect Score result above a provided minimum threshold. > Note: When using this parameter, only events where the `products.suspectScore.data.result` property set to a value exceeding your threshold are returned. Events without a `products.suspectScore` Smart Signal result are left out of the response.
Boolean ipBlocklist = true; // Boolean | Filter events by IP Blocklist Detection result. > Note: When using this parameter, only events with the `products.ipBlocklist.data.result` property set to `true` or `false` are returned. Events without a `products.ipBlocklist` Smart Signal result are left out of the response.
Boolean datacenter = true; // Boolean | Filter events by Datacenter Detection result. > Note: When using this parameter, only events with the `products.ipInfo.data.v4.datacenter.result` or `products.ipInfo.data.v6.datacenter.result` property set to `true` or `false` are returned. Events without a `products.ipInfo` Smart Signal result are left out of the response.
try {
SearchEventsResponse result = api.searchEvents(limit, new FingerprintApi.SearchEventsOptionalParams()
.setPaginationKey(paginationKey)
Expand All @@ -465,7 +467,9 @@ public class FingerprintApiExample {
.setEmulator(emulator)
.setRootApps(rootApps)
.setVpnConfidence(vpnConfidence)
.setMinSuspectScore(minSuspectScore));
.setMinSuspectScore(minSuspectScore)
.setIpBlocklist(ipBlocklist)
.setDatacenter(datacenter));
System.out.println(result);
} catch (ApiException e) {
System.err.println("Exception when calling FingerprintApi.searchEvents:" + e.getMessage());
Expand Down Expand Up @@ -510,8 +514,10 @@ Object containing optional parameters for API method. Supports a fluent interfac
| **clonedApp** | **Boolean**| Filter events by Cloned App Detection result. > Note: When using this parameter, only events with the `products.clonedApp.data.result` property set to `true` or `false` are returned. Events without a `products.clonedApp` Smart Signal result are left out of the response. | [optional] |
| **emulator** | **Boolean**| Filter events by Android Emulator Detection result. > Note: When using this parameter, only events with the `products.emulator.data.result` property set to `true` or `false` are returned. Events without a `products.emulator` Smart Signal result are left out of the response. | [optional] |
| **rootApps** | **Boolean**| Filter events by Rooted Device Detection result. > Note: When using this parameter, only events with the `products.rootApps.data.result` property set to `true` or `false` are returned. Events without a `products.rootApps` Smart Signal result are left out of the response. | [optional] |
| **vpnConfidence** | **String**| Filter events by VPN Detection result confidence level. `high` - events with high VPN Detection confidence. `medium` - events with medium VPN Detection confidence. `low` - events with low VPN Detection confidence. > Note: When using this parameter, only events with the `products.vpn.data.confidence` property set to a valid value are returned. Events without a `products.vpn` Smart Signal result are left out of the response. | [optional] [enum: high,, medium, low] |
| **vpnConfidence** | **String**| Filter events by VPN Detection result confidence level. `high` - events with high VPN Detection confidence. `medium` - events with medium VPN Detection confidence. `low` - events with low VPN Detection confidence. > Note: When using this parameter, only events with the `products.vpn.data.confidence` property set to a valid value are returned. Events without a `products.vpn` Smart Signal result are left out of the response. | [optional] [enum: high, medium, low] |
| **minSuspectScore** | **Float**| Filter events with Suspect Score result above a provided minimum threshold. > Note: When using this parameter, only events where the `products.suspectScore.data.result` property set to a value exceeding your threshold are returned. Events without a `products.suspectScore` Smart Signal result are left out of the response. | [optional] |
| **ipBlocklist** | **Boolean**| Filter events by IP Blocklist Detection result. > Note: When using this parameter, only events with the `products.ipBlocklist.data.result` property set to `true` or `false` are returned. Events without a `products.ipBlocklist` Smart Signal result are left out of the response. | [optional] |
| **datacenter** | **Boolean**| Filter events by Datacenter Detection result. > Note: When using this parameter, only events with the `products.ipInfo.data.v4.datacenter.result` or `products.ipInfo.data.v6.datacenter.result` property set to `true` or `false` are returned. Events without a `products.ipInfo` Smart Signal result are left out of the response. | [optional] |

### Return type

Expand Down
25 changes: 24 additions & 1 deletion res/fingerprint-server-api.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -414,7 +414,7 @@ paths:
schema:
type: string
enum:
- high,
- high
- medium
- low
description: >
Expand Down Expand Up @@ -444,6 +444,29 @@ paths:
exceeding your threshold are returned. Events without a
`products.suspectScore` Smart Signal result are left out of the
response.
- name: ip_blocklist
in: query
schema:
type: boolean
description: >
Filter events by IP Blocklist Detection result.

> Note: When using this parameter, only events with the
`products.ipBlocklist.data.result` property set to `true` or `false`
are returned. Events without a `products.ipBlocklist` Smart Signal
result are left out of the response.
- name: datacenter
in: query
schema:
type: boolean
description: >
Filter events by Datacenter Detection result.

> Note: When using this parameter, only events with the
`products.ipInfo.data.v4.datacenter.result` or
`products.ipInfo.data.v6.datacenter.result` property set to `true`
or `false` are returned. Events without a `products.ipInfo` Smart
Signal result are left out of the response.
responses:
'200':
description: Events matching the filter(s).
Expand Down
34 changes: 34 additions & 0 deletions sdk/src/main/java/com/fingerprint/api/FingerprintApi.java
Original file line number Diff line number Diff line change
Expand Up @@ -405,6 +405,8 @@ public static class SearchEventsOptionalParams {
private Boolean rootApps;
private String vpnConfidence;
private Float minSuspectScore;
private Boolean ipBlocklist;
private Boolean datacenter;

/**
* getter for paginationKey - Use `pagination_key` to get the next page of results. When more results are available (e.g., you requested up to 200 results for your search using `limit`, but there are more than 200 events total matching your request), the `paginationKey` top-level attribute is added to the response. The key corresponds to the `timestamp` of the last returned event. In the following request, use that value in the `pagination_key` parameter to get the next page of results: 1. First request, returning most recent 200 events: `GET api-base-url/events/search?limit=200` 2. Use `response.paginationKey` to get the next page of results: `GET api-base-url/events/search?limit=200&pagination_key=1740815825085`
Expand Down Expand Up @@ -751,6 +753,36 @@ public SearchEventsOptionalParams setMinSuspectScore(Float minSuspectScore) {
return this;
}

/**
* getter for ipBlocklist - Filter events by IP Blocklist Detection result. > Note: When using this parameter, only events with the `products.ipBlocklist.data.result` property set to `true` or `false` are returned. Events without a `products.ipBlocklist` Smart Signal result are left out of the response.
*/
public Boolean getIpBlocklist() {
return ipBlocklist;
}

/**
* setter for ipBlocklist - Filter events by IP Blocklist Detection result. > Note: When using this parameter, only events with the `products.ipBlocklist.data.result` property set to `true` or `false` are returned. Events without a `products.ipBlocklist` Smart Signal result are left out of the response.
*/
public SearchEventsOptionalParams setIpBlocklist(Boolean ipBlocklist) {
this.ipBlocklist = ipBlocklist;
return this;
}

/**
* getter for datacenter - Filter events by Datacenter Detection result. > Note: When using this parameter, only events with the `products.ipInfo.data.v4.datacenter.result` or `products.ipInfo.data.v6.datacenter.result` property set to `true` or `false` are returned. Events without a `products.ipInfo` Smart Signal result are left out of the response.
*/
public Boolean getDatacenter() {
return datacenter;
}

/**
* setter for datacenter - Filter events by Datacenter Detection result. > Note: When using this parameter, only events with the `products.ipInfo.data.v4.datacenter.result` or `products.ipInfo.data.v6.datacenter.result` property set to `true` or `false` are returned. Events without a `products.ipInfo` Smart Signal result are left out of the response.
*/
public SearchEventsOptionalParams setDatacenter(Boolean datacenter) {
this.datacenter = datacenter;
return this;
}

}
/**
* Get events via search
Expand Down Expand Up @@ -830,6 +862,8 @@ public ApiResponse<SearchEventsResponse> searchEventsWithHttpInfo(Integer limit,
localVarQueryParams.addAll(apiClient.parameterToPairs("", "root_apps", searchEventsOptionalParams.getRootApps()));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "vpn_confidence", searchEventsOptionalParams.getVpnConfidence()));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "min_suspect_score", searchEventsOptionalParams.getMinSuspectScore()));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "ip_blocklist", searchEventsOptionalParams.getIpBlocklist()));
localVarQueryParams.addAll(apiClient.parameterToPairs("", "datacenter", searchEventsOptionalParams.getDatacenter()));
}


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -580,6 +580,8 @@ public void searchEventsMaximumParamsTest() throws ApiException {
final String VPN_CONFIDENCE = "medium";
final Boolean EMULATOR = true;
final Boolean INCOGNITO = true;
final Boolean IP_BLOCKLIST = true;
final Boolean DATACENTER = true;

Map<String, String> expectedQueryParams = new HashMap<>();
expectedQueryParams.put("limit", String.valueOf(LIMIT));
Expand All @@ -606,6 +608,8 @@ public void searchEventsMaximumParamsTest() throws ApiException {
expectedQueryParams.put("vpn_confidence", VPN_CONFIDENCE);
expectedQueryParams.put("emulator", String.valueOf(EMULATOR));
expectedQueryParams.put("incognito", String.valueOf(INCOGNITO));
expectedQueryParams.put("ip_blocklist", String.valueOf(IP_BLOCKLIST));
expectedQueryParams.put("datacenter", String.valueOf(DATACENTER));

addMock("searchEvents", null, invocation -> {
List<Pair> queryParams = invocation.getArgument(3);
Expand Down Expand Up @@ -638,7 +642,9 @@ public void searchEventsMaximumParamsTest() throws ApiException {
.setVpn(VPN)
.setVpnConfidence(VPN_CONFIDENCE)
.setEmulator(EMULATOR)
.setIncognito(INCOGNITO));
.setIncognito(INCOGNITO)
.setIpBlocklist(IP_BLOCKLIST)
.setDatacenter(DATACENTER));
List<SearchEventsResponseEventsInner> events = response.getEvents();
assertEquals(events.size(), 1);
}
Expand Down
Loading