Skip to content

Commit f5b7503

Browse files
author
APIs and Common Services team
committed
Automated SDK update
This updates the SDK from internal repo commit segmentio/public-api@675319cb.
1 parent 674db61 commit f5b7503

10 files changed

+1096
-7
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: 59.4.0
13+
Latest API and SDK version: 59.5.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>59.4.0</version>
31+
<version>59.5.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:59.4.0"
47+
implementation "com.segment.publicapi:segment-publicapi:59.5.0"
4848
}
4949
```
5050

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

5959
Then manually install the following JARs:
6060

61-
* `target/segment-publicapi-59.4.0.jar`
61+
* `target/segment-publicapi-59.5.0.jar`
6262
* `target/lib/*.jar`
6363

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

docs/AudiencesApi.md

Lines changed: 80 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ All URIs are relative to *https://api.segmentapis.com*
1515
| [**listAudiences**](AudiencesApi.md#listAudiences) | **GET** /spaces/{spaceId}/audiences | List Audiences |
1616
| [**removeAudienceFromSpace**](AudiencesApi.md#removeAudienceFromSpace) | **DELETE** /spaces/{spaceId}/audiences/{id} | Remove Audience from Space |
1717
| [**updateAudienceForSpace**](AudiencesApi.md#updateAudienceForSpace) | **PATCH** /spaces/{spaceId}/audiences/{id} | Update Audience for Space |
18+
| [**updateAudienceScheduleForAudience**](AudiencesApi.md#updateAudienceScheduleForAudience) | **PATCH** /spaces/{spaceId}/audiences/{id}/schedules/{scheduleId} | Update Audience Schedule for Audience |
1819

1920

2021

@@ -860,3 +861,82 @@ public class Example {
860861
| **422** | Validation failure | - |
861862
| **429** | Too many requests | - |
862863

864+
865+
## Operation: updateAudienceScheduleForAudience
866+
867+
> UpdateAudienceScheduleForAudience200Response updateAudienceScheduleForAudience(spaceId, id, scheduleId, updateAudienceScheduleForAudienceAlphaInput)
868+
869+
Update Audience Schedule for Audience
870+
871+
Updates an audience schedule for a Linked Audience (audienceType &#x3D; LINKED). • This endpoint is in **Alpha** testing. Please submit any feedback by sending an email to [email protected]. • In order to successfully call this endpoint, the specified Workspace needs to have the Audience feature enabled. Please reach out to your customer success manager for more information.
872+
873+
### Example
874+
875+
```java
876+
// Import classes:
877+
import com.segment.publicapi.ApiClient;
878+
import com.segment.publicapi.ApiException;
879+
import com.segment.publicapi.Configuration;
880+
import com.segment.publicapi.auth.*;
881+
import com.segment.publicapi.models.*;
882+
import com.segment.publicapi.api.AudiencesApi;
883+
884+
public class Example {
885+
public static void main(String[] args) {
886+
ApiClient defaultClient = Configuration.getDefaultApiClient();
887+
888+
// Configure HTTP bearer authorization: token
889+
HttpBearerAuth token = (HttpBearerAuth) defaultClient.getAuthentication("token");
890+
token.setBearerToken("BEARER TOKEN");
891+
892+
AudiencesApi apiInstance = new AudiencesApi(defaultClient);
893+
String spaceId = "9aQ1Lj62S4bomZKLF4DPqW"; // String |
894+
String id = "aud_0ujsszwN8NRY24YaXiTIE2VWDTS"; // String |
895+
String scheduleId = "sch_0ujsszwN8NRY24YaXiTIE2VWDTS"; // String |
896+
UpdateAudienceScheduleForAudienceAlphaInput updateAudienceScheduleForAudienceAlphaInput = new UpdateAudienceScheduleForAudienceAlphaInput(); // UpdateAudienceScheduleForAudienceAlphaInput |
897+
try {
898+
UpdateAudienceScheduleForAudience200Response result = apiInstance.updateAudienceScheduleForAudience(spaceId, id, scheduleId, updateAudienceScheduleForAudienceAlphaInput);
899+
System.out.println(result);
900+
} catch (ApiException e) {
901+
System.err.println("Exception when calling AudiencesApi#updateAudienceScheduleForAudience");
902+
System.err.println("Status code: " + e.getCode());
903+
System.err.println("Reason: " + e.getResponseBody());
904+
System.err.println("Response headers: " + e.getResponseHeaders());
905+
e.printStackTrace();
906+
}
907+
}
908+
}
909+
```
910+
911+
### Parameters
912+
913+
914+
| Name | Type | Description | Notes |
915+
|------------- | ------------- | ------------- | -------------|
916+
| **spaceId** | **String**| | |
917+
| **id** | **String**| | |
918+
| **scheduleId** | **String**| | |
919+
| **updateAudienceScheduleForAudienceAlphaInput** | [**UpdateAudienceScheduleForAudienceAlphaInput**](UpdateAudienceScheduleForAudienceAlphaInput.md)| | |
920+
921+
### Return type
922+
923+
[**UpdateAudienceScheduleForAudience200Response**](UpdateAudienceScheduleForAudience200Response.md)
924+
925+
### Authorization
926+
927+
[token](../README.md#token)
928+
929+
### HTTP request headers
930+
931+
- **Content-Type**: application/vnd.segment.v1alpha+json
932+
- **Accept**: application/vnd.segment.v1alpha+json, application/json
933+
934+
935+
### HTTP response details
936+
| Status code | Description | Response headers |
937+
|-------------|-------------|------------------|
938+
| **200** | OK | - |
939+
| **404** | Resource not found | - |
940+
| **422** | Validation failure | - |
941+
| **429** | Too many requests | - |
942+

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>59.4.0</version>
8+
<version>59.5.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 59.4.0 (Java)");
126+
setUserAgent("Public API SDK 59.5.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 = "59.4.0";
15+
public static final String VERSION = "59.5.0";
1616

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

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

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1652,6 +1652,15 @@ private static Class getClassByDiscriminator(
16521652
gsonBuilder.registerTypeAdapterFactory(
16531653
new com.segment.publicapi.models.UpdateAudienceForSpaceAlphaOutput
16541654
.CustomTypeAdapterFactory());
1655+
gsonBuilder.registerTypeAdapterFactory(
1656+
new com.segment.publicapi.models.UpdateAudienceScheduleForAudience200Response
1657+
.CustomTypeAdapterFactory());
1658+
gsonBuilder.registerTypeAdapterFactory(
1659+
new com.segment.publicapi.models.UpdateAudienceScheduleForAudienceAlphaInput
1660+
.CustomTypeAdapterFactory());
1661+
gsonBuilder.registerTypeAdapterFactory(
1662+
new com.segment.publicapi.models.UpdateAudienceScheduleForAudienceAlphaOutput
1663+
.CustomTypeAdapterFactory());
16551664
gsonBuilder.registerTypeAdapterFactory(
16561665
new com.segment.publicapi.models.UpdateComputedTraitForSpace200Response
16571666
.CustomTypeAdapterFactory());

0 commit comments

Comments
 (0)