Skip to content

Commit

Permalink
11.23.0
Browse files Browse the repository at this point in the history
  • Loading branch information
SupportSDM committed Jan 8, 2025
1 parent e79da17 commit b09ab04
Show file tree
Hide file tree
Showing 4 changed files with 684 additions and 73 deletions.
2 changes: 1 addition & 1 deletion com/strongdm/api/SigningCallCredential.java
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ class SigningCallCredential extends CallCredentials {
private final String apiAccessKey;
private final String signature;
private static final String API_VERSION = "2024-03-28";
private static final String USER_AGENT = "strongdm-sdk-java/11.22.0";
private static final String USER_AGENT = "strongdm-sdk-java/11.23.0";

protected SigningCallCredential(String apiAccessKey, String signature) {
this.apiAccessKey = apiAccessKey;
Expand Down
37 changes: 37 additions & 0 deletions com/strongdm/api/Workflow.java
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@

package com.strongdm.api;

import java.time.Duration;
import java.util.List;

/**
Expand All @@ -25,6 +26,42 @@
* either but automatic approval or a set of users authorized to approve the requests.
*/
public class Workflow {
private Duration accessRequestFixedDuration;
/**
* Fixed Duration of access requests bound to this workflow. If fixed duration is provided, max
* duration must be empty. If neither max nor fixed duration are provided, requests that bind to
* this workflow will use the organization-level settings.
*/
public Duration getAccessRequestFixedDuration() {
return this.accessRequestFixedDuration;
}
/**
* Fixed Duration of access requests bound to this workflow. If fixed duration is provided, max
* duration must be empty. If neither max nor fixed duration are provided, requests that bind to
* this workflow will use the organization-level settings.
*/
public void setAccessRequestFixedDuration(Duration in) {
this.accessRequestFixedDuration = in;
}

private Duration accessRequestMaxDuration;
/**
* Maximum Duration of access requests bound to this workflow. If max duration is provided, fixed
* duration must be empty. If neither max nor fixed duration are provided, requests that bind to
* this workflow will use the organization-level settings.
*/
public Duration getAccessRequestMaxDuration() {
return this.accessRequestMaxDuration;
}
/**
* Maximum Duration of access requests bound to this workflow. If max duration is provided, fixed
* duration must be empty. If neither max nor fixed duration are provided, requests that bind to
* this workflow will use the organization-level settings.
*/
public void setAccessRequestMaxDuration(Duration in) {
this.accessRequestMaxDuration = in;
}

private List<AccessRule> accessRules;
/**
* AccessRules is a list of access rules defining the resources this Workflow provides access to.
Expand Down
12 changes: 12 additions & 0 deletions com/strongdm/api/plumbing/Plumbing.java
Original file line number Diff line number Diff line change
Expand Up @@ -18764,6 +18764,10 @@ public static List<VaultTokenStore> convertRepeatedVaultTokenStoreToPlumbing(

public static com.strongdm.api.Workflow convertWorkflowToPorcelain(Workflow plumbing) {
com.strongdm.api.Workflow porcelain = new com.strongdm.api.Workflow();
porcelain.setAccessRequestFixedDuration(
Plumbing.convertDurationToPorcelain(plumbing.getAccessRequestFixedDuration()));
porcelain.setAccessRequestMaxDuration(
Plumbing.convertDurationToPorcelain(plumbing.getAccessRequestMaxDuration()));
porcelain.setAccessRules(Plumbing.convertAccessRulesToPorcelain(plumbing.getAccessRules()));
porcelain.setApprovalFlowId((plumbing.getApprovalFlowId()));
porcelain.setAutoGrant((plumbing.getAutoGrant()));
Expand All @@ -18780,6 +18784,14 @@ public static Workflow convertWorkflowToPlumbing(com.strongdm.api.Workflow porce
return null;
}
Workflow.Builder builder = Workflow.newBuilder();
if (porcelain.getAccessRequestFixedDuration() != null) {
builder.setAccessRequestFixedDuration(
Plumbing.convertDurationToPlumbing(porcelain.getAccessRequestFixedDuration()));
}
if (porcelain.getAccessRequestMaxDuration() != null) {
builder.setAccessRequestMaxDuration(
Plumbing.convertDurationToPlumbing(porcelain.getAccessRequestMaxDuration()));
}
if (porcelain.getAccessRules() != null) {
builder.setAccessRules(Plumbing.convertAccessRulesToPlumbing(porcelain.getAccessRules()));
}
Expand Down
Loading

0 comments on commit b09ab04

Please sign in to comment.