Skip to content

Commit

Permalink
fix: make fields required according to real API response
Browse files Browse the repository at this point in the history
  • Loading branch information
TheUnderScorer committed Feb 26, 2024
1 parent bcfae3b commit a94fd56
Show file tree
Hide file tree
Showing 24 changed files with 113 additions and 111 deletions.
5 changes: 3 additions & 2 deletions docs/BotdResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,9 @@ Contains all the information from Bot Detection product
|**ip** | **String** | IP address of the requesting browser or bot. | |
|**time** | **OffsetDateTime** | Time in UTC when the request from the JS agent was made. We recommend to treat requests that are older than 2 minutes as malicious. Otherwise, request replay attacks are possible | |
|**url** | **String** | Page URL from which identification request was sent. | |
|**userAgent** | **String** | | [optional] |
|**requestId** | **String** | | [optional] |
|**userAgent** | **String** | | |
|**requestId** | **String** | | |
|**linkedId** | **String** | | [optional] |
|**bot** | [**BotdDetectionResult**](BotdDetectionResult.md) | | |


Expand Down
3 changes: 2 additions & 1 deletion docs/EventResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@ Contains results from all activated products - Fingerprint Pro, Bot Detection, a

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**products** | [**ProductsResponse**](ProductsResponse.md) | | [optional] |
|**products** | [**ProductsResponse**](ProductsResponse.md) | | |
|**error** | [**ProductError**](ProductError.md) | | [optional] |



2 changes: 1 addition & 1 deletion docs/HighActivityResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**result** | **Boolean** | Flag indicating whether the request came from a high activity visitor. | [optional] |
|**result** | **Boolean** | Flag indicating whether the request came from a high activity visitor. | |
|**dailyRequests** | [**BigDecimal**](BigDecimal.md) | Number of requests from the same visitor in the previous day. | [optional] |


Expand Down
4 changes: 2 additions & 2 deletions docs/IpBlockListResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**result** | **Boolean** | `true` if request IP address is part of any database that we use to search for known malicious actors, `false` otherwise. | [optional] |
|**details** | [**IpBlockListResultDetails**](IpBlockListResultDetails.md) | | [optional] |
|**result** | **Boolean** | `true` if request IP address is part of any database that we use to search for known malicious actors, `false` otherwise. | |
|**details** | [**IpBlockListResultDetails**](IpBlockListResultDetails.md) | | |



4 changes: 2 additions & 2 deletions docs/IpBlockListResultDetails.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**emailSpam** | **Boolean** | IP address was part of a known email spam attack (SMTP). | [optional] |
|**attackSource** | **Boolean** | IP address was part of a known network attack (SSH/HTTPS). | [optional] |
|**emailSpam** | **Boolean** | IP address was part of a known email spam attack (SMTP). | |
|**attackSource** | **Boolean** | IP address was part of a known network attack (SSH/HTTPS). | |



4 changes: 2 additions & 2 deletions docs/IpInfoResultV4.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**address** | **String** | | [optional] |
|**geolocation** | [**IPLocation**](IPLocation.md) | | [optional] |
|**address** | **String** | | |
|**geolocation** | [**IPLocation**](IPLocation.md) | | |
|**asn** | [**ASN**](ASN.md) | | [optional] |
|**datacenter** | [**DataCenter**](DataCenter.md) | | [optional] |

Expand Down
4 changes: 2 additions & 2 deletions docs/IpInfoResultV6.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**address** | **String** | | [optional] |
|**geolocation** | [**IPLocation**](IPLocation.md) | | [optional] |
|**address** | **String** | | |
|**geolocation** | [**IPLocation**](IPLocation.md) | | |
|**asn** | [**ASN**](ASN.md) | | [optional] |
|**datacenter** | [**DataCenter**](DataCenter.md) | | [optional] |

Expand Down
2 changes: 1 addition & 1 deletion docs/LocationSpoofingResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**result** | **Boolean** | Flag indicating whether the request came from a device with location spoofing enabled. | [optional] |
|**result** | **Boolean** | Flag indicating whether the request came from a mobile device with location spoofing enabled. | |



4 changes: 2 additions & 2 deletions docs/TamperingResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**result** | **Boolean** | Flag indicating whether browser tampering was detected according to our internal thresholds. | [optional] |
|**anomalyScore** | [**BigDecimal**](BigDecimal.md) | Confidence score (`0.0 - 1.0`) for the tampering detection. Values above `0.5` suggest that we're reasonably sure there was a tampering attempt. Values below `0.5` are genuine browsers. | [optional] |
|**result** | **Boolean** | Flag indicating whether browser tampering was detected according to our internal thresholds. | |
|**anomalyScore** | [**BigDecimal**](BigDecimal.md) | Confidence score (`0.0 - 1.0`) for the tampering detection. Values above `0.5` suggest that we're reasonably sure there was a tampering attempt. Values below `0.5` are genuine browsers. | |



4 changes: 2 additions & 2 deletions docs/Visit.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,8 +14,8 @@
|**ipLocation** | [**IPLocation**](IPLocation.md) | | [optional] |
|**timestamp** | **Long** | Timestamp of the event with millisecond precision in Unix time. | |
|**time** | **OffsetDateTime** | Time expressed according to ISO 8601 in UTC format. | |
|**url** | **URI** | Page URL from which identification request was sent. | |
|**tag** | **Map<String, Object>** | A customer-provided value or an object that was sent with identification request. | [optional] |
|**url** | **URI** | Page URL from which the identification request was sent. | |
|**tag** | **Map<String, Object>** | A customer-provided value or an object that was sent with identification request. | |
|**linkedId** | **String** | A customer-provided id that was sent with identification request. | [optional] |
|**confidence** | [**Confidence**](Confidence.md) | | |
|**visitorFound** | **Boolean** | Attribute represents if a visitor had been identified before. | |
Expand Down
7 changes: 4 additions & 3 deletions docs/VpnResult.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,10 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**result** | **Boolean** | VPN or other anonymizing service has been used when sending the request. | [optional] |
|**originTimezone** | **String** | Local timezone which is used in timezoneMismatch method. | [optional] |
|**methods** | [**VpnResultMethods**](VpnResultMethods.md) | | [optional] |
|**result** | **Boolean** | VPN or other anonymizing service has been used when sending the request. | |
|**originTimezone** | **String** | Local timezone which is used in timezoneMismatch method. | |
|**originCountry** | **String** | Country of the request (only for Android SDK version >= 2.4.0, ISO 3166 format or unknown). | [optional] |
|**methods** | [**VpnResultMethods**](VpnResultMethods.md) | | |



6 changes: 3 additions & 3 deletions docs/VpnResultMethods.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@

| Name | Type | Description | Notes |
|------------ | ------------- | ------------- | -------------|
|**timezoneMismatch** | **Boolean** | User's browser timezone doesn't match the timezone from which the request was originally made. | [optional] |
|**publicVPN** | **Boolean** | Request IP address is owned and used by a public VPN service provider. | [optional] |
|**auxiliaryMobile** | **Boolean** | This method applies to mobile devices only. Indicates the result of additional methods used to detect a VPN in mobile devices. | [optional] |
|**timezoneMismatch** | **Boolean** | User's browser timezone doesn't match the timezone from which the request was originally made. | |
|**publicVPN** | **Boolean** | Request IP address is owned and used by a public VPN service provider. | |
|**auxiliaryMobile** | **Boolean** | This method applies to mobile devices only. Indicates the result of additional methods used to detect a VPN in mobile devices. | |



12 changes: 6 additions & 6 deletions src/main/java/com/fingerprint/model/BotdResult.java
Original file line number Diff line number Diff line change
Expand Up @@ -152,10 +152,10 @@ public BotdResult userAgent(String userAgent) {
* Get userAgent
* @return userAgent
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36", value = "")
@javax.annotation.Nonnull
@ApiModelProperty(example = "Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/111.0.0.0 Safari/537.36", required = true, value = "")
@JsonProperty(JSON_PROPERTY_USER_AGENT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public String getUserAgent() {
return userAgent;
Expand All @@ -178,10 +178,10 @@ public BotdResult requestId(String requestId) {
* Get requestId
* @return requestId
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "1681392853693.lRiBBD", value = "")
@javax.annotation.Nonnull
@ApiModelProperty(example = "1681392853693.lRiBBD", required = true, value = "")
@JsonProperty(JSON_PROPERTY_REQUEST_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public String getRequestId() {
return requestId;
Expand Down
9 changes: 5 additions & 4 deletions src/main/java/com/fingerprint/model/EventResponse.java
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonTypeName;
import com.fasterxml.jackson.annotation.JsonValue;
import com.fingerprint.model.ProductError;
import com.fingerprint.model.ProductsResponse;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
Expand Down Expand Up @@ -53,18 +54,18 @@ public EventResponse products(ProductsResponse products) {
* Get products
* @return products
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
@JsonProperty(JSON_PROPERTY_PRODUCTS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public ProductsResponse getProducts() {
return products;
}


@JsonProperty(JSON_PROPERTY_PRODUCTS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setProducts(ProductsResponse products) {
this.products = products;
}
Expand Down
8 changes: 4 additions & 4 deletions src/main/java/com/fingerprint/model/HighActivityResult.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,18 @@ public HighActivityResult result(Boolean result) {
* Flag indicating whether the request came from a high activity visitor.
* @return result
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "false", value = "Flag indicating whether the request came from a high activity visitor.")
@javax.annotation.Nonnull
@ApiModelProperty(example = "false", required = true, value = "Flag indicating whether the request came from a high activity visitor.")
@JsonProperty(JSON_PROPERTY_RESULT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public Boolean getResult() {
return result;
}


@JsonProperty(JSON_PROPERTY_RESULT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setResult(Boolean result) {
this.result = result;
}
Expand Down
16 changes: 8 additions & 8 deletions src/main/java/com/fingerprint/model/IpBlockListResult.java
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,18 @@ public IpBlockListResult result(Boolean result) {
* `true` if request IP address is part of any database that we use to search for known malicious actors, `false` otherwise.
* @return result
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "false", value = "`true` if request IP address is part of any database that we use to search for known malicious actors, `false` otherwise. ")
@javax.annotation.Nonnull
@ApiModelProperty(example = "false", required = true, value = "`true` if request IP address is part of any database that we use to search for known malicious actors, `false` otherwise. ")
@JsonProperty(JSON_PROPERTY_RESULT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public Boolean getResult() {
return result;
}


@JsonProperty(JSON_PROPERTY_RESULT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setResult(Boolean result) {
this.result = result;
}
Expand All @@ -82,18 +82,18 @@ public IpBlockListResult details(IpBlockListResultDetails details) {
* Get details
* @return details
**/
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
@JsonProperty(JSON_PROPERTY_DETAILS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public IpBlockListResultDetails getDetails() {
return details;
}


@JsonProperty(JSON_PROPERTY_DETAILS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setDetails(IpBlockListResultDetails details) {
this.details = details;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,18 @@ public IpBlockListResultDetails emailSpam(Boolean emailSpam) {
* IP address was part of a known email spam attack (SMTP).
* @return emailSpam
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "false", value = "IP address was part of a known email spam attack (SMTP).")
@javax.annotation.Nonnull
@ApiModelProperty(example = "false", required = true, value = "IP address was part of a known email spam attack (SMTP).")
@JsonProperty(JSON_PROPERTY_EMAIL_SPAM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public Boolean getEmailSpam() {
return emailSpam;
}


@JsonProperty(JSON_PROPERTY_EMAIL_SPAM)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setEmailSpam(Boolean emailSpam) {
this.emailSpam = emailSpam;
}
Expand All @@ -82,18 +82,18 @@ public IpBlockListResultDetails attackSource(Boolean attackSource) {
* IP address was part of a known network attack (SSH/HTTPS).
* @return attackSource
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "false", value = "IP address was part of a known network attack (SSH/HTTPS).")
@javax.annotation.Nonnull
@ApiModelProperty(example = "false", required = true, value = "IP address was part of a known network attack (SSH/HTTPS).")
@JsonProperty(JSON_PROPERTY_ATTACK_SOURCE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public Boolean getAttackSource() {
return attackSource;
}


@JsonProperty(JSON_PROPERTY_ATTACK_SOURCE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setAttackSource(Boolean attackSource) {
this.attackSource = attackSource;
}
Expand Down
17 changes: 8 additions & 9 deletions src/main/java/com/fingerprint/model/IpInfoResultV4.java
Original file line number Diff line number Diff line change
Expand Up @@ -67,18 +67,18 @@ public IpInfoResultV4 address(String address) {
* Get address
* @return address
**/
@javax.annotation.Nullable
@ApiModelProperty(example = "94.142.239.124", value = "")
@javax.annotation.Nonnull
@ApiModelProperty(example = "94.142.239.124", required = true, value = "")
@JsonProperty(JSON_PROPERTY_ADDRESS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public String getAddress() {
return address;
}


@JsonProperty(JSON_PROPERTY_ADDRESS)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setAddress(String address) {
this.address = address;
}
Expand All @@ -94,19 +94,18 @@ public IpInfoResultV4 geolocation(IPLocation geolocation) {
* @return geolocation
* @deprecated
**/
@Deprecated
@javax.annotation.Nullable
@ApiModelProperty(value = "")
@javax.annotation.Nonnull
@ApiModelProperty(required = true, value = "")
@JsonProperty(JSON_PROPERTY_GEOLOCATION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)

public IPLocation getGeolocation() {
return geolocation;
}


@JsonProperty(JSON_PROPERTY_GEOLOCATION)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
@JsonInclude(value = JsonInclude.Include.ALWAYS)
public void setGeolocation(IPLocation geolocation) {
this.geolocation = geolocation;
}
Expand Down
Loading

0 comments on commit a94fd56

Please sign in to comment.