Skip to content

Commit 34106dd

Browse files
authored
rebuild for 1.57.0 (#88)
1 parent 14b8165 commit 34106dd

File tree

4 files changed

+137
-9
lines changed

4 files changed

+137
-9
lines changed

src/main/java/io/fusionauth/client/FusionAuthClient.java

+115
Original file line numberDiff line numberDiff line change
@@ -2366,6 +2366,22 @@ public ClientResponse<EmailTemplateResponse, Errors> patchEmailTemplate(UUID ema
23662366
.go();
23672367
}
23682368

2369+
/**
2370+
* Updates, via PATCH, the Entity with the given Id.
2371+
*
2372+
* @param entityId The Id of the Entity Type to update.
2373+
* @param request The request that contains just the new Entity information.
2374+
* @return The ClientResponse object.
2375+
*/
2376+
public ClientResponse<EntityResponse, Errors> patchEntity(UUID entityId, Map<String, Object> request) {
2377+
return start(EntityResponse.class, Errors.class)
2378+
.uri("/api/entity")
2379+
.urlSegment(entityId)
2380+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
2381+
.patch()
2382+
.go();
2383+
}
2384+
23692385
/**
23702386
* Updates, via PATCH, the Entity Type with the given Id.
23712387
*
@@ -2382,6 +2398,57 @@ public ClientResponse<EntityTypeResponse, Errors> patchEntityType(UUID entityTyp
23822398
.go();
23832399
}
23842400

2401+
/**
2402+
* Patches the permission with the given Id for the entity type.
2403+
*
2404+
* @param entityTypeId The Id of the entityType that the permission belongs to.
2405+
* @param permissionId The Id of the permission to patch.
2406+
* @param request The request that contains the new permission information.
2407+
* @return The ClientResponse object.
2408+
*/
2409+
public ClientResponse<EntityTypeResponse, Errors> patchEntityTypePermission(UUID entityTypeId, UUID permissionId, Map<String, Object> request) {
2410+
return start(EntityTypeResponse.class, Errors.class)
2411+
.uri("/api/entity/type")
2412+
.urlSegment(entityTypeId)
2413+
.urlSegment("permission")
2414+
.urlSegment(permissionId)
2415+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
2416+
.patch()
2417+
.go();
2418+
}
2419+
2420+
/**
2421+
* Patches the form with the given Id.
2422+
*
2423+
* @param formId The Id of the form to patch.
2424+
* @param request The request object that contains the new form information.
2425+
* @return The ClientResponse object.
2426+
*/
2427+
public ClientResponse<FormResponse, Errors> patchForm(UUID formId, Map<String, Object> request) {
2428+
return start(FormResponse.class, Errors.class)
2429+
.uri("/api/form")
2430+
.urlSegment(formId)
2431+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
2432+
.patch()
2433+
.go();
2434+
}
2435+
2436+
/**
2437+
* Patches the form field with the given Id.
2438+
*
2439+
* @param fieldId The Id of the form field to patch.
2440+
* @param request The request object that contains the new form field information.
2441+
* @return The ClientResponse object.
2442+
*/
2443+
public ClientResponse<FormFieldResponse, Errors> patchFormField(UUID fieldId, Map<String, Object> request) {
2444+
return start(FormFieldResponse.class, Errors.class)
2445+
.uri("/api/form/field")
2446+
.urlSegment(fieldId)
2447+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
2448+
.patch()
2449+
.go();
2450+
}
2451+
23852452
/**
23862453
* Updates, via PATCH, the group with the given Id.
23872454
*
@@ -2398,6 +2465,22 @@ public ClientResponse<GroupResponse, Errors> patchGroup(UUID groupId, Map<String
23982465
.go();
23992466
}
24002467

2468+
/**
2469+
* Update the IP Access Control List with the given Id.
2470+
*
2471+
* @param accessControlListId The Id of the IP Access Control List to patch.
2472+
* @param request The request that contains the new IP Access Control List information.
2473+
* @return The ClientResponse object.
2474+
*/
2475+
public ClientResponse<IPAccessControlListResponse, Errors> patchIPAccessControlList(UUID accessControlListId, Map<String, Object> request) {
2476+
return start(IPAccessControlListResponse.class, Errors.class)
2477+
.uri("/api/ip-acl")
2478+
.urlSegment(accessControlListId)
2479+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
2480+
.patch()
2481+
.go();
2482+
}
2483+
24012484
/**
24022485
* Updates, via PATCH, the identity provider with the given Id.
24032486
*
@@ -2621,6 +2704,22 @@ public ClientResponse<UserConsentResponse, Errors> patchUserConsent(UUID userCon
26212704
.go();
26222705
}
26232706

2707+
/**
2708+
* Patches the webhook with the given Id.
2709+
*
2710+
* @param webhookId The Id of the webhook to update.
2711+
* @param request The request that contains the new webhook information.
2712+
* @return The ClientResponse object.
2713+
*/
2714+
public ClientResponse<WebhookResponse, Errors> patchWebhook(UUID webhookId, Map<String, Object> request) {
2715+
return start(WebhookResponse.class, Errors.class)
2716+
.uri("/api/webhook")
2717+
.urlSegment(webhookId)
2718+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
2719+
.patch()
2720+
.go();
2721+
}
2722+
26242723
/**
26252724
* Reactivates the application with the given Id.
26262725
*
@@ -5216,6 +5315,22 @@ public ClientResponse<EntityTypeResponse, Errors> updateEntityTypePermission(UUI
52165315
.go();
52175316
}
52185317

5318+
/**
5319+
* Updates a family with a given Id.
5320+
*
5321+
* @param familyId The Id of the family to update.
5322+
* @param request The request object that contains all the new family information.
5323+
* @return The ClientResponse object.
5324+
*/
5325+
public ClientResponse<FamilyResponse, Errors> updateFamily(UUID familyId, FamilyRequest request) {
5326+
return start(FamilyResponse.class, Errors.class)
5327+
.uri("/api/user/family")
5328+
.urlSegment(familyId)
5329+
.bodyHandler(new JSONBodyHandler(request, objectMapper()))
5330+
.put()
5331+
.go();
5332+
}
5333+
52195334
/**
52205335
* Updates the form with the given Id.
52215336
*

src/main/java/io/fusionauth/domain/SystemConfiguration.java

+6-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2018-2024, FusionAuth, All Rights Reserved
2+
* Copyright (c) 2018-2025, FusionAuth, All Rights Reserved
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -182,6 +182,11 @@ public DeleteConfiguration(int numberOfDaysToRetain) {
182182
this.numberOfDaysToRetain = numberOfDaysToRetain;
183183
}
184184

185+
public DeleteConfiguration(int numberOfDaysToRetain, boolean enabled) {
186+
this.enabled = enabled;
187+
this.numberOfDaysToRetain = numberOfDaysToRetain;
188+
}
189+
185190
@Override
186191
public boolean equals(Object o) {
187192
if (this == o) {

src/main/java/io/fusionauth/domain/WebhookEventLogConfiguration.java

+10-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2024, FusionAuth, All Rights Reserved
2+
* Copyright (c) 2024-2025, FusionAuth, All Rights Reserved
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -26,14 +26,15 @@
2626
*
2727
* @author Spencer Witt
2828
*/
29-
public class WebhookEventLogConfiguration {
30-
public DeleteConfiguration delete = new DeleteConfiguration(30);
29+
public class WebhookEventLogConfiguration extends Enableable {
30+
public DeleteConfiguration delete = new DeleteConfiguration(30, true);
3131

3232
@JacksonConstructor
3333
public WebhookEventLogConfiguration() {
3434
}
3535

3636
public WebhookEventLogConfiguration(WebhookEventLogConfiguration other) {
37+
this.enabled = other.enabled;
3738
this.delete = new DeleteConfiguration(other.delete);
3839
}
3940

@@ -42,16 +43,21 @@ public boolean equals(Object o) {
4243
if (this == o) {
4344
return true;
4445
}
46+
// @formatter:off
4547
if (!(o instanceof WebhookEventLogConfiguration)) {
4648
return false;
4749
}
50+
if (!super.equals(o)) {
51+
return false;
52+
}
4853
WebhookEventLogConfiguration that = (WebhookEventLogConfiguration) o;
4954
return Objects.equals(delete, that.delete);
55+
// @formatter:on
5056
}
5157

5258
@Override
5359
public int hashCode() {
54-
return Objects.hash(delete);
60+
return Objects.hash(super.hashCode(), delete);
5561
}
5662

5763
@Override

src/main/java/io/fusionauth/domain/search/WebhookEventLogSearchCriteria.java

+6-4
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*
2-
* Copyright (c) 2024, FusionAuth, All Rights Reserved
2+
* Copyright (c) 2024-2025, FusionAuth, All Rights Reserved
33
*
44
* Licensed under the Apache License, Version 2.0 (the "License");
55
* you may not use this file except in compliance with the License.
@@ -15,7 +15,9 @@
1515
*/
1616
package io.fusionauth.domain.search;
1717

18+
import java.time.ZoneOffset;
1819
import java.time.ZonedDateTime;
20+
import java.time.temporal.ChronoUnit;
1921
import java.util.LinkedHashMap;
2022
import java.util.Map;
2123
import java.util.Set;
@@ -35,15 +37,15 @@
3537
public class WebhookEventLogSearchCriteria extends BaseSearchCriteria implements Buildable<WebhookEventLogSearchCriteria> {
3638
public static final Map<String, String> SortableFields = new LinkedHashMap<>();
3739

38-
public ZonedDateTime end;
40+
public ZonedDateTime end = ZonedDateTime.now(ZoneOffset.UTC).plusMinutes(1).truncatedTo(ChronoUnit.MINUTES);
3941

4042
public String event;
4143

4244
public WebhookEventResult eventResult;
4345

4446
public EventType eventType;
4547

46-
public ZonedDateTime start;
48+
public ZonedDateTime start = ZonedDateTime.now(ZoneOffset.UTC).minusHours(1).truncatedTo(ChronoUnit.MINUTES);
4749

4850
@JacksonConstructor
4951
public WebhookEventLogSearchCriteria() {
@@ -67,7 +69,7 @@ public Set<String> supportedOrderByColumns() {
6769

6870
@Override
6971
protected String defaultOrderBy() {
70-
return "sequence DESC";
72+
return "insertInstant DESC";
7173
}
7274

7375
static {

0 commit comments

Comments
 (0)