Skip to content

Commit a9479ea

Browse files
SDK regeneration
1 parent fec6735 commit a9479ea

File tree

489 files changed

+64243
-24602
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

489 files changed

+64243
-24602
lines changed

.github/workflows/label-ai-generated-prs.yml

Lines changed: 0 additions & 11 deletions
This file was deleted.

README.md

Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,19 @@
22

33
[![fern shield](https://img.shields.io/badge/%F0%9F%8C%BF-Built%20with%20Fern-brightgreen)](https://buildwithfern.com?utm_source=github&utm_medium=github&utm_campaign=readme&utm_source=https%3A%2F%2Fgithub.com%2Fintercom%2Fintercom-java)
44

5-
The Intercom Java library provides convenient access to the Intercom API from Java.
5+
The Intercom Java library provides convenient access to the Intercom APIs from Java.
6+
7+
## Table of Contents
8+
9+
- [Usage](#usage)
10+
- [Environments](#environments)
11+
- [Base Url](#base-url)
12+
- [Exception Handling](#exception-handling)
13+
- [Advanced](#advanced)
14+
- [Custom Client](#custom-client)
15+
- [Retries](#retries)
16+
- [Timeouts](#timeouts)
17+
- [Contributing](#contributing)
618

719
## Usage
820

@@ -12,8 +24,7 @@ Instantiate and use the client with the following:
1224
package com.example.usage;
1325

1426
import com.intercom.api.Intercom;
15-
import com.intercom.api.resources.articles.requests.CreateArticleRequest;
16-
import com.intercom.api.resources.articles.types.CreateArticleRequestState;
27+
import com.intercom.api.resources.aicontent.requests.CreateContentImportSourceRequest;
1728

1829
public class Example {
1930
public static void main(String[] args) {
@@ -22,14 +33,11 @@ public class Example {
2233
.token("<token>")
2334
.build();
2435

25-
client.articles().create(
26-
CreateArticleRequest
36+
client.aiContent().createContentImportSource(
37+
CreateContentImportSourceRequest
2738
.builder()
28-
.title("Thanks for everything")
29-
.authorId(1295)
30-
.description("Description of the Article")
31-
.body("Body of the Article")
32-
.state(CreateArticleRequestState.PUBLISHED)
39+
.syncBehavior("api")
40+
.url("https://www.example.com")
3341
.build()
3442
);
3543
}
@@ -71,7 +79,7 @@ When the API returns a non-success status code (4xx or 5xx response), an API exc
7179
import com.intercom.api.core.IntercomApiApiException;
7280

7381
try {
74-
client.articles().create(...);
82+
client.aiContent().createContentImportSource(...);
7583
} catch (IntercomApiApiException e) {
7684
// Do something with the API exception...
7785
}
@@ -134,7 +142,7 @@ Intercom client = Intercom
134142
.build();
135143

136144
// Request level
137-
client.articles().create(
145+
client.aiContent().createContentImportSource(
138146
...,
139147
RequestOptions
140148
.builder()

build.gradle

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ java {
4646

4747
group = 'io.intercom'
4848

49-
version = '3.0.0'
49+
version = '3.1.0'
5050

5151
jar {
5252
dependsOn(":generatePomFileForMavenPublication")
@@ -77,7 +77,7 @@ publishing {
7777
maven(MavenPublication) {
7878
groupId = 'io.intercom'
7979
artifactId = 'intercom-java'
80-
version = '3.0.0'
80+
version = '3.1.0'
8181
from components.java
8282
pom {
8383
name = 'intercom'

src/main/java/com/intercom/api/AsyncIntercom.java

Lines changed: 76 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,14 +6,22 @@
66
import com.intercom.api.core.ClientOptions;
77
import com.intercom.api.core.Suppliers;
88
import com.intercom.api.resources.admins.AsyncAdminsClient;
9+
import com.intercom.api.resources.aicontent.AsyncAiContentClient;
910
import com.intercom.api.resources.articles.AsyncArticlesClient;
11+
import com.intercom.api.resources.awaystatusreasons.AsyncAwayStatusReasonsClient;
12+
import com.intercom.api.resources.calls.AsyncCallsClient;
1013
import com.intercom.api.resources.companies.AsyncCompaniesClient;
1114
import com.intercom.api.resources.contacts.AsyncContactsClient;
1215
import com.intercom.api.resources.conversations.AsyncConversationsClient;
16+
import com.intercom.api.resources.customchannelevents.AsyncCustomChannelEventsClient;
17+
import com.intercom.api.resources.customobjectinstances.AsyncCustomObjectInstancesClient;
1318
import com.intercom.api.resources.dataattributes.AsyncDataAttributesClient;
1419
import com.intercom.api.resources.dataexport.AsyncDataExportClient;
1520
import com.intercom.api.resources.events.AsyncEventsClient;
21+
import com.intercom.api.resources.export.AsyncExportClient;
1622
import com.intercom.api.resources.helpcenters.AsyncHelpCentersClient;
23+
import com.intercom.api.resources.internalarticles.AsyncInternalArticlesClient;
24+
import com.intercom.api.resources.jobs.AsyncJobsClient;
1725
import com.intercom.api.resources.messages.AsyncMessagesClient;
1826
import com.intercom.api.resources.news.AsyncNewsClient;
1927
import com.intercom.api.resources.notes.AsyncNotesClient;
@@ -23,6 +31,7 @@
2331
import com.intercom.api.resources.tags.AsyncTagsClient;
2432
import com.intercom.api.resources.teams.AsyncTeamsClient;
2533
import com.intercom.api.resources.tickets.AsyncTicketsClient;
34+
import com.intercom.api.resources.ticketstates.AsyncTicketStatesClient;
2635
import com.intercom.api.resources.tickettypes.AsyncTicketTypesClient;
2736
import com.intercom.api.resources.unstable.AsyncUnstableClient;
2837
import com.intercom.api.resources.visitors.AsyncVisitorsClient;
@@ -33,10 +42,20 @@ public class AsyncIntercom {
3342

3443
protected final Supplier<AsyncAdminsClient> adminsClient;
3544

45+
protected final Supplier<AsyncAiContentClient> aiContentClient;
46+
3647
protected final Supplier<AsyncArticlesClient> articlesClient;
3748

49+
protected final Supplier<AsyncAwayStatusReasonsClient> awayStatusReasonsClient;
50+
51+
protected final Supplier<AsyncExportClient> exportClient;
52+
53+
protected final Supplier<AsyncDataExportClient> dataExportClient;
54+
3855
protected final Supplier<AsyncHelpCentersClient> helpCentersClient;
3956

57+
protected final Supplier<AsyncInternalArticlesClient> internalArticlesClient;
58+
4059
protected final Supplier<AsyncCompaniesClient> companiesClient;
4160

4261
protected final Supplier<AsyncContactsClient> contactsClient;
@@ -47,11 +66,15 @@ public class AsyncIntercom {
4766

4867
protected final Supplier<AsyncConversationsClient> conversationsClient;
4968

69+
protected final Supplier<AsyncCustomChannelEventsClient> customChannelEventsClient;
70+
71+
protected final Supplier<AsyncCustomObjectInstancesClient> customObjectInstancesClient;
72+
5073
protected final Supplier<AsyncDataAttributesClient> dataAttributesClient;
5174

5275
protected final Supplier<AsyncEventsClient> eventsClient;
5376

54-
protected final Supplier<AsyncDataExportClient> dataExportClient;
77+
protected final Supplier<AsyncJobsClient> jobsClient;
5578

5679
protected final Supplier<AsyncMessagesClient> messagesClient;
5780

@@ -61,8 +84,12 @@ public class AsyncIntercom {
6184

6285
protected final Supplier<AsyncPhoneCallRedirectsClient> phoneCallRedirectsClient;
6386

87+
protected final Supplier<AsyncCallsClient> callsClient;
88+
6489
protected final Supplier<AsyncTeamsClient> teamsClient;
6590

91+
protected final Supplier<AsyncTicketStatesClient> ticketStatesClient;
92+
6693
protected final Supplier<AsyncTicketTypesClient> ticketTypesClient;
6794

6895
protected final Supplier<AsyncTicketsClient> ticketsClient;
@@ -76,21 +103,30 @@ public class AsyncIntercom {
76103
public AsyncIntercom(ClientOptions clientOptions) {
77104
this.clientOptions = clientOptions;
78105
this.adminsClient = Suppliers.memoize(() -> new AsyncAdminsClient(clientOptions));
106+
this.aiContentClient = Suppliers.memoize(() -> new AsyncAiContentClient(clientOptions));
79107
this.articlesClient = Suppliers.memoize(() -> new AsyncArticlesClient(clientOptions));
108+
this.awayStatusReasonsClient = Suppliers.memoize(() -> new AsyncAwayStatusReasonsClient(clientOptions));
109+
this.exportClient = Suppliers.memoize(() -> new AsyncExportClient(clientOptions));
110+
this.dataExportClient = Suppliers.memoize(() -> new AsyncDataExportClient(clientOptions));
80111
this.helpCentersClient = Suppliers.memoize(() -> new AsyncHelpCentersClient(clientOptions));
112+
this.internalArticlesClient = Suppliers.memoize(() -> new AsyncInternalArticlesClient(clientOptions));
81113
this.companiesClient = Suppliers.memoize(() -> new AsyncCompaniesClient(clientOptions));
82114
this.contactsClient = Suppliers.memoize(() -> new AsyncContactsClient(clientOptions));
83115
this.notesClient = Suppliers.memoize(() -> new AsyncNotesClient(clientOptions));
84116
this.tagsClient = Suppliers.memoize(() -> new AsyncTagsClient(clientOptions));
85117
this.conversationsClient = Suppliers.memoize(() -> new AsyncConversationsClient(clientOptions));
118+
this.customChannelEventsClient = Suppliers.memoize(() -> new AsyncCustomChannelEventsClient(clientOptions));
119+
this.customObjectInstancesClient = Suppliers.memoize(() -> new AsyncCustomObjectInstancesClient(clientOptions));
86120
this.dataAttributesClient = Suppliers.memoize(() -> new AsyncDataAttributesClient(clientOptions));
87121
this.eventsClient = Suppliers.memoize(() -> new AsyncEventsClient(clientOptions));
88-
this.dataExportClient = Suppliers.memoize(() -> new AsyncDataExportClient(clientOptions));
122+
this.jobsClient = Suppliers.memoize(() -> new AsyncJobsClient(clientOptions));
89123
this.messagesClient = Suppliers.memoize(() -> new AsyncMessagesClient(clientOptions));
90124
this.segmentsClient = Suppliers.memoize(() -> new AsyncSegmentsClient(clientOptions));
91125
this.subscriptionTypesClient = Suppliers.memoize(() -> new AsyncSubscriptionTypesClient(clientOptions));
92126
this.phoneCallRedirectsClient = Suppliers.memoize(() -> new AsyncPhoneCallRedirectsClient(clientOptions));
127+
this.callsClient = Suppliers.memoize(() -> new AsyncCallsClient(clientOptions));
93128
this.teamsClient = Suppliers.memoize(() -> new AsyncTeamsClient(clientOptions));
129+
this.ticketStatesClient = Suppliers.memoize(() -> new AsyncTicketStatesClient(clientOptions));
94130
this.ticketTypesClient = Suppliers.memoize(() -> new AsyncTicketTypesClient(clientOptions));
95131
this.ticketsClient = Suppliers.memoize(() -> new AsyncTicketsClient(clientOptions));
96132
this.visitorsClient = Suppliers.memoize(() -> new AsyncVisitorsClient(clientOptions));
@@ -102,14 +138,34 @@ public AsyncAdminsClient admins() {
102138
return this.adminsClient.get();
103139
}
104140

141+
public AsyncAiContentClient aiContent() {
142+
return this.aiContentClient.get();
143+
}
144+
105145
public AsyncArticlesClient articles() {
106146
return this.articlesClient.get();
107147
}
108148

149+
public AsyncAwayStatusReasonsClient awayStatusReasons() {
150+
return this.awayStatusReasonsClient.get();
151+
}
152+
153+
public AsyncExportClient export() {
154+
return this.exportClient.get();
155+
}
156+
157+
public AsyncDataExportClient dataExport() {
158+
return this.dataExportClient.get();
159+
}
160+
109161
public AsyncHelpCentersClient helpCenters() {
110162
return this.helpCentersClient.get();
111163
}
112164

165+
public AsyncInternalArticlesClient internalArticles() {
166+
return this.internalArticlesClient.get();
167+
}
168+
113169
public AsyncCompaniesClient companies() {
114170
return this.companiesClient.get();
115171
}
@@ -130,6 +186,14 @@ public AsyncConversationsClient conversations() {
130186
return this.conversationsClient.get();
131187
}
132188

189+
public AsyncCustomChannelEventsClient customChannelEvents() {
190+
return this.customChannelEventsClient.get();
191+
}
192+
193+
public AsyncCustomObjectInstancesClient customObjectInstances() {
194+
return this.customObjectInstancesClient.get();
195+
}
196+
133197
public AsyncDataAttributesClient dataAttributes() {
134198
return this.dataAttributesClient.get();
135199
}
@@ -138,8 +202,8 @@ public AsyncEventsClient events() {
138202
return this.eventsClient.get();
139203
}
140204

141-
public AsyncDataExportClient dataExport() {
142-
return this.dataExportClient.get();
205+
public AsyncJobsClient jobs() {
206+
return this.jobsClient.get();
143207
}
144208

145209
public AsyncMessagesClient messages() {
@@ -158,10 +222,18 @@ public AsyncPhoneCallRedirectsClient phoneCallRedirects() {
158222
return this.phoneCallRedirectsClient.get();
159223
}
160224

225+
public AsyncCallsClient calls() {
226+
return this.callsClient.get();
227+
}
228+
161229
public AsyncTeamsClient teams() {
162230
return this.teamsClient.get();
163231
}
164232

233+
public AsyncTicketStatesClient ticketStates() {
234+
return this.ticketStatesClient.get();
235+
}
236+
165237
public AsyncTicketTypesClient ticketTypes() {
166238
return this.ticketTypesClient.get();
167239
}

0 commit comments

Comments
 (0)