Skip to content
Open
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
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ Add the dependency in your `pom.xml` file:
<dependency>
<groupId>com.pipedream</groupId>
<artifactId>pipedream</artifactId>
<version>1.0.5</version>
<version>1.0.6</version>
</dependency>
```

Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ java {

group = 'com.pipedream'

version = '1.0.5'
version = '1.0.6'

jar {
dependsOn(":generatePomFileForMavenPublication")
Expand Down Expand Up @@ -79,7 +79,7 @@ publishing {
maven(MavenPublication) {
groupId = 'com.pipedream'
artifactId = 'pipedream'
version = '1.0.5'
version = '1.0.6'
from components.java
pom {
name = 'pipedream'
Expand Down
4 changes: 2 additions & 2 deletions src/main/java/com/pipedream/api/core/ClientOptions.java
Original file line number Diff line number Diff line change
Expand Up @@ -35,10 +35,10 @@ private ClientOptions(
this.headers.putAll(headers);
this.headers.putAll(new HashMap<String, String>() {
{
put("User-Agent", "com.pipedream:pipedream/1.0.5");
put("User-Agent", "com.pipedream:pipedream/1.0.6");
put("X-Fern-Language", "JAVA");
put("X-Fern-SDK-Name", "com.pipedream.fern:api-sdk");
put("X-Fern-SDK-Version", "1.0.5");
put("X-Fern-SDK-Version", "1.0.6");
}
});
this.headerSuppliers = headerSuppliers;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,6 @@ public CompletableFuture<BaseClientHttpResponse<SyncPagingIterable<Account>>> li
.addPathSegments("v1/connect")
.addPathSegment(clientOptions.projectId())
.addPathSegments("accounts");
if (request.getAppId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "app_id", request.getAppId().get(), false);
}
if (request.getExternalUserId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "external_user_id", request.getExternalUserId().get(), false);
Expand All @@ -92,6 +88,9 @@ public CompletableFuture<BaseClientHttpResponse<SyncPagingIterable<Account>>> li
QueryStringMapper.addQueryParameter(
httpUrl, "limit", request.getLimit().get(), false);
}
if (request.getApp().isPresent()) {
QueryStringMapper.addQueryParameter(httpUrl, "app", request.getApp().get(), false);
}
if (request.getIncludeCredentials().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl,
Expand Down Expand Up @@ -183,10 +182,6 @@ public CompletableFuture<BaseClientHttpResponse<Account>> create(
.addPathSegments("v1/connect")
.addPathSegment(clientOptions.projectId())
.addPathSegments("accounts");
if (request.getAppId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "app_id", request.getAppId().get(), false);
}
if (request.getExternalUserId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "external_user_id", request.getExternalUserId().get(), false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -63,10 +63,6 @@ public BaseClientHttpResponse<SyncPagingIterable<Account>> list(
.addPathSegments("v1/connect")
.addPathSegment(clientOptions.projectId())
.addPathSegments("accounts");
if (request.getAppId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "app_id", request.getAppId().get(), false);
}
if (request.getExternalUserId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "external_user_id", request.getExternalUserId().get(), false);
Expand All @@ -87,6 +83,9 @@ public BaseClientHttpResponse<SyncPagingIterable<Account>> list(
QueryStringMapper.addQueryParameter(
httpUrl, "limit", request.getLimit().get(), false);
}
if (request.getApp().isPresent()) {
QueryStringMapper.addQueryParameter(httpUrl, "app", request.getApp().get(), false);
}
if (request.getIncludeCredentials().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl,
Expand Down Expand Up @@ -156,10 +155,6 @@ public BaseClientHttpResponse<Account> create(CreateAccountOpts request, Request
.addPathSegments("v1/connect")
.addPathSegment(clientOptions.projectId())
.addPathSegments("accounts");
if (request.getAppId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "app_id", request.getAppId().get(), false);
}
if (request.getExternalUserId().isPresent()) {
QueryStringMapper.addQueryParameter(
httpUrl, "external_user_id", request.getExternalUserId().get(), false);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,6 @@
@JsonInclude(JsonInclude.Include.NON_ABSENT)
@JsonDeserialize(builder = AccountsListRequest.Builder.class)
public final class AccountsListRequest {
private final Optional<String> appId;

private final Optional<String> externalUserId;

private final Optional<String> oauthAppId;
Expand All @@ -32,37 +30,31 @@ public final class AccountsListRequest {

private final Optional<Integer> limit;

private final Optional<String> app;

private final Optional<Boolean> includeCredentials;

private final Map<String, Object> additionalProperties;

private AccountsListRequest(
Optional<String> appId,
Optional<String> externalUserId,
Optional<String> oauthAppId,
Optional<String> after,
Optional<String> before,
Optional<Integer> limit,
Optional<String> app,
Optional<Boolean> includeCredentials,
Map<String, Object> additionalProperties) {
this.appId = appId;
this.externalUserId = externalUserId;
this.oauthAppId = oauthAppId;
this.after = after;
this.before = before;
this.limit = limit;
this.app = app;
this.includeCredentials = includeCredentials;
this.additionalProperties = additionalProperties;
}

/**
* @return The app slug or ID to filter accounts by.
*/
@JsonProperty("app_id")
public Optional<String> getAppId() {
return appId;
}

@JsonProperty("external_user_id")
public Optional<String> getExternalUserId() {
return externalUserId;
Expand Down Expand Up @@ -100,6 +92,14 @@ public Optional<Integer> getLimit() {
return limit;
}

/**
* @return The app slug or ID to filter accounts by.
*/
@JsonProperty("app")
public Optional<String> getApp() {
return app;
}

/**
* @return Whether to retrieve the account's credentials or not
*/
Expand All @@ -120,24 +120,24 @@ public Map<String, Object> getAdditionalProperties() {
}

private boolean equalTo(AccountsListRequest other) {
return appId.equals(other.appId)
&& externalUserId.equals(other.externalUserId)
return externalUserId.equals(other.externalUserId)
&& oauthAppId.equals(other.oauthAppId)
&& after.equals(other.after)
&& before.equals(other.before)
&& limit.equals(other.limit)
&& app.equals(other.app)
&& includeCredentials.equals(other.includeCredentials);
}

@java.lang.Override
public int hashCode() {
return Objects.hash(
this.appId,
this.externalUserId,
this.oauthAppId,
this.after,
this.before,
this.limit,
this.app,
this.includeCredentials);
}

Expand All @@ -152,8 +152,6 @@ public static Builder builder() {

@JsonIgnoreProperties(ignoreUnknown = true)
public static final class Builder {
private Optional<String> appId = Optional.empty();

private Optional<String> externalUserId = Optional.empty();

private Optional<String> oauthAppId = Optional.empty();
Expand All @@ -164,6 +162,8 @@ public static final class Builder {

private Optional<Integer> limit = Optional.empty();

private Optional<String> app = Optional.empty();

private Optional<Boolean> includeCredentials = Optional.empty();

@JsonAnySetter
Expand All @@ -172,30 +172,16 @@ public static final class Builder {
private Builder() {}

public Builder from(AccountsListRequest other) {
appId(other.getAppId());
externalUserId(other.getExternalUserId());
oauthAppId(other.getOauthAppId());
after(other.getAfter());
before(other.getBefore());
limit(other.getLimit());
app(other.getApp());
includeCredentials(other.getIncludeCredentials());
return this;
}

/**
* <p>The app slug or ID to filter accounts by.</p>
*/
@JsonSetter(value = "app_id", nulls = Nulls.SKIP)
public Builder appId(Optional<String> appId) {
this.appId = appId;
return this;
}

public Builder appId(String appId) {
this.appId = Optional.ofNullable(appId);
return this;
}

@JsonSetter(value = "external_user_id", nulls = Nulls.SKIP)
public Builder externalUserId(Optional<String> externalUserId) {
this.externalUserId = externalUserId;
Expand Down Expand Up @@ -263,6 +249,20 @@ public Builder limit(Integer limit) {
return this;
}

/**
* <p>The app slug or ID to filter accounts by.</p>
*/
@JsonSetter(value = "app", nulls = Nulls.SKIP)
public Builder app(Optional<String> app) {
this.app = app;
return this;
}

public Builder app(String app) {
this.app = Optional.ofNullable(app);
return this;
}

/**
* <p>Whether to retrieve the account's credentials or not</p>
*/
Expand All @@ -279,7 +279,7 @@ public Builder includeCredentials(Boolean includeCredentials) {

public AccountsListRequest build() {
return new AccountsListRequest(
appId, externalUserId, oauthAppId, after, before, limit, includeCredentials, additionalProperties);
externalUserId, oauthAppId, after, before, limit, app, includeCredentials, additionalProperties);
}
}
}
Loading