Skip to content

Commit 566d261

Browse files
author
APIs and Common Services team
committed
Automated SDK update
This updates the SDK from internal repo commit segmentio/public-api@3aaed812.
1 parent 37a1863 commit 566d261

File tree

7 files changed

+11
-311
lines changed

7 files changed

+11
-311
lines changed

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ All endpoints in the API follow REST conventions and use standard HTTP methods.
1010

1111
See the next sections for more information on how to use the Segment Public API Java SDK.
1212

13-
Latest API and SDK version: 57.3.0
13+
Latest API and SDK version: 58.0.0
1414

1515
## Requirements
1616

@@ -28,7 +28,7 @@ Add this dependency to your project's POM:
2828
<dependency>
2929
<groupId>com.segment.publicapi</groupId>
3030
<artifactId>segment-publicapi</artifactId>
31-
<version>57.3.0</version>
31+
<version>58.0.0</version>
3232
<scope>compile</scope>
3333
</dependency>
3434
```
@@ -44,7 +44,7 @@ Add this dependency to your project's build file:
4444
}
4545
4646
dependencies {
47-
implementation "com.segment.publicapi:segment-publicapi:57.3.0"
47+
implementation "com.segment.publicapi:segment-publicapi:58.0.0"
4848
}
4949
```
5050

@@ -58,7 +58,7 @@ mvn clean package
5858

5959
Then manually install the following JARs:
6060

61-
* `target/segment-publicapi-57.3.0.jar`
61+
* `target/segment-publicapi-58.0.0.jar`
6262
* `target/lib/*.jar`
6363

6464
You are now ready to start making calls to Public API!

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
<artifactId>segment-publicapi</artifactId>
66
<packaging>jar</packaging>
77
<name>segment-publicapi</name>
8-
<version>57.3.0</version>
8+
<version>58.0.0</version>
99
<url>https://segment.com/docs/api/public-api/</url>
1010
<description>Segment Public API</description>
1111
<scm>

src/main/java/com/segment/publicapi/ApiClient.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ private void init() {
123123
json = new JSON();
124124

125125
// Set default User-Agent.
126-
setUserAgent("Public API SDK 57.3.0 (Java)");
126+
setUserAgent("Public API SDK 58.0.0 (Java)");
127127

128128
authentications = new HashMap<String, Authentication>();
129129
}

src/main/java/com/segment/publicapi/Configuration.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
package com.segment.publicapi;
1313

1414
public class Configuration {
15-
public static final String VERSION = "57.3.0";
15+
public static final String VERSION = "58.0.0";
1616

1717
private static ApiClient defaultApiClient = new ApiClient();
1818

src/main/java/com/segment/publicapi/models/CreateFilterForSpaceInput.java

Lines changed: 2 additions & 104 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@
2222
import com.google.gson.stream.JsonWriter;
2323
import com.segment.publicapi.JSON;
2424
import java.io.IOException;
25-
import java.util.ArrayList;
2625
import java.util.HashSet;
27-
import java.util.List;
2826
import java.util.Map;
2927
import java.util.Objects;
3028
import java.util.Set;
@@ -61,16 +59,6 @@ public class CreateFilterForSpaceInput {
6159
@SerializedName(SERIALIZED_NAME_DROP)
6260
private Boolean drop;
6361

64-
public static final String SERIALIZED_NAME_DROP_PROPERTIES = "dropProperties";
65-
66-
@SerializedName(SERIALIZED_NAME_DROP_PROPERTIES)
67-
private List<String> dropProperties;
68-
69-
public static final String SERIALIZED_NAME_ALLOW_PROPERTIES = "allowProperties";
70-
71-
@SerializedName(SERIALIZED_NAME_ALLOW_PROPERTIES)
72-
private List<String> allowProperties;
73-
7462
public CreateFilterForSpaceInput() {}
7563

7664
public CreateFilterForSpaceInput integrationId(String integrationId) {
@@ -193,62 +181,6 @@ public void setDrop(Boolean drop) {
193181
this.drop = drop;
194182
}
195183

196-
public CreateFilterForSpaceInput dropProperties(List<String> dropProperties) {
197-
198-
this.dropProperties = dropProperties;
199-
return this;
200-
}
201-
202-
public CreateFilterForSpaceInput addDropPropertiesItem(String dropPropertiesItem) {
203-
if (this.dropProperties == null) {
204-
this.dropProperties = new ArrayList<>();
205-
}
206-
this.dropProperties.add(dropPropertiesItem);
207-
return this;
208-
}
209-
210-
/**
211-
* Describes the properties to be dropped on events that match the \&quot;if\&quot; statement.
212-
*
213-
* @return dropProperties
214-
*/
215-
@javax.annotation.Nullable
216-
public List<String> getDropProperties() {
217-
return dropProperties;
218-
}
219-
220-
public void setDropProperties(List<String> dropProperties) {
221-
this.dropProperties = dropProperties;
222-
}
223-
224-
public CreateFilterForSpaceInput allowProperties(List<String> allowProperties) {
225-
226-
this.allowProperties = allowProperties;
227-
return this;
228-
}
229-
230-
public CreateFilterForSpaceInput addAllowPropertiesItem(String allowPropertiesItem) {
231-
if (this.allowProperties == null) {
232-
this.allowProperties = new ArrayList<>();
233-
}
234-
this.allowProperties.add(allowPropertiesItem);
235-
return this;
236-
}
237-
238-
/**
239-
* Describes the properties allowed on events that match the \&quot;if\&quot; statement.
240-
*
241-
* @return allowProperties
242-
*/
243-
@javax.annotation.Nullable
244-
public List<String> getAllowProperties() {
245-
return allowProperties;
246-
}
247-
248-
public void setAllowProperties(List<String> allowProperties) {
249-
this.allowProperties = allowProperties;
250-
}
251-
252184
@Override
253185
public boolean equals(Object o) {
254186
if (this == o) {
@@ -263,22 +195,12 @@ public boolean equals(Object o) {
263195
&& Objects.equals(this.name, createFilterForSpaceInput.name)
264196
&& Objects.equals(this.description, createFilterForSpaceInput.description)
265197
&& Objects.equals(this._if, createFilterForSpaceInput._if)
266-
&& Objects.equals(this.drop, createFilterForSpaceInput.drop)
267-
&& Objects.equals(this.dropProperties, createFilterForSpaceInput.dropProperties)
268-
&& Objects.equals(this.allowProperties, createFilterForSpaceInput.allowProperties);
198+
&& Objects.equals(this.drop, createFilterForSpaceInput.drop);
269199
}
270200

271201
@Override
272202
public int hashCode() {
273-
return Objects.hash(
274-
integrationId,
275-
enabled,
276-
name,
277-
description,
278-
_if,
279-
drop,
280-
dropProperties,
281-
allowProperties);
203+
return Objects.hash(integrationId, enabled, name, description, _if, drop);
282204
}
283205

284206
@Override
@@ -291,8 +213,6 @@ public String toString() {
291213
sb.append(" description: ").append(toIndentedString(description)).append("\n");
292214
sb.append(" _if: ").append(toIndentedString(_if)).append("\n");
293215
sb.append(" drop: ").append(toIndentedString(drop)).append("\n");
294-
sb.append(" dropProperties: ").append(toIndentedString(dropProperties)).append("\n");
295-
sb.append(" allowProperties: ").append(toIndentedString(allowProperties)).append("\n");
296216
sb.append("}");
297217
return sb.toString();
298218
}
@@ -320,8 +240,6 @@ private String toIndentedString(Object o) {
320240
openapiFields.add("description");
321241
openapiFields.add("if");
322242
openapiFields.add("drop");
323-
openapiFields.add("dropProperties");
324-
openapiFields.add("allowProperties");
325243

326244
// a set of required properties/fields (JSON key names)
327245
openapiRequiredFields = new HashSet<String>();
@@ -399,26 +317,6 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti
399317
+ " got `%s`",
400318
jsonObj.get("if").toString()));
401319
}
402-
// ensure the optional json data is an array if present
403-
if (jsonObj.get("dropProperties") != null
404-
&& !jsonObj.get("dropProperties").isJsonNull()
405-
&& !jsonObj.get("dropProperties").isJsonArray()) {
406-
throw new IllegalArgumentException(
407-
String.format(
408-
"Expected the field `dropProperties` to be an array in the JSON string"
409-
+ " but got `%s`",
410-
jsonObj.get("dropProperties").toString()));
411-
}
412-
// ensure the optional json data is an array if present
413-
if (jsonObj.get("allowProperties") != null
414-
&& !jsonObj.get("allowProperties").isJsonNull()
415-
&& !jsonObj.get("allowProperties").isJsonArray()) {
416-
throw new IllegalArgumentException(
417-
String.format(
418-
"Expected the field `allowProperties` to be an array in the JSON string"
419-
+ " but got `%s`",
420-
jsonObj.get("allowProperties").toString()));
421-
}
422320
}
423321

424322
public static class CustomTypeAdapterFactory implements TypeAdapterFactory {

src/main/java/com/segment/publicapi/models/Filter.java

Lines changed: 0 additions & 96 deletions
Original file line numberDiff line numberDiff line change
@@ -22,9 +22,7 @@
2222
import com.google.gson.stream.JsonWriter;
2323
import com.segment.publicapi.JSON;
2424
import java.io.IOException;
25-
import java.util.ArrayList;
2625
import java.util.HashSet;
27-
import java.util.List;
2826
import java.util.Map;
2927
import java.util.Objects;
3028
import java.util.Set;
@@ -71,16 +69,6 @@ public class Filter {
7169
@SerializedName(SERIALIZED_NAME_DROP)
7270
private Boolean drop;
7371

74-
public static final String SERIALIZED_NAME_DROP_PROPERTIES = "dropProperties";
75-
76-
@SerializedName(SERIALIZED_NAME_DROP_PROPERTIES)
77-
private List<String> dropProperties;
78-
79-
public static final String SERIALIZED_NAME_ALLOW_PROPERTIES = "allowProperties";
80-
81-
@SerializedName(SERIALIZED_NAME_ALLOW_PROPERTIES)
82-
private List<String> allowProperties;
83-
8472
public static final String SERIALIZED_NAME_CREATED_AT = "createdAt";
8573

8674
@SerializedName(SERIALIZED_NAME_CREATED_AT)
@@ -253,62 +241,6 @@ public void setDrop(Boolean drop) {
253241
this.drop = drop;
254242
}
255243

256-
public Filter dropProperties(List<String> dropProperties) {
257-
258-
this.dropProperties = dropProperties;
259-
return this;
260-
}
261-
262-
public Filter addDropPropertiesItem(String dropPropertiesItem) {
263-
if (this.dropProperties == null) {
264-
this.dropProperties = new ArrayList<>();
265-
}
266-
this.dropProperties.add(dropPropertiesItem);
267-
return this;
268-
}
269-
270-
/**
271-
* Describes the properties to be dropped on events that match the \&quot;if\&quot; statement.
272-
*
273-
* @return dropProperties
274-
*/
275-
@javax.annotation.Nullable
276-
public List<String> getDropProperties() {
277-
return dropProperties;
278-
}
279-
280-
public void setDropProperties(List<String> dropProperties) {
281-
this.dropProperties = dropProperties;
282-
}
283-
284-
public Filter allowProperties(List<String> allowProperties) {
285-
286-
this.allowProperties = allowProperties;
287-
return this;
288-
}
289-
290-
public Filter addAllowPropertiesItem(String allowPropertiesItem) {
291-
if (this.allowProperties == null) {
292-
this.allowProperties = new ArrayList<>();
293-
}
294-
this.allowProperties.add(allowPropertiesItem);
295-
return this;
296-
}
297-
298-
/**
299-
* Describes the properties allowed on events that match the \&quot;if\&quot; statement.
300-
*
301-
* @return allowProperties
302-
*/
303-
@javax.annotation.Nullable
304-
public List<String> getAllowProperties() {
305-
return allowProperties;
306-
}
307-
308-
public void setAllowProperties(List<String> allowProperties) {
309-
this.allowProperties = allowProperties;
310-
}
311-
312244
public Filter createdAt(String createdAt) {
313245

314246
this.createdAt = createdAt;
@@ -366,8 +298,6 @@ public boolean equals(Object o) {
366298
&& Objects.equals(this.description, filter.description)
367299
&& Objects.equals(this._if, filter._if)
368300
&& Objects.equals(this.drop, filter.drop)
369-
&& Objects.equals(this.dropProperties, filter.dropProperties)
370-
&& Objects.equals(this.allowProperties, filter.allowProperties)
371301
&& Objects.equals(this.createdAt, filter.createdAt)
372302
&& Objects.equals(this.updatedAt, filter.updatedAt);
373303
}
@@ -383,8 +313,6 @@ public int hashCode() {
383313
description,
384314
_if,
385315
drop,
386-
dropProperties,
387-
allowProperties,
388316
createdAt,
389317
updatedAt);
390318
}
@@ -401,8 +329,6 @@ public String toString() {
401329
sb.append(" description: ").append(toIndentedString(description)).append("\n");
402330
sb.append(" _if: ").append(toIndentedString(_if)).append("\n");
403331
sb.append(" drop: ").append(toIndentedString(drop)).append("\n");
404-
sb.append(" dropProperties: ").append(toIndentedString(dropProperties)).append("\n");
405-
sb.append(" allowProperties: ").append(toIndentedString(allowProperties)).append("\n");
406332
sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n");
407333
sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n");
408334
sb.append("}");
@@ -434,8 +360,6 @@ private String toIndentedString(Object o) {
434360
openapiFields.add("description");
435361
openapiFields.add("if");
436362
openapiFields.add("drop");
437-
openapiFields.add("dropProperties");
438-
openapiFields.add("allowProperties");
439363
openapiFields.add("createdAt");
440364
openapiFields.add("updatedAt");
441365

@@ -533,26 +457,6 @@ public static void validateJsonElement(JsonElement jsonElement) throws IOExcepti
533457
+ " got `%s`",
534458
jsonObj.get("if").toString()));
535459
}
536-
// ensure the optional json data is an array if present
537-
if (jsonObj.get("dropProperties") != null
538-
&& !jsonObj.get("dropProperties").isJsonNull()
539-
&& !jsonObj.get("dropProperties").isJsonArray()) {
540-
throw new IllegalArgumentException(
541-
String.format(
542-
"Expected the field `dropProperties` to be an array in the JSON string"
543-
+ " but got `%s`",
544-
jsonObj.get("dropProperties").toString()));
545-
}
546-
// ensure the optional json data is an array if present
547-
if (jsonObj.get("allowProperties") != null
548-
&& !jsonObj.get("allowProperties").isJsonNull()
549-
&& !jsonObj.get("allowProperties").isJsonArray()) {
550-
throw new IllegalArgumentException(
551-
String.format(
552-
"Expected the field `allowProperties` to be an array in the JSON string"
553-
+ " but got `%s`",
554-
jsonObj.get("allowProperties").toString()));
555-
}
556460
if (!jsonObj.get("createdAt").isJsonPrimitive()) {
557461
throw new IllegalArgumentException(
558462
String.format(

0 commit comments

Comments
 (0)