Skip to content

Commit f3af07d

Browse files
Merge pull request #13 from gleanwork/speakeasy-sdk-regen-1746237690
chore: 🐝 Update SDK - Generate GLEAN 0.1.0-beta.5
2 parents be55402 + bf14c50 commit f3af07d

File tree

23 files changed

+1233
-1176
lines changed

23 files changed

+1233
-1176
lines changed

.speakeasy/gen.lock

Lines changed: 6 additions & 8 deletions
Large diffs are not rendered by default.

.speakeasy/gen.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ generation:
2424
generateNewTests: true
2525
skipResponseBodyAssertions: true
2626
typescript:
27-
version: 0.1.0-beta.4
27+
version: 0.1.0-beta.5
2828
additionalDependencies:
2929
dependencies: {}
3030
devDependencies: {}

.speakeasy/glean-merged-spec.yaml

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,16 @@ info:
1111
# Usage guidelines
1212
This API is evolving fast. Glean will provide advance notice of any planned backwards incompatible changes along
1313
with a 6-month sunset period for anything that requires developers to adopt the new versions.
14+
15+
# API Clients
16+
Official API clients for the Glean Indexing API are available in multiple languages:
17+
18+
- [Python](https://github.com/gleanwork/api-client-python)
19+
- [TypeScript](https://github.com/gleanwork/api-client-typescript)
20+
- [Go](https://github.com/gleanwork/api-client-go)
21+
- [Java](https://github.com/gleanwork/api-client-java)
22+
23+
These API clients provide type-safe, idiomatic interfaces for working with Glean IndexingAPIs in your language of choice.
1424
x-logo:
1525
url: https://app.glean.com/images/glean-text2.svg
1626
x-speakeasy-name: "Glean API"
@@ -3142,6 +3152,9 @@ paths:
31423152
description: Request Timeout
31433153
'429':
31443154
description: Too Many Requests
3155+
x-speakeasy-group: client.chat
3156+
x-speakeasy-name-override: startStream
3157+
x-speakeasy-usage-example: true
31453158
components:
31463159
securitySchemes:
31473160
BearerAuth:

.speakeasy/workflow.lock

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,11 +2,11 @@ speakeasyVersion: 1.542.0
22
sources:
33
Glean API:
44
sourceNamespace: glean-api-specs
5-
sourceRevisionDigest: sha256:d40d70c4d92691d51a53fa22799793ca4113defb0713b48b8f0eddbbaff0eb66
6-
sourceBlobDigest: sha256:a0e8b1ed041891821639f1eef8b320b46870ca17109c1ed15712cf112b462763
5+
sourceRevisionDigest: sha256:011632a1ad4a281f6009d6b332829448c0f742f2a1fc45a3c51d61aa3f63d5e7
6+
sourceBlobDigest: sha256:ce8abdf11ef3db8d29f3073665e1c24ea1ec3f3cd01dd59d42c51aa785e6daaa
77
tags:
88
- latest
9-
- speakeasy-sdk-regen-1746231561
9+
- speakeasy-sdk-regen-1746237690
1010
Glean Client API:
1111
sourceNamespace: glean-client-api
1212
sourceRevisionDigest: sha256:aec0770b5bcca91068c3a844cb9ef4a091281f6cc3b7d86f2abef1bd6fb2b301
@@ -18,10 +18,10 @@ targets:
1818
glean:
1919
source: Glean API
2020
sourceNamespace: glean-api-specs
21-
sourceRevisionDigest: sha256:d40d70c4d92691d51a53fa22799793ca4113defb0713b48b8f0eddbbaff0eb66
22-
sourceBlobDigest: sha256:a0e8b1ed041891821639f1eef8b320b46870ca17109c1ed15712cf112b462763
21+
sourceRevisionDigest: sha256:011632a1ad4a281f6009d6b332829448c0f742f2a1fc45a3c51d61aa3f63d5e7
22+
sourceBlobDigest: sha256:ce8abdf11ef3db8d29f3073665e1c24ea1ec3f3cd01dd59d42c51aa785e6daaa
2323
codeSamplesNamespace: glean-api-specs-typescript-code-samples
24-
codeSamplesRevisionDigest: sha256:063ac68018659a5bae05115d771c3b6ff251061553cf205e78c18e4ba8b4d8f6
24+
codeSamplesRevisionDigest: sha256:93941774f25257d750204ce4e5c57faccf7adb5a1a05d37658db4f5cc95b62b5
2525
workflow:
2626
workflowVersion: 1.0.0
2727
speakeasyVersion: latest

README.md

Lines changed: 62 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,7 @@ For supported JavaScript runtimes, please consult [RUNTIMES.md](RUNTIMES.md).
7979
<!-- Start SDK Example Usage [usage] -->
8080
## SDK Example Usage
8181

82-
### Example
82+
### Example 1
8383

8484
```typescript
8585
import { Glean } from "@gleanwork/api-client";
@@ -107,6 +107,36 @@ async function run() {
107107

108108
run();
109109

110+
```
111+
112+
### Example 2
113+
114+
```typescript
115+
import { Glean } from "@gleanwork/api-client";
116+
117+
const glean = new Glean({
118+
bearerAuth: process.env["GLEAN_BEARER_AUTH"] ?? "",
119+
});
120+
121+
async function run() {
122+
const result = await glean.client.chat.startStream({
123+
messages: [
124+
{
125+
fragments: [
126+
{
127+
text: "What are the company holidays this year?",
128+
},
129+
],
130+
},
131+
],
132+
});
133+
134+
// Handle the result
135+
console.log(result);
136+
}
137+
138+
run();
139+
110140
```
111141
<!-- End SDK Example Usage [usage] -->
112142

@@ -175,10 +205,6 @@ run();
175205
* [listagents](docs/sdks/agents/README.md#listagents) - Lists all agents.
176206
* [getagentinputs](docs/sdks/agents/README.md#getagentinputs) - Gets the inputs to an agent.
177207

178-
### [chat](docs/sdks/chat/README.md)
179-
180-
* [chatStream](docs/sdks/chat/README.md#chatstream) - Chat
181-
182208
### [client](docs/sdks/client/README.md)
183209

184210

@@ -208,17 +234,18 @@ run();
208234

209235
* [createToken](docs/sdks/clientauthentication/README.md#createtoken) - Create authentication token
210236

211-
#### [client.chat](docs/sdks/clientchat/README.md)
237+
#### [client.chat](docs/sdks/chat/README.md)
212238

213-
* [start](docs/sdks/clientchat/README.md#start) - Chat
214-
* [deleteAll](docs/sdks/clientchat/README.md#deleteall) - Deletes all saved Chats owned by a user
215-
* [delete](docs/sdks/clientchat/README.md#delete) - Deletes saved Chats
216-
* [get](docs/sdks/clientchat/README.md#get) - Retrieves a Chat
217-
* [list](docs/sdks/clientchat/README.md#list) - Retrieves all saved Chats
218-
* [getApplication](docs/sdks/clientchat/README.md#getapplication) - Gets the metadata for a custom Chat application
219-
* [uploadFiles](docs/sdks/clientchat/README.md#uploadfiles) - Upload files for Chat.
220-
* [getFiles](docs/sdks/clientchat/README.md#getfiles) - Get files uploaded by a user for Chat.
221-
* [deleteFiles](docs/sdks/clientchat/README.md#deletefiles) - Delete files uploaded by a user for chat.
239+
* [start](docs/sdks/chat/README.md#start) - Chat
240+
* [deleteAll](docs/sdks/chat/README.md#deleteall) - Deletes all saved Chats owned by a user
241+
* [delete](docs/sdks/chat/README.md#delete) - Deletes saved Chats
242+
* [get](docs/sdks/chat/README.md#get) - Retrieves a Chat
243+
* [list](docs/sdks/chat/README.md#list) - Retrieves all saved Chats
244+
* [getApplication](docs/sdks/chat/README.md#getapplication) - Gets the metadata for a custom Chat application
245+
* [uploadFiles](docs/sdks/chat/README.md#uploadfiles) - Upload files for Chat.
246+
* [getFiles](docs/sdks/chat/README.md#getfiles) - Get files uploaded by a user for Chat.
247+
* [deleteFiles](docs/sdks/chat/README.md#deletefiles) - Delete files uploaded by a user for chat.
248+
* [startStream](docs/sdks/chat/README.md#startstream) - Chat
222249

223250
#### [client.collections](docs/sdks/collections/README.md)
224251

@@ -372,7 +399,6 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
372399
- [`agentsGetagentinputs`](docs/sdks/agents/README.md#getagentinputs) - Gets the inputs to an agent.
373400
- [`agentsListagents`](docs/sdks/agents/README.md#listagents) - Lists all agents.
374401
- [`agentsRunagent`](docs/sdks/agents/README.md#runagent) - Runs an Agent.
375-
- [`chatChatStream`](docs/sdks/chat/README.md#chatstream) - Chat
376402
- [`clientActivitiesReportActivity`](docs/sdks/activities/README.md#reportactivity) - Report client activity
377403
- [`clientActivityReport`](docs/sdks/activity/README.md#report) - Report document activity
378404
- [`clientAnnouncementsCreate`](docs/sdks/announcements/README.md#create) - Create Announcement
@@ -384,15 +410,16 @@ To read more about standalone functions, check [FUNCTIONS.md](./FUNCTIONS.md).
384410
- [`clientAnswersGet`](docs/sdks/answers/README.md#get) - Read Answer
385411
- [`clientAnswersList`](docs/sdks/answers/README.md#list) - List Answers
386412
- [`clientAuthenticationCreateToken`](docs/sdks/clientauthentication/README.md#createtoken) - Create authentication token
387-
- [`clientChatDelete`](docs/sdks/clientchat/README.md#delete) - Deletes saved Chats
388-
- [`clientChatDeleteAll`](docs/sdks/clientchat/README.md#deleteall) - Deletes all saved Chats owned by a user
389-
- [`clientChatDeleteFiles`](docs/sdks/clientchat/README.md#deletefiles) - Delete files uploaded by a user for chat.
390-
- [`clientChatGet`](docs/sdks/clientchat/README.md#get) - Retrieves a Chat
391-
- [`clientChatGetApplication`](docs/sdks/clientchat/README.md#getapplication) - Gets the metadata for a custom Chat application
392-
- [`clientChatGetFiles`](docs/sdks/clientchat/README.md#getfiles) - Get files uploaded by a user for Chat.
393-
- [`clientChatList`](docs/sdks/clientchat/README.md#list) - Retrieves all saved Chats
394-
- [`clientChatStart`](docs/sdks/clientchat/README.md#start) - Chat
395-
- [`clientChatUploadFiles`](docs/sdks/clientchat/README.md#uploadfiles) - Upload files for Chat.
413+
- [`clientChatDelete`](docs/sdks/chat/README.md#delete) - Deletes saved Chats
414+
- [`clientChatDeleteAll`](docs/sdks/chat/README.md#deleteall) - Deletes all saved Chats owned by a user
415+
- [`clientChatDeleteFiles`](docs/sdks/chat/README.md#deletefiles) - Delete files uploaded by a user for chat.
416+
- [`clientChatGet`](docs/sdks/chat/README.md#get) - Retrieves a Chat
417+
- [`clientChatGetApplication`](docs/sdks/chat/README.md#getapplication) - Gets the metadata for a custom Chat application
418+
- [`clientChatGetFiles`](docs/sdks/chat/README.md#getfiles) - Get files uploaded by a user for Chat.
419+
- [`clientChatList`](docs/sdks/chat/README.md#list) - Retrieves all saved Chats
420+
- [`clientChatStart`](docs/sdks/chat/README.md#start) - Chat
421+
- [`clientChatStartStream`](docs/sdks/chat/README.md#startstream) - Chat
422+
- [`clientChatUploadFiles`](docs/sdks/chat/README.md#uploadfiles) - Upload files for Chat.
396423
- [`clientCollectionsAddItems`](docs/sdks/collections/README.md#additems) - Add Collection item
397424
- [`clientCollectionsCreate`](docs/sdks/collections/README.md#create) - Create Collection
398425
- [`clientCollectionsDelete`](docs/sdks/collections/README.md#delete) - Delete Collection
@@ -498,7 +525,6 @@ To learn about this feature and how to get started, check
498525
- [`useAgentsGetagentinputsMutation`](docs/sdks/agents/README.md#getagentinputs) - Gets the inputs to an agent.
499526
- [`useAgentsListagentsMutation`](docs/sdks/agents/README.md#listagents) - Lists all agents.
500527
- [`useAgentsRunagentMutation`](docs/sdks/agents/README.md#runagent) - Runs an Agent.
501-
- [`useChatChatStreamMutation`](docs/sdks/chat/README.md#chatstream) - Chat
502528
- [`useClientActivitiesReportActivityMutation`](docs/sdks/activities/README.md#reportactivity) - Report client activity
503529
- [`useClientActivityReportMutation`](docs/sdks/activity/README.md#report) - Report document activity
504530
- [`useClientAnnouncementsCreateMutation`](docs/sdks/announcements/README.md#create) - Create Announcement
@@ -510,15 +536,16 @@ To learn about this feature and how to get started, check
510536
- [`useClientAnswersGetMutation`](docs/sdks/answers/README.md#get) - Read Answer
511537
- [`useClientAnswersListMutation`](docs/sdks/answers/README.md#list) - List Answers
512538
- [`useClientAuthenticationCreateTokenMutation`](docs/sdks/clientauthentication/README.md#createtoken) - Create authentication token
513-
- [`useClientChatDeleteAllMutation`](docs/sdks/clientchat/README.md#deleteall) - Deletes all saved Chats owned by a user
514-
- [`useClientChatDeleteFilesMutation`](docs/sdks/clientchat/README.md#deletefiles) - Delete files uploaded by a user for chat.
515-
- [`useClientChatDeleteMutation`](docs/sdks/clientchat/README.md#delete) - Deletes saved Chats
516-
- [`useClientChatGetApplicationMutation`](docs/sdks/clientchat/README.md#getapplication) - Gets the metadata for a custom Chat application
517-
- [`useClientChatGetFilesMutation`](docs/sdks/clientchat/README.md#getfiles) - Get files uploaded by a user for Chat.
518-
- [`useClientChatGetMutation`](docs/sdks/clientchat/README.md#get) - Retrieves a Chat
519-
- [`useClientChatListMutation`](docs/sdks/clientchat/README.md#list) - Retrieves all saved Chats
520-
- [`useClientChatStartMutation`](docs/sdks/clientchat/README.md#start) - Chat
521-
- [`useClientChatUploadFilesMutation`](docs/sdks/clientchat/README.md#uploadfiles) - Upload files for Chat.
539+
- [`useClientChatDeleteAllMutation`](docs/sdks/chat/README.md#deleteall) - Deletes all saved Chats owned by a user
540+
- [`useClientChatDeleteFilesMutation`](docs/sdks/chat/README.md#deletefiles) - Delete files uploaded by a user for chat.
541+
- [`useClientChatDeleteMutation`](docs/sdks/chat/README.md#delete) - Deletes saved Chats
542+
- [`useClientChatGetApplicationMutation`](docs/sdks/chat/README.md#getapplication) - Gets the metadata for a custom Chat application
543+
- [`useClientChatGetFilesMutation`](docs/sdks/chat/README.md#getfiles) - Get files uploaded by a user for Chat.
544+
- [`useClientChatGetMutation`](docs/sdks/chat/README.md#get) - Retrieves a Chat
545+
- [`useClientChatListMutation`](docs/sdks/chat/README.md#list) - Retrieves all saved Chats
546+
- [`useClientChatStartMutation`](docs/sdks/chat/README.md#start) - Chat
547+
- [`useClientChatStartStreamMutation`](docs/sdks/chat/README.md#startstream) - Chat
548+
- [`useClientChatUploadFilesMutation`](docs/sdks/chat/README.md#uploadfiles) - Upload files for Chat.
522549
- [`useClientCollectionsAddItemsMutation`](docs/sdks/collections/README.md#additems) - Add Collection item
523550
- [`useClientCollectionsCreateMutation`](docs/sdks/collections/README.md#create) - Create Collection
524551
- [`useClientCollectionsDeleteItemMutation`](docs/sdks/collections/README.md#deleteitem) - Delete Collection item

RELEASES.md

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,14 @@ Based on:
3838
### Generated
3939
- [typescript v0.1.0-beta.4] .
4040
### Releases
41-
- [NPM v0.1.0-beta.4] https://www.npmjs.com/package/@gleanwork/api-client/v/0.1.0-beta.4 - .
41+
- [NPM v0.1.0-beta.4] https://www.npmjs.com/package/@gleanwork/api-client/v/0.1.0-beta.4 - .
42+
43+
## 2025-05-03 15:07:16
44+
### Changes
45+
Based on:
46+
- OpenAPI Doc
47+
- Speakeasy CLI 1.542.0 (2.596.2) https://github.com/speakeasy-api/speakeasy
48+
### Generated
49+
- [typescript v0.1.0-beta.5] .
50+
### Releases
51+
- [NPM v0.1.0-beta.5] https://www.npmjs.com/package/@gleanwork/api-client/v/0.1.0-beta.5 - .

USAGE.md

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,5 +25,33 @@ async function run() {
2525

2626
run();
2727

28+
```
29+
30+
```typescript
31+
import { Glean } from "@gleanwork/api-client";
32+
33+
const glean = new Glean({
34+
bearerAuth: process.env["GLEAN_BEARER_AUTH"] ?? "",
35+
});
36+
37+
async function run() {
38+
const result = await glean.client.chat.startStream({
39+
messages: [
40+
{
41+
fragments: [
42+
{
43+
text: "What are the company holidays this year?",
44+
},
45+
],
46+
},
47+
],
48+
});
49+
50+
// Handle the result
51+
console.log(result);
52+
}
53+
54+
run();
55+
2856
```
2957
<!-- End SDK Example Usage [usage] -->

0 commit comments

Comments
 (0)