syllable-sdk 0.1.0-alpha.43 → 0.1.0-alpha.45
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -2
- package/docs/sdks/datasources/README.md +26 -18
- package/docs/sdks/v1/README.md +158 -0
- package/funcs/dataSourcesDelete.d.ts.map +1 -1
- package/funcs/dataSourcesDelete.js +5 -2
- package/funcs/dataSourcesDelete.js.map +1 -1
- package/funcs/{dataSourcesGetByName.d.ts → dataSourcesGetById.d.ts} +2 -2
- package/funcs/dataSourcesGetById.d.ts.map +1 -0
- package/funcs/dataSourcesGetById.js +108 -0
- package/funcs/dataSourcesGetById.js.map +1 -0
- package/funcs/v1Delete.d.ts +16 -0
- package/funcs/v1Delete.d.ts.map +1 -0
- package/funcs/v1Delete.js +112 -0
- package/funcs/v1Delete.js.map +1 -0
- package/funcs/v1GetById.d.ts +17 -0
- package/funcs/v1GetById.d.ts.map +1 -0
- package/funcs/{dataSourcesGetByName.js → v1GetById.js} +10 -7
- package/funcs/v1GetById.js.map +1 -0
- package/jsr.json +1 -1
- package/lib/config.d.ts +2 -2
- package/lib/config.js +2 -2
- package/mintlify/mint.json +3 -0
- package/models/components/datasourcecreaterequest.d.ts +3 -3
- package/models/components/datasourcecreaterequest.d.ts.map +1 -1
- package/models/components/datasourcecreaterequest.js +2 -2
- package/models/components/datasourcecreaterequest.js.map +1 -1
- package/models/components/datasourcedetailresponse.d.ts +8 -3
- package/models/components/datasourcedetailresponse.d.ts.map +1 -1
- package/models/components/datasourcedetailresponse.js +4 -2
- package/models/components/datasourcedetailresponse.js.map +1 -1
- package/models/components/datasourcemetadataresponse.d.ts +8 -3
- package/models/components/datasourcemetadataresponse.d.ts.map +1 -1
- package/models/components/datasourcemetadataresponse.js +4 -2
- package/models/components/datasourcemetadataresponse.js.map +1 -1
- package/models/components/datasourceupdaterequest.d.ts +8 -3
- package/models/components/datasourceupdaterequest.d.ts.map +1 -1
- package/models/components/datasourceupdaterequest.js +4 -2
- package/models/components/datasourceupdaterequest.js.map +1 -1
- package/models/components/index.d.ts +1 -0
- package/models/components/index.d.ts.map +1 -1
- package/models/components/index.js +1 -0
- package/models/components/index.js.map +1 -1
- package/models/components/tooldetailresponse.d.ts +6 -0
- package/models/components/tooldetailresponse.d.ts.map +1 -1
- package/models/components/tooldetailresponse.js +5 -0
- package/models/components/tooldetailresponse.js.map +1 -1
- package/models/components/toolpromptinfo.d.ts +40 -0
- package/models/components/toolpromptinfo.d.ts.map +1 -0
- package/models/components/toolpromptinfo.js +61 -0
- package/models/components/toolpromptinfo.js.map +1 -0
- package/models/components/toolresponse.d.ts +6 -0
- package/models/components/toolresponse.d.ts.map +1 -1
- package/models/components/toolresponse.js +5 -0
- package/models/components/toolresponse.js.map +1 -1
- package/models/operations/datasourcesdelete.d.ts +2 -2
- package/models/operations/datasourcesdelete.d.ts.map +1 -1
- package/models/operations/datasourcesdelete.js +4 -4
- package/models/operations/datasourcesdelete.js.map +1 -1
- package/models/operations/datasourcesgetbyid.d.ts +29 -0
- package/models/operations/datasourcesgetbyid.d.ts.map +1 -0
- package/models/operations/{datasourcesgetbyname.js → datasourcesgetbyid.js} +21 -21
- package/models/operations/datasourcesgetbyid.js.map +1 -0
- package/models/operations/index.d.ts +1 -1
- package/models/operations/index.d.ts.map +1 -1
- package/models/operations/index.js +1 -1
- package/models/operations/index.js.map +1 -1
- package/openapi.json +176 -61
- package/package.json +1 -1
- package/sdk/datasources.d.ts +1 -1
- package/sdk/datasources.d.ts.map +1 -1
- package/sdk/datasources.js +3 -3
- package/sdk/datasources.js.map +1 -1
- package/sdk/sdk.d.ts +2 -2
- package/sdk/sdk.d.ts.map +1 -1
- package/sdk/sdk.js +3 -3
- package/sdk/sdk.js.map +1 -1
- package/sdk/v1.d.ts +14 -0
- package/sdk/v1.d.ts.map +1 -1
- package/sdk/v1.js +20 -0
- package/sdk/v1.js.map +1 -1
- package/src/funcs/dataSourcesDelete.ts +5 -8
- package/src/funcs/{dataSourcesGetByName.ts → dataSourcesGetById.ts} +9 -13
- package/src/funcs/v1Delete.ts +147 -0
- package/src/funcs/v1GetById.ts +142 -0
- package/src/lib/config.ts +2 -2
- package/src/models/components/datasourcecreaterequest.ts +5 -5
- package/src/models/components/datasourcedetailresponse.ts +12 -5
- package/src/models/components/datasourcemetadataresponse.ts +12 -5
- package/src/models/components/datasourceupdaterequest.ts +12 -5
- package/src/models/components/index.ts +1 -0
- package/src/models/components/tooldetailresponse.ts +15 -0
- package/src/models/components/toolpromptinfo.ts +75 -0
- package/src/models/components/toolresponse.ts +15 -0
- package/src/models/operations/datasourcesdelete.ts +6 -6
- package/src/models/operations/datasourcesgetbyid.ts +75 -0
- package/src/models/operations/index.ts +1 -1
- package/src/sdk/datasources.ts +4 -4
- package/src/sdk/sdk.ts +5 -5
- package/src/sdk/v1.ts +36 -0
- package/funcs/dataSourcesGetByName.d.ts.map +0 -1
- package/funcs/dataSourcesGetByName.js.map +0 -1
- package/models/operations/datasourcesgetbyname.d.ts +0 -29
- package/models/operations/datasourcesgetbyname.d.ts.map +0 -1
- package/models/operations/datasourcesgetbyname.js.map +0 -1
- package/src/models/operations/datasourcesgetbyname.ts +0 -77
|
@@ -59,16 +59,13 @@ export async function dataSourcesDelete(
|
|
|
59
59
|
const body = null;
|
|
60
60
|
|
|
61
61
|
const pathParams = {
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
),
|
|
62
|
+
data_source_id: encodeSimple("data_source_id", payload.data_source_id, {
|
|
63
|
+
explode: false,
|
|
64
|
+
charEncoding: "percent",
|
|
65
|
+
}),
|
|
67
66
|
};
|
|
68
67
|
|
|
69
|
-
const path = pathToFunc("/api/v1/data_sources/{
|
|
70
|
-
pathParams,
|
|
71
|
-
);
|
|
68
|
+
const path = pathToFunc("/api/v1/data_sources/{data_source_id}")(pathParams);
|
|
72
69
|
|
|
73
70
|
const query = encodeFormQuery({
|
|
74
71
|
"reason": payload.reason,
|
|
@@ -30,9 +30,9 @@ import { Result } from "../types/fp.js";
|
|
|
30
30
|
* @remarks
|
|
31
31
|
* Fetch a given data source, including its text.
|
|
32
32
|
*/
|
|
33
|
-
export async function
|
|
33
|
+
export async function dataSourcesGetById(
|
|
34
34
|
client: SyllableSDKCore,
|
|
35
|
-
request: operations.
|
|
35
|
+
request: operations.DataSourcesGetByIdRequest,
|
|
36
36
|
options?: RequestOptions,
|
|
37
37
|
): Promise<
|
|
38
38
|
Result<
|
|
@@ -49,8 +49,7 @@ export async function dataSourcesGetByName(
|
|
|
49
49
|
> {
|
|
50
50
|
const parsed = safeParse(
|
|
51
51
|
request,
|
|
52
|
-
(value) =>
|
|
53
|
-
operations.DataSourcesGetByNameRequest$outboundSchema.parse(value),
|
|
52
|
+
(value) => operations.DataSourcesGetByIdRequest$outboundSchema.parse(value),
|
|
54
53
|
"Input validation failed",
|
|
55
54
|
);
|
|
56
55
|
if (!parsed.ok) {
|
|
@@ -60,16 +59,13 @@ export async function dataSourcesGetByName(
|
|
|
60
59
|
const body = null;
|
|
61
60
|
|
|
62
61
|
const pathParams = {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
),
|
|
62
|
+
data_source_id: encodeSimple("data_source_id", payload.data_source_id, {
|
|
63
|
+
explode: false,
|
|
64
|
+
charEncoding: "percent",
|
|
65
|
+
}),
|
|
68
66
|
};
|
|
69
67
|
|
|
70
|
-
const path = pathToFunc("/api/v1/data_sources/{
|
|
71
|
-
pathParams,
|
|
72
|
-
);
|
|
68
|
+
const path = pathToFunc("/api/v1/data_sources/{data_source_id}")(pathParams);
|
|
73
69
|
|
|
74
70
|
const headers = new Headers(compactMap({
|
|
75
71
|
Accept: "application/json",
|
|
@@ -81,7 +77,7 @@ export async function dataSourcesGetByName(
|
|
|
81
77
|
|
|
82
78
|
const context = {
|
|
83
79
|
baseURL: options?.serverURL ?? "",
|
|
84
|
-
operationID: "
|
|
80
|
+
operationID: "data_sources_get_by_id",
|
|
85
81
|
oAuth2Scopes: [],
|
|
86
82
|
|
|
87
83
|
resolvedSecurity: requestSecurity,
|
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import * as z from "zod";
|
|
6
|
+
import { SyllableSDKCore } from "../core.js";
|
|
7
|
+
import { encodeFormQuery, encodeSimple } from "../lib/encodings.js";
|
|
8
|
+
import * as M from "../lib/matchers.js";
|
|
9
|
+
import { compactMap } from "../lib/primitives.js";
|
|
10
|
+
import { safeParse } from "../lib/schemas.js";
|
|
11
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
12
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
13
|
+
import { pathToFunc } from "../lib/url.js";
|
|
14
|
+
import {
|
|
15
|
+
ConnectionError,
|
|
16
|
+
InvalidRequestError,
|
|
17
|
+
RequestAbortedError,
|
|
18
|
+
RequestTimeoutError,
|
|
19
|
+
UnexpectedClientError,
|
|
20
|
+
} from "../models/errors/httpclienterrors.js";
|
|
21
|
+
import * as errors from "../models/errors/index.js";
|
|
22
|
+
import { SDKError } from "../models/errors/sdkerror.js";
|
|
23
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
24
|
+
import * as operations from "../models/operations/index.js";
|
|
25
|
+
import { Result } from "../types/fp.js";
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Delete Data Source
|
|
29
|
+
*
|
|
30
|
+
* @remarks
|
|
31
|
+
* Delete a given data source.
|
|
32
|
+
*/
|
|
33
|
+
export async function v1Delete(
|
|
34
|
+
client: SyllableSDKCore,
|
|
35
|
+
request: operations.DataSourcesDeleteRequest,
|
|
36
|
+
options?: RequestOptions,
|
|
37
|
+
): Promise<
|
|
38
|
+
Result<
|
|
39
|
+
any,
|
|
40
|
+
| errors.HTTPValidationError
|
|
41
|
+
| SDKError
|
|
42
|
+
| SDKValidationError
|
|
43
|
+
| UnexpectedClientError
|
|
44
|
+
| InvalidRequestError
|
|
45
|
+
| RequestAbortedError
|
|
46
|
+
| RequestTimeoutError
|
|
47
|
+
| ConnectionError
|
|
48
|
+
>
|
|
49
|
+
> {
|
|
50
|
+
const parsed = safeParse(
|
|
51
|
+
request,
|
|
52
|
+
(value) => operations.DataSourcesDeleteRequest$outboundSchema.parse(value),
|
|
53
|
+
"Input validation failed",
|
|
54
|
+
);
|
|
55
|
+
if (!parsed.ok) {
|
|
56
|
+
return parsed;
|
|
57
|
+
}
|
|
58
|
+
const payload = parsed.value;
|
|
59
|
+
const body = null;
|
|
60
|
+
|
|
61
|
+
const pathParams = {
|
|
62
|
+
data_source_id: encodeSimple("data_source_id", payload.data_source_id, {
|
|
63
|
+
explode: false,
|
|
64
|
+
charEncoding: "percent",
|
|
65
|
+
}),
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
const path = pathToFunc("/api/v1/data_sources/{data_source_id}")(pathParams);
|
|
69
|
+
|
|
70
|
+
const query = encodeFormQuery({
|
|
71
|
+
"reason": payload.reason,
|
|
72
|
+
});
|
|
73
|
+
|
|
74
|
+
const headers = new Headers(compactMap({
|
|
75
|
+
Accept: "application/json",
|
|
76
|
+
}));
|
|
77
|
+
|
|
78
|
+
const secConfig = await extractSecurity(client._options.apiKeyHeader);
|
|
79
|
+
const securityInput = secConfig == null ? {} : { apiKeyHeader: secConfig };
|
|
80
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
81
|
+
|
|
82
|
+
const context = {
|
|
83
|
+
baseURL: options?.serverURL ?? "",
|
|
84
|
+
operationID: "data_sources_delete",
|
|
85
|
+
oAuth2Scopes: [],
|
|
86
|
+
|
|
87
|
+
resolvedSecurity: requestSecurity,
|
|
88
|
+
|
|
89
|
+
securitySource: client._options.apiKeyHeader,
|
|
90
|
+
retryConfig: options?.retries
|
|
91
|
+
|| client._options.retryConfig
|
|
92
|
+
|| { strategy: "none" },
|
|
93
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
94
|
+
};
|
|
95
|
+
|
|
96
|
+
const requestRes = client._createRequest(context, {
|
|
97
|
+
security: requestSecurity,
|
|
98
|
+
method: "DELETE",
|
|
99
|
+
baseURL: options?.serverURL,
|
|
100
|
+
path: path,
|
|
101
|
+
headers: headers,
|
|
102
|
+
query: query,
|
|
103
|
+
body: body,
|
|
104
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
105
|
+
}, options);
|
|
106
|
+
if (!requestRes.ok) {
|
|
107
|
+
return requestRes;
|
|
108
|
+
}
|
|
109
|
+
const req = requestRes.value;
|
|
110
|
+
|
|
111
|
+
const doResult = await client._do(req, {
|
|
112
|
+
context,
|
|
113
|
+
errorCodes: ["422", "4XX", "5XX"],
|
|
114
|
+
retryConfig: context.retryConfig,
|
|
115
|
+
retryCodes: context.retryCodes,
|
|
116
|
+
});
|
|
117
|
+
if (!doResult.ok) {
|
|
118
|
+
return doResult;
|
|
119
|
+
}
|
|
120
|
+
const response = doResult.value;
|
|
121
|
+
|
|
122
|
+
const responseFields = {
|
|
123
|
+
HttpMeta: { Response: response, Request: req },
|
|
124
|
+
};
|
|
125
|
+
|
|
126
|
+
const [result] = await M.match<
|
|
127
|
+
any,
|
|
128
|
+
| errors.HTTPValidationError
|
|
129
|
+
| SDKError
|
|
130
|
+
| SDKValidationError
|
|
131
|
+
| UnexpectedClientError
|
|
132
|
+
| InvalidRequestError
|
|
133
|
+
| RequestAbortedError
|
|
134
|
+
| RequestTimeoutError
|
|
135
|
+
| ConnectionError
|
|
136
|
+
>(
|
|
137
|
+
M.json(200, z.any()),
|
|
138
|
+
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
139
|
+
M.fail("4XX"),
|
|
140
|
+
M.fail("5XX"),
|
|
141
|
+
)(response, { extraFields: responseFields });
|
|
142
|
+
if (!result.ok) {
|
|
143
|
+
return result;
|
|
144
|
+
}
|
|
145
|
+
|
|
146
|
+
return result;
|
|
147
|
+
}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
/*
|
|
2
|
+
* Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
import { SyllableSDKCore } from "../core.js";
|
|
6
|
+
import { encodeSimple } from "../lib/encodings.js";
|
|
7
|
+
import * as M from "../lib/matchers.js";
|
|
8
|
+
import { compactMap } from "../lib/primitives.js";
|
|
9
|
+
import { safeParse } from "../lib/schemas.js";
|
|
10
|
+
import { RequestOptions } from "../lib/sdks.js";
|
|
11
|
+
import { extractSecurity, resolveGlobalSecurity } from "../lib/security.js";
|
|
12
|
+
import { pathToFunc } from "../lib/url.js";
|
|
13
|
+
import * as components from "../models/components/index.js";
|
|
14
|
+
import {
|
|
15
|
+
ConnectionError,
|
|
16
|
+
InvalidRequestError,
|
|
17
|
+
RequestAbortedError,
|
|
18
|
+
RequestTimeoutError,
|
|
19
|
+
UnexpectedClientError,
|
|
20
|
+
} from "../models/errors/httpclienterrors.js";
|
|
21
|
+
import * as errors from "../models/errors/index.js";
|
|
22
|
+
import { SDKError } from "../models/errors/sdkerror.js";
|
|
23
|
+
import { SDKValidationError } from "../models/errors/sdkvalidationerror.js";
|
|
24
|
+
import * as operations from "../models/operations/index.js";
|
|
25
|
+
import { Result } from "../types/fp.js";
|
|
26
|
+
|
|
27
|
+
/**
|
|
28
|
+
* Get Data Source
|
|
29
|
+
*
|
|
30
|
+
* @remarks
|
|
31
|
+
* Fetch a given data source, including its text.
|
|
32
|
+
*/
|
|
33
|
+
export async function v1GetById(
|
|
34
|
+
client: SyllableSDKCore,
|
|
35
|
+
request: operations.DataSourcesGetByIdRequest,
|
|
36
|
+
options?: RequestOptions,
|
|
37
|
+
): Promise<
|
|
38
|
+
Result<
|
|
39
|
+
components.DataSourceDetailResponse,
|
|
40
|
+
| errors.HTTPValidationError
|
|
41
|
+
| SDKError
|
|
42
|
+
| SDKValidationError
|
|
43
|
+
| UnexpectedClientError
|
|
44
|
+
| InvalidRequestError
|
|
45
|
+
| RequestAbortedError
|
|
46
|
+
| RequestTimeoutError
|
|
47
|
+
| ConnectionError
|
|
48
|
+
>
|
|
49
|
+
> {
|
|
50
|
+
const parsed = safeParse(
|
|
51
|
+
request,
|
|
52
|
+
(value) => operations.DataSourcesGetByIdRequest$outboundSchema.parse(value),
|
|
53
|
+
"Input validation failed",
|
|
54
|
+
);
|
|
55
|
+
if (!parsed.ok) {
|
|
56
|
+
return parsed;
|
|
57
|
+
}
|
|
58
|
+
const payload = parsed.value;
|
|
59
|
+
const body = null;
|
|
60
|
+
|
|
61
|
+
const pathParams = {
|
|
62
|
+
data_source_id: encodeSimple("data_source_id", payload.data_source_id, {
|
|
63
|
+
explode: false,
|
|
64
|
+
charEncoding: "percent",
|
|
65
|
+
}),
|
|
66
|
+
};
|
|
67
|
+
|
|
68
|
+
const path = pathToFunc("/api/v1/data_sources/{data_source_id}")(pathParams);
|
|
69
|
+
|
|
70
|
+
const headers = new Headers(compactMap({
|
|
71
|
+
Accept: "application/json",
|
|
72
|
+
}));
|
|
73
|
+
|
|
74
|
+
const secConfig = await extractSecurity(client._options.apiKeyHeader);
|
|
75
|
+
const securityInput = secConfig == null ? {} : { apiKeyHeader: secConfig };
|
|
76
|
+
const requestSecurity = resolveGlobalSecurity(securityInput);
|
|
77
|
+
|
|
78
|
+
const context = {
|
|
79
|
+
baseURL: options?.serverURL ?? "",
|
|
80
|
+
operationID: "data_sources_get_by_id",
|
|
81
|
+
oAuth2Scopes: [],
|
|
82
|
+
|
|
83
|
+
resolvedSecurity: requestSecurity,
|
|
84
|
+
|
|
85
|
+
securitySource: client._options.apiKeyHeader,
|
|
86
|
+
retryConfig: options?.retries
|
|
87
|
+
|| client._options.retryConfig
|
|
88
|
+
|| { strategy: "none" },
|
|
89
|
+
retryCodes: options?.retryCodes || ["429", "500", "502", "503", "504"],
|
|
90
|
+
};
|
|
91
|
+
|
|
92
|
+
const requestRes = client._createRequest(context, {
|
|
93
|
+
security: requestSecurity,
|
|
94
|
+
method: "GET",
|
|
95
|
+
baseURL: options?.serverURL,
|
|
96
|
+
path: path,
|
|
97
|
+
headers: headers,
|
|
98
|
+
body: body,
|
|
99
|
+
timeoutMs: options?.timeoutMs || client._options.timeoutMs || -1,
|
|
100
|
+
}, options);
|
|
101
|
+
if (!requestRes.ok) {
|
|
102
|
+
return requestRes;
|
|
103
|
+
}
|
|
104
|
+
const req = requestRes.value;
|
|
105
|
+
|
|
106
|
+
const doResult = await client._do(req, {
|
|
107
|
+
context,
|
|
108
|
+
errorCodes: ["422", "4XX", "5XX"],
|
|
109
|
+
retryConfig: context.retryConfig,
|
|
110
|
+
retryCodes: context.retryCodes,
|
|
111
|
+
});
|
|
112
|
+
if (!doResult.ok) {
|
|
113
|
+
return doResult;
|
|
114
|
+
}
|
|
115
|
+
const response = doResult.value;
|
|
116
|
+
|
|
117
|
+
const responseFields = {
|
|
118
|
+
HttpMeta: { Response: response, Request: req },
|
|
119
|
+
};
|
|
120
|
+
|
|
121
|
+
const [result] = await M.match<
|
|
122
|
+
components.DataSourceDetailResponse,
|
|
123
|
+
| errors.HTTPValidationError
|
|
124
|
+
| SDKError
|
|
125
|
+
| SDKValidationError
|
|
126
|
+
| UnexpectedClientError
|
|
127
|
+
| InvalidRequestError
|
|
128
|
+
| RequestAbortedError
|
|
129
|
+
| RequestTimeoutError
|
|
130
|
+
| ConnectionError
|
|
131
|
+
>(
|
|
132
|
+
M.json(200, components.DataSourceDetailResponse$inboundSchema),
|
|
133
|
+
M.jsonErr(422, errors.HTTPValidationError$inboundSchema),
|
|
134
|
+
M.fail("4XX"),
|
|
135
|
+
M.fail("5XX"),
|
|
136
|
+
)(response, { extraFields: responseFields });
|
|
137
|
+
if (!result.ok) {
|
|
138
|
+
return result;
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
return result;
|
|
142
|
+
}
|
package/src/lib/config.ts
CHANGED
|
@@ -57,8 +57,8 @@ export function serverURLFromOptions(options: SDKOptions): URL | null {
|
|
|
57
57
|
export const SDK_METADATA = {
|
|
58
58
|
language: "typescript",
|
|
59
59
|
openapiDocVersion: "0.0.2",
|
|
60
|
-
sdkVersion: "0.1.0-alpha.
|
|
60
|
+
sdkVersion: "0.1.0-alpha.45",
|
|
61
61
|
genVersion: "2.512.4",
|
|
62
62
|
userAgent:
|
|
63
|
-
"speakeasy-sdk/typescript 0.1.0-alpha.
|
|
63
|
+
"speakeasy-sdk/typescript 0.1.0-alpha.45 2.512.4 0.0.2 syllable-sdk",
|
|
64
64
|
} as const;
|
|
@@ -26,9 +26,9 @@ export type DataSourceCreateRequest = {
|
|
|
26
26
|
*/
|
|
27
27
|
chunk: boolean;
|
|
28
28
|
/**
|
|
29
|
-
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks.
|
|
29
|
+
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks. Defaults to a blank line ('\n\n').
|
|
30
30
|
*/
|
|
31
|
-
chunkDelimiter?: string |
|
|
31
|
+
chunkDelimiter?: string | undefined;
|
|
32
32
|
/**
|
|
33
33
|
* Information that the data source will provide to the agent accessing it.
|
|
34
34
|
*/
|
|
@@ -45,7 +45,7 @@ export const DataSourceCreateRequest$inboundSchema: z.ZodType<
|
|
|
45
45
|
description: z.nullable(z.string()).optional(),
|
|
46
46
|
labels: z.array(z.string()).optional(),
|
|
47
47
|
chunk: z.boolean(),
|
|
48
|
-
chunk_delimiter: z.
|
|
48
|
+
chunk_delimiter: z.string().default("\n\n"),
|
|
49
49
|
text: z.string(),
|
|
50
50
|
}).transform((v) => {
|
|
51
51
|
return remap$(v, {
|
|
@@ -59,7 +59,7 @@ export type DataSourceCreateRequest$Outbound = {
|
|
|
59
59
|
description?: string | null | undefined;
|
|
60
60
|
labels?: Array<string> | undefined;
|
|
61
61
|
chunk: boolean;
|
|
62
|
-
chunk_delimiter
|
|
62
|
+
chunk_delimiter: string;
|
|
63
63
|
text: string;
|
|
64
64
|
};
|
|
65
65
|
|
|
@@ -73,7 +73,7 @@ export const DataSourceCreateRequest$outboundSchema: z.ZodType<
|
|
|
73
73
|
description: z.nullable(z.string()).optional(),
|
|
74
74
|
labels: z.array(z.string()).optional(),
|
|
75
75
|
chunk: z.boolean(),
|
|
76
|
-
chunkDelimiter: z.
|
|
76
|
+
chunkDelimiter: z.string().default("\n\n"),
|
|
77
77
|
text: z.string(),
|
|
78
78
|
}).transform((v) => {
|
|
79
79
|
return remap$(v, {
|
|
@@ -29,9 +29,13 @@ export type DataSourceDetailResponse = {
|
|
|
29
29
|
*/
|
|
30
30
|
chunk: boolean;
|
|
31
31
|
/**
|
|
32
|
-
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks.
|
|
32
|
+
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks. Defaults to a blank line ('\n\n').
|
|
33
33
|
*/
|
|
34
|
-
chunkDelimiter?: string |
|
|
34
|
+
chunkDelimiter?: string | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* The data source ID.
|
|
37
|
+
*/
|
|
38
|
+
id: number;
|
|
35
39
|
/**
|
|
36
40
|
* The comments for the most recent edit to the data source
|
|
37
41
|
*/
|
|
@@ -60,7 +64,8 @@ export const DataSourceDetailResponse$inboundSchema: z.ZodType<
|
|
|
60
64
|
description: z.nullable(z.string()).optional(),
|
|
61
65
|
labels: z.array(z.string()).optional(),
|
|
62
66
|
chunk: z.boolean(),
|
|
63
|
-
chunk_delimiter: z.
|
|
67
|
+
chunk_delimiter: z.string().default("\n\n"),
|
|
68
|
+
id: z.number().int(),
|
|
64
69
|
edit_comments: z.nullable(z.string()).optional(),
|
|
65
70
|
updated_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
66
71
|
last_updated_by: z.nullable(z.string()),
|
|
@@ -80,7 +85,8 @@ export type DataSourceDetailResponse$Outbound = {
|
|
|
80
85
|
description?: string | null | undefined;
|
|
81
86
|
labels?: Array<string> | undefined;
|
|
82
87
|
chunk: boolean;
|
|
83
|
-
chunk_delimiter
|
|
88
|
+
chunk_delimiter: string;
|
|
89
|
+
id: number;
|
|
84
90
|
edit_comments?: string | null | undefined;
|
|
85
91
|
updated_at: string;
|
|
86
92
|
last_updated_by: string | null;
|
|
@@ -97,7 +103,8 @@ export const DataSourceDetailResponse$outboundSchema: z.ZodType<
|
|
|
97
103
|
description: z.nullable(z.string()).optional(),
|
|
98
104
|
labels: z.array(z.string()).optional(),
|
|
99
105
|
chunk: z.boolean(),
|
|
100
|
-
chunkDelimiter: z.
|
|
106
|
+
chunkDelimiter: z.string().default("\n\n"),
|
|
107
|
+
id: z.number().int(),
|
|
101
108
|
editComments: z.nullable(z.string()).optional(),
|
|
102
109
|
updatedAt: z.date().transform(v => v.toISOString()),
|
|
103
110
|
lastUpdatedBy: z.nullable(z.string()),
|
|
@@ -29,9 +29,13 @@ export type DataSourceMetadataResponse = {
|
|
|
29
29
|
*/
|
|
30
30
|
chunk: boolean;
|
|
31
31
|
/**
|
|
32
|
-
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks.
|
|
32
|
+
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks. Defaults to a blank line ('\n\n').
|
|
33
33
|
*/
|
|
34
|
-
chunkDelimiter?: string |
|
|
34
|
+
chunkDelimiter?: string | undefined;
|
|
35
|
+
/**
|
|
36
|
+
* The data source ID.
|
|
37
|
+
*/
|
|
38
|
+
id: number;
|
|
35
39
|
/**
|
|
36
40
|
* The comments for the most recent edit to the data source
|
|
37
41
|
*/
|
|
@@ -56,7 +60,8 @@ export const DataSourceMetadataResponse$inboundSchema: z.ZodType<
|
|
|
56
60
|
description: z.nullable(z.string()).optional(),
|
|
57
61
|
labels: z.array(z.string()).optional(),
|
|
58
62
|
chunk: z.boolean(),
|
|
59
|
-
chunk_delimiter: z.
|
|
63
|
+
chunk_delimiter: z.string().default("\n\n"),
|
|
64
|
+
id: z.number().int(),
|
|
60
65
|
edit_comments: z.nullable(z.string()).optional(),
|
|
61
66
|
updated_at: z.string().datetime({ offset: true }).transform(v => new Date(v)),
|
|
62
67
|
last_updated_by: z.nullable(z.string()),
|
|
@@ -75,7 +80,8 @@ export type DataSourceMetadataResponse$Outbound = {
|
|
|
75
80
|
description?: string | null | undefined;
|
|
76
81
|
labels?: Array<string> | undefined;
|
|
77
82
|
chunk: boolean;
|
|
78
|
-
chunk_delimiter
|
|
83
|
+
chunk_delimiter: string;
|
|
84
|
+
id: number;
|
|
79
85
|
edit_comments?: string | null | undefined;
|
|
80
86
|
updated_at: string;
|
|
81
87
|
last_updated_by: string | null;
|
|
@@ -91,7 +97,8 @@ export const DataSourceMetadataResponse$outboundSchema: z.ZodType<
|
|
|
91
97
|
description: z.nullable(z.string()).optional(),
|
|
92
98
|
labels: z.array(z.string()).optional(),
|
|
93
99
|
chunk: z.boolean(),
|
|
94
|
-
chunkDelimiter: z.
|
|
100
|
+
chunkDelimiter: z.string().default("\n\n"),
|
|
101
|
+
id: z.number().int(),
|
|
95
102
|
editComments: z.nullable(z.string()).optional(),
|
|
96
103
|
updatedAt: z.date().transform(v => v.toISOString()),
|
|
97
104
|
lastUpdatedBy: z.nullable(z.string()),
|
|
@@ -26,9 +26,13 @@ export type DataSourceUpdateRequest = {
|
|
|
26
26
|
*/
|
|
27
27
|
chunk: boolean;
|
|
28
28
|
/**
|
|
29
|
-
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks.
|
|
29
|
+
* String that should be treated as delimiter between intended chunks if chunk == True. This string will not be included in any chunks. Defaults to a blank line ('\n\n').
|
|
30
30
|
*/
|
|
31
|
-
chunkDelimiter?: string |
|
|
31
|
+
chunkDelimiter?: string | undefined;
|
|
32
|
+
/**
|
|
33
|
+
* The data source ID.
|
|
34
|
+
*/
|
|
35
|
+
id: number;
|
|
32
36
|
/**
|
|
33
37
|
* The comments for the most recent edit to the data source
|
|
34
38
|
*/
|
|
@@ -49,7 +53,8 @@ export const DataSourceUpdateRequest$inboundSchema: z.ZodType<
|
|
|
49
53
|
description: z.nullable(z.string()).optional(),
|
|
50
54
|
labels: z.array(z.string()).optional(),
|
|
51
55
|
chunk: z.boolean(),
|
|
52
|
-
chunk_delimiter: z.
|
|
56
|
+
chunk_delimiter: z.string().default("\n\n"),
|
|
57
|
+
id: z.number().int(),
|
|
53
58
|
edit_comments: z.nullable(z.string()).optional(),
|
|
54
59
|
text: z.string(),
|
|
55
60
|
}).transform((v) => {
|
|
@@ -65,7 +70,8 @@ export type DataSourceUpdateRequest$Outbound = {
|
|
|
65
70
|
description?: string | null | undefined;
|
|
66
71
|
labels?: Array<string> | undefined;
|
|
67
72
|
chunk: boolean;
|
|
68
|
-
chunk_delimiter
|
|
73
|
+
chunk_delimiter: string;
|
|
74
|
+
id: number;
|
|
69
75
|
edit_comments?: string | null | undefined;
|
|
70
76
|
text: string;
|
|
71
77
|
};
|
|
@@ -80,7 +86,8 @@ export const DataSourceUpdateRequest$outboundSchema: z.ZodType<
|
|
|
80
86
|
description: z.nullable(z.string()).optional(),
|
|
81
87
|
labels: z.array(z.string()).optional(),
|
|
82
88
|
chunk: z.boolean(),
|
|
83
|
-
chunkDelimiter: z.
|
|
89
|
+
chunkDelimiter: z.string().default("\n\n"),
|
|
90
|
+
id: z.number().int(),
|
|
84
91
|
editComments: z.nullable(z.string()).optional(),
|
|
85
92
|
text: z.string(),
|
|
86
93
|
}).transform((v) => {
|
|
@@ -91,6 +91,7 @@ export * from "./toolhttpmethod.js";
|
|
|
91
91
|
export * from "./toolparameterdefault.js";
|
|
92
92
|
export * from "./toolparametertransform.js";
|
|
93
93
|
export * from "./toolparametertransformcondition.js";
|
|
94
|
+
export * from "./toolpromptinfo.js";
|
|
94
95
|
export * from "./toolproperties.js";
|
|
95
96
|
export * from "./toolresponse.js";
|
|
96
97
|
export * from "./toolupdaterequest.js";
|
|
@@ -13,6 +13,12 @@ import {
|
|
|
13
13
|
ToolDefinition$Outbound,
|
|
14
14
|
ToolDefinition$outboundSchema,
|
|
15
15
|
} from "./tooldefinition.js";
|
|
16
|
+
import {
|
|
17
|
+
ToolPromptInfo,
|
|
18
|
+
ToolPromptInfo$inboundSchema,
|
|
19
|
+
ToolPromptInfo$Outbound,
|
|
20
|
+
ToolPromptInfo$outboundSchema,
|
|
21
|
+
} from "./toolpromptinfo.js";
|
|
16
22
|
|
|
17
23
|
/**
|
|
18
24
|
* A tool is a function that an agent can call to perform actions like accessing databases,
|
|
@@ -46,6 +52,10 @@ export type ToolDetailResponse = {
|
|
|
46
52
|
* The name of the service to which the tool belongs
|
|
47
53
|
*/
|
|
48
54
|
serviceName?: string | null | undefined;
|
|
55
|
+
/**
|
|
56
|
+
* IDs and names of the prompts linked to the tool
|
|
57
|
+
*/
|
|
58
|
+
promptsInfo?: Array<ToolPromptInfo> | null | undefined;
|
|
49
59
|
/**
|
|
50
60
|
* The timestamp of the most recent update to the service
|
|
51
61
|
*/
|
|
@@ -72,6 +82,7 @@ export const ToolDetailResponse$inboundSchema: z.ZodType<
|
|
|
72
82
|
id: z.number().int(),
|
|
73
83
|
last_updated_comments: z.nullable(z.string()).optional(),
|
|
74
84
|
service_name: z.nullable(z.string()).optional(),
|
|
85
|
+
prompts_info: z.nullable(z.array(ToolPromptInfo$inboundSchema)).optional(),
|
|
75
86
|
last_updated: z.string().datetime({ offset: true }).transform(v =>
|
|
76
87
|
new Date(v)
|
|
77
88
|
),
|
|
@@ -82,6 +93,7 @@ export const ToolDetailResponse$inboundSchema: z.ZodType<
|
|
|
82
93
|
"service_id": "serviceId",
|
|
83
94
|
"last_updated_comments": "lastUpdatedComments",
|
|
84
95
|
"service_name": "serviceName",
|
|
96
|
+
"prompts_info": "promptsInfo",
|
|
85
97
|
"last_updated": "lastUpdated",
|
|
86
98
|
"last_updated_by": "lastUpdatedBy",
|
|
87
99
|
});
|
|
@@ -95,6 +107,7 @@ export type ToolDetailResponse$Outbound = {
|
|
|
95
107
|
id: number;
|
|
96
108
|
last_updated_comments?: string | null | undefined;
|
|
97
109
|
service_name?: string | null | undefined;
|
|
110
|
+
prompts_info?: Array<ToolPromptInfo$Outbound> | null | undefined;
|
|
98
111
|
last_updated: string;
|
|
99
112
|
last_updated_by: string;
|
|
100
113
|
fields: Array<string>;
|
|
@@ -112,6 +125,7 @@ export const ToolDetailResponse$outboundSchema: z.ZodType<
|
|
|
112
125
|
id: z.number().int(),
|
|
113
126
|
lastUpdatedComments: z.nullable(z.string()).optional(),
|
|
114
127
|
serviceName: z.nullable(z.string()).optional(),
|
|
128
|
+
promptsInfo: z.nullable(z.array(ToolPromptInfo$outboundSchema)).optional(),
|
|
115
129
|
lastUpdated: z.date().transform(v => v.toISOString()),
|
|
116
130
|
lastUpdatedBy: z.string(),
|
|
117
131
|
fields: z.array(z.string()),
|
|
@@ -120,6 +134,7 @@ export const ToolDetailResponse$outboundSchema: z.ZodType<
|
|
|
120
134
|
serviceId: "service_id",
|
|
121
135
|
lastUpdatedComments: "last_updated_comments",
|
|
122
136
|
serviceName: "service_name",
|
|
137
|
+
promptsInfo: "prompts_info",
|
|
123
138
|
lastUpdated: "last_updated",
|
|
124
139
|
lastUpdatedBy: "last_updated_by",
|
|
125
140
|
});
|