weave-typescript 0.19.0 → 0.21.0
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/dist/weaveapi/inference/v1/inference.pb.d.ts +588 -0
- package/dist/weaveapi/inference/v1/inference.pb.js +7170 -0
- package/dist/weaveapi/inference/v1/service.pb.d.ts +235 -0
- package/dist/weaveapi/inference/v1/service.pb.js +651 -0
- package/dist/weaveapi/model/v1/model.pb.d.ts +105 -0
- package/dist/weaveapi/model/v1/model.pb.js +1001 -0
- package/dist/weaveapi/model/v1/service.pb.d.ts +116 -0
- package/dist/weaveapi/model/v1/service.pb.js +579 -0
- package/dist/weaveapi/provider/v1/provider.pb.d.ts +14 -0
- package/dist/weaveapi/provider/v1/provider.pb.js +88 -2
- package/dist/weaveapi/provider/v1/service.pb.d.ts +26 -1
- package/dist/weaveapi/provider/v1/service.pb.js +325 -6
- package/dist/weavesql/weavedb/model_catalog_sql.d.ts +91 -0
- package/dist/weavesql/weavedb/model_catalog_sql.js +213 -0
- package/dist/weavesql/weavedb/provider_sql.d.ts +25 -9
- package/dist/weavesql/weavedb/provider_sql.js +83 -54
- package/package.json +2 -2
|
@@ -49,6 +49,16 @@ export declare enum ProviderCredentialStatus {
|
|
|
49
49
|
}
|
|
50
50
|
export declare function providerCredentialStatusFromJSON(object: any): ProviderCredentialStatus;
|
|
51
51
|
export declare function providerCredentialStatusToJSON(object: ProviderCredentialStatus): string;
|
|
52
|
+
/** ProviderAuthenticationType identifies the credential mode Weave uses at runtime. */
|
|
53
|
+
export declare enum ProviderAuthenticationType {
|
|
54
|
+
PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED = 0,
|
|
55
|
+
PROVIDER_AUTHENTICATION_TYPE_API_KEY = 1,
|
|
56
|
+
PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN = 2,
|
|
57
|
+
PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4 = 3,
|
|
58
|
+
UNRECOGNIZED = -1
|
|
59
|
+
}
|
|
60
|
+
export declare function providerAuthenticationTypeFromJSON(object: any): ProviderAuthenticationType;
|
|
61
|
+
export declare function providerAuthenticationTypeToJSON(object: ProviderAuthenticationType): string;
|
|
52
62
|
/** ProviderPropagationScope describes the targeting mode for one propagation. */
|
|
53
63
|
export declare enum ProviderPropagationScope {
|
|
54
64
|
PROVIDER_PROPAGATION_SCOPE_UNSPECIFIED = 0,
|
|
@@ -83,6 +93,10 @@ export interface ProviderConfiguration {
|
|
|
83
93
|
createdAt: Date | undefined;
|
|
84
94
|
updatedAt: Date | undefined;
|
|
85
95
|
credentialLastRotatedAt: Date | undefined;
|
|
96
|
+
authenticationType: ProviderAuthenticationType;
|
|
97
|
+
settings: {
|
|
98
|
+
[key: string]: any;
|
|
99
|
+
} | undefined;
|
|
86
100
|
}
|
|
87
101
|
/** ProviderPropagationTargetStatus reports propagation results for one organization. */
|
|
88
102
|
export interface ProviderPropagationTargetStatus {
|
|
@@ -5,19 +5,22 @@
|
|
|
5
5
|
// protoc unknown
|
|
6
6
|
// source: weaveapi/provider/v1/provider.proto
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
|
-
exports.AccessibleOrganization = exports.ProviderPropagationTargetStatus = exports.ProviderConfiguration = exports.ProviderPropagationTargetState = exports.ProviderPropagationScope = exports.ProviderCredentialStatus = exports.ProviderConfigurationStatus = exports.ProviderKind = exports.protobufPackage = void 0;
|
|
8
|
+
exports.AccessibleOrganization = exports.ProviderPropagationTargetStatus = exports.ProviderConfiguration = exports.ProviderPropagationTargetState = exports.ProviderPropagationScope = exports.ProviderAuthenticationType = exports.ProviderCredentialStatus = exports.ProviderConfigurationStatus = exports.ProviderKind = exports.protobufPackage = void 0;
|
|
9
9
|
exports.providerKindFromJSON = providerKindFromJSON;
|
|
10
10
|
exports.providerKindToJSON = providerKindToJSON;
|
|
11
11
|
exports.providerConfigurationStatusFromJSON = providerConfigurationStatusFromJSON;
|
|
12
12
|
exports.providerConfigurationStatusToJSON = providerConfigurationStatusToJSON;
|
|
13
13
|
exports.providerCredentialStatusFromJSON = providerCredentialStatusFromJSON;
|
|
14
14
|
exports.providerCredentialStatusToJSON = providerCredentialStatusToJSON;
|
|
15
|
+
exports.providerAuthenticationTypeFromJSON = providerAuthenticationTypeFromJSON;
|
|
16
|
+
exports.providerAuthenticationTypeToJSON = providerAuthenticationTypeToJSON;
|
|
15
17
|
exports.providerPropagationScopeFromJSON = providerPropagationScopeFromJSON;
|
|
16
18
|
exports.providerPropagationScopeToJSON = providerPropagationScopeToJSON;
|
|
17
19
|
exports.providerPropagationTargetStateFromJSON = providerPropagationTargetStateFromJSON;
|
|
18
20
|
exports.providerPropagationTargetStateToJSON = providerPropagationTargetStateToJSON;
|
|
19
21
|
/* eslint-disable */
|
|
20
22
|
const wire_1 = require("@bufbuild/protobuf/wire");
|
|
23
|
+
const struct_pb_1 = require("../../../google/protobuf/struct.pb");
|
|
21
24
|
const timestamp_pb_1 = require("../../../google/protobuf/timestamp.pb");
|
|
22
25
|
exports.protobufPackage = "weaveapi.provider.v1";
|
|
23
26
|
/** ProviderKind identifies one supported LLM provider runtime. */
|
|
@@ -266,6 +269,50 @@ function providerCredentialStatusToJSON(object) {
|
|
|
266
269
|
return "UNRECOGNIZED";
|
|
267
270
|
}
|
|
268
271
|
}
|
|
272
|
+
/** ProviderAuthenticationType identifies the credential mode Weave uses at runtime. */
|
|
273
|
+
var ProviderAuthenticationType;
|
|
274
|
+
(function (ProviderAuthenticationType) {
|
|
275
|
+
ProviderAuthenticationType[ProviderAuthenticationType["PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED"] = 0] = "PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED";
|
|
276
|
+
ProviderAuthenticationType[ProviderAuthenticationType["PROVIDER_AUTHENTICATION_TYPE_API_KEY"] = 1] = "PROVIDER_AUTHENTICATION_TYPE_API_KEY";
|
|
277
|
+
ProviderAuthenticationType[ProviderAuthenticationType["PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN"] = 2] = "PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN";
|
|
278
|
+
ProviderAuthenticationType[ProviderAuthenticationType["PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4"] = 3] = "PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4";
|
|
279
|
+
ProviderAuthenticationType[ProviderAuthenticationType["UNRECOGNIZED"] = -1] = "UNRECOGNIZED";
|
|
280
|
+
})(ProviderAuthenticationType || (exports.ProviderAuthenticationType = ProviderAuthenticationType = {}));
|
|
281
|
+
function providerAuthenticationTypeFromJSON(object) {
|
|
282
|
+
switch (object) {
|
|
283
|
+
case 0:
|
|
284
|
+
case "PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED":
|
|
285
|
+
return ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED;
|
|
286
|
+
case 1:
|
|
287
|
+
case "PROVIDER_AUTHENTICATION_TYPE_API_KEY":
|
|
288
|
+
return ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_API_KEY;
|
|
289
|
+
case 2:
|
|
290
|
+
case "PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN":
|
|
291
|
+
return ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN;
|
|
292
|
+
case 3:
|
|
293
|
+
case "PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4":
|
|
294
|
+
return ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4;
|
|
295
|
+
case -1:
|
|
296
|
+
case "UNRECOGNIZED":
|
|
297
|
+
default:
|
|
298
|
+
return ProviderAuthenticationType.UNRECOGNIZED;
|
|
299
|
+
}
|
|
300
|
+
}
|
|
301
|
+
function providerAuthenticationTypeToJSON(object) {
|
|
302
|
+
switch (object) {
|
|
303
|
+
case ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED:
|
|
304
|
+
return "PROVIDER_AUTHENTICATION_TYPE_UNSPECIFIED";
|
|
305
|
+
case ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_API_KEY:
|
|
306
|
+
return "PROVIDER_AUTHENTICATION_TYPE_API_KEY";
|
|
307
|
+
case ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN:
|
|
308
|
+
return "PROVIDER_AUTHENTICATION_TYPE_BEARER_TOKEN";
|
|
309
|
+
case ProviderAuthenticationType.PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4:
|
|
310
|
+
return "PROVIDER_AUTHENTICATION_TYPE_AWS_SIGV4";
|
|
311
|
+
case ProviderAuthenticationType.UNRECOGNIZED:
|
|
312
|
+
default:
|
|
313
|
+
return "UNRECOGNIZED";
|
|
314
|
+
}
|
|
315
|
+
}
|
|
269
316
|
/** ProviderPropagationScope describes the targeting mode for one propagation. */
|
|
270
317
|
var ProviderPropagationScope;
|
|
271
318
|
(function (ProviderPropagationScope) {
|
|
@@ -363,6 +410,8 @@ function createBaseProviderConfiguration() {
|
|
|
363
410
|
createdAt: undefined,
|
|
364
411
|
updatedAt: undefined,
|
|
365
412
|
credentialLastRotatedAt: undefined,
|
|
413
|
+
authenticationType: 0,
|
|
414
|
+
settings: undefined,
|
|
366
415
|
};
|
|
367
416
|
}
|
|
368
417
|
exports.ProviderConfiguration = {
|
|
@@ -406,6 +455,12 @@ exports.ProviderConfiguration = {
|
|
|
406
455
|
if (message.credentialLastRotatedAt !== undefined) {
|
|
407
456
|
timestamp_pb_1.Timestamp.encode(toTimestamp(message.credentialLastRotatedAt), writer.uint32(106).fork()).join();
|
|
408
457
|
}
|
|
458
|
+
if (message.authenticationType !== 0) {
|
|
459
|
+
writer.uint32(112).int32(message.authenticationType);
|
|
460
|
+
}
|
|
461
|
+
if (message.settings !== undefined) {
|
|
462
|
+
struct_pb_1.Struct.encode(struct_pb_1.Struct.wrap(message.settings), writer.uint32(122).fork()).join();
|
|
463
|
+
}
|
|
409
464
|
return writer;
|
|
410
465
|
},
|
|
411
466
|
decode(input, length) {
|
|
@@ -506,6 +561,20 @@ exports.ProviderConfiguration = {
|
|
|
506
561
|
message.credentialLastRotatedAt = fromTimestamp(timestamp_pb_1.Timestamp.decode(reader, reader.uint32()));
|
|
507
562
|
continue;
|
|
508
563
|
}
|
|
564
|
+
case 14: {
|
|
565
|
+
if (tag !== 112) {
|
|
566
|
+
break;
|
|
567
|
+
}
|
|
568
|
+
message.authenticationType = reader.int32();
|
|
569
|
+
continue;
|
|
570
|
+
}
|
|
571
|
+
case 15: {
|
|
572
|
+
if (tag !== 122) {
|
|
573
|
+
break;
|
|
574
|
+
}
|
|
575
|
+
message.settings = struct_pb_1.Struct.unwrap(struct_pb_1.Struct.decode(reader, reader.uint32()));
|
|
576
|
+
continue;
|
|
577
|
+
}
|
|
509
578
|
}
|
|
510
579
|
if ((tag & 7) === 4 || tag === 0) {
|
|
511
580
|
break;
|
|
@@ -573,6 +642,12 @@ exports.ProviderConfiguration = {
|
|
|
573
642
|
: isSet(object.credential_last_rotated_at)
|
|
574
643
|
? fromJsonTimestamp(object.credential_last_rotated_at)
|
|
575
644
|
: undefined,
|
|
645
|
+
authenticationType: isSet(object.authenticationType)
|
|
646
|
+
? providerAuthenticationTypeFromJSON(object.authenticationType)
|
|
647
|
+
: isSet(object.authentication_type)
|
|
648
|
+
? providerAuthenticationTypeFromJSON(object.authentication_type)
|
|
649
|
+
: 0,
|
|
650
|
+
settings: isObject(object.settings) ? object.settings : undefined,
|
|
576
651
|
};
|
|
577
652
|
},
|
|
578
653
|
toJSON(message) {
|
|
@@ -616,13 +691,19 @@ exports.ProviderConfiguration = {
|
|
|
616
691
|
if (message.credentialLastRotatedAt !== undefined) {
|
|
617
692
|
obj.credentialLastRotatedAt = message.credentialLastRotatedAt.toISOString();
|
|
618
693
|
}
|
|
694
|
+
if (message.authenticationType !== 0) {
|
|
695
|
+
obj.authenticationType = providerAuthenticationTypeToJSON(message.authenticationType);
|
|
696
|
+
}
|
|
697
|
+
if (message.settings !== undefined) {
|
|
698
|
+
obj.settings = message.settings;
|
|
699
|
+
}
|
|
619
700
|
return obj;
|
|
620
701
|
},
|
|
621
702
|
create(base) {
|
|
622
703
|
return exports.ProviderConfiguration.fromPartial(base !== null && base !== void 0 ? base : {});
|
|
623
704
|
},
|
|
624
705
|
fromPartial(object) {
|
|
625
|
-
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o;
|
|
706
|
+
var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, _q;
|
|
626
707
|
const message = createBaseProviderConfiguration();
|
|
627
708
|
message.id = (_a = object.id) !== null && _a !== void 0 ? _a : "";
|
|
628
709
|
message.organizationId = (_b = object.organizationId) !== null && _b !== void 0 ? _b : "";
|
|
@@ -637,6 +718,8 @@ exports.ProviderConfiguration = {
|
|
|
637
718
|
message.createdAt = (_l = object.createdAt) !== null && _l !== void 0 ? _l : undefined;
|
|
638
719
|
message.updatedAt = (_m = object.updatedAt) !== null && _m !== void 0 ? _m : undefined;
|
|
639
720
|
message.credentialLastRotatedAt = (_o = object.credentialLastRotatedAt) !== null && _o !== void 0 ? _o : undefined;
|
|
721
|
+
message.authenticationType = (_p = object.authenticationType) !== null && _p !== void 0 ? _p : 0;
|
|
722
|
+
message.settings = (_q = object.settings) !== null && _q !== void 0 ? _q : undefined;
|
|
640
723
|
return message;
|
|
641
724
|
},
|
|
642
725
|
};
|
|
@@ -909,6 +992,9 @@ function fromJsonTimestamp(o) {
|
|
|
909
992
|
return fromTimestamp(timestamp_pb_1.Timestamp.fromJSON(o));
|
|
910
993
|
}
|
|
911
994
|
}
|
|
995
|
+
function isObject(value) {
|
|
996
|
+
return typeof value === "object" && value !== null;
|
|
997
|
+
}
|
|
912
998
|
function isSet(value) {
|
|
913
999
|
return value !== null && value !== undefined;
|
|
914
1000
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BinaryReader, BinaryWriter } from "@bufbuild/protobuf/wire";
|
|
2
|
-
import { AccessibleOrganization, ProviderConfiguration, ProviderConfigurationStatus, ProviderCredentialStatus, ProviderKind, ProviderPropagationScope, ProviderPropagationTargetStatus } from "./provider.pb";
|
|
2
|
+
import { AccessibleOrganization, ProviderAuthenticationType, ProviderConfiguration, ProviderConfigurationStatus, ProviderCredentialStatus, ProviderKind, ProviderPropagationScope, ProviderPropagationTargetStatus } from "./provider.pb";
|
|
3
3
|
export declare const protobufPackage = "weaveapi.provider.v1";
|
|
4
4
|
export interface ListProviderConfigurationsRequest {
|
|
5
5
|
organizationIds: string[];
|
|
@@ -21,6 +21,17 @@ export interface CreateProviderConfigurationRequest {
|
|
|
21
21
|
baseUrl: string;
|
|
22
22
|
apiKey: string;
|
|
23
23
|
enabled: boolean;
|
|
24
|
+
authenticationType: ProviderAuthenticationType;
|
|
25
|
+
credentialFields: {
|
|
26
|
+
[key: string]: string;
|
|
27
|
+
};
|
|
28
|
+
settings: {
|
|
29
|
+
[key: string]: any;
|
|
30
|
+
} | undefined;
|
|
31
|
+
}
|
|
32
|
+
export interface CreateProviderConfigurationRequest_CredentialFieldsEntry {
|
|
33
|
+
key: string;
|
|
34
|
+
value: string;
|
|
24
35
|
}
|
|
25
36
|
export interface CreateProviderConfigurationResponse {
|
|
26
37
|
providerConfigurations: ProviderConfiguration[];
|
|
@@ -33,6 +44,10 @@ export interface UpdateProviderConfigurationRequest {
|
|
|
33
44
|
displayName: string;
|
|
34
45
|
baseUrl: string;
|
|
35
46
|
status: ProviderConfigurationStatus;
|
|
47
|
+
authenticationType: ProviderAuthenticationType;
|
|
48
|
+
settings: {
|
|
49
|
+
[key: string]: any;
|
|
50
|
+
} | undefined;
|
|
36
51
|
}
|
|
37
52
|
export interface UpdateProviderConfigurationResponse {
|
|
38
53
|
providerConfiguration: ProviderConfiguration | undefined;
|
|
@@ -41,6 +56,14 @@ export interface RotateProviderCredentialRequest {
|
|
|
41
56
|
providerConfigurationId: string;
|
|
42
57
|
organizationId: string;
|
|
43
58
|
apiKey: string;
|
|
59
|
+
authenticationType: ProviderAuthenticationType;
|
|
60
|
+
credentialFields: {
|
|
61
|
+
[key: string]: string;
|
|
62
|
+
};
|
|
63
|
+
}
|
|
64
|
+
export interface RotateProviderCredentialRequest_CredentialFieldsEntry {
|
|
65
|
+
key: string;
|
|
66
|
+
value: string;
|
|
44
67
|
}
|
|
45
68
|
export interface RotateProviderCredentialResponse {
|
|
46
69
|
providerConfiguration: ProviderConfiguration | undefined;
|
|
@@ -62,10 +85,12 @@ export interface GetProviderPropagationStatusResponse {
|
|
|
62
85
|
export declare const ListProviderConfigurationsRequest: MessageFns<ListProviderConfigurationsRequest>;
|
|
63
86
|
export declare const ListProviderConfigurationsResponse: MessageFns<ListProviderConfigurationsResponse>;
|
|
64
87
|
export declare const CreateProviderConfigurationRequest: MessageFns<CreateProviderConfigurationRequest>;
|
|
88
|
+
export declare const CreateProviderConfigurationRequest_CredentialFieldsEntry: MessageFns<CreateProviderConfigurationRequest_CredentialFieldsEntry>;
|
|
65
89
|
export declare const CreateProviderConfigurationResponse: MessageFns<CreateProviderConfigurationResponse>;
|
|
66
90
|
export declare const UpdateProviderConfigurationRequest: MessageFns<UpdateProviderConfigurationRequest>;
|
|
67
91
|
export declare const UpdateProviderConfigurationResponse: MessageFns<UpdateProviderConfigurationResponse>;
|
|
68
92
|
export declare const RotateProviderCredentialRequest: MessageFns<RotateProviderCredentialRequest>;
|
|
93
|
+
export declare const RotateProviderCredentialRequest_CredentialFieldsEntry: MessageFns<RotateProviderCredentialRequest_CredentialFieldsEntry>;
|
|
69
94
|
export declare const RotateProviderCredentialResponse: MessageFns<RotateProviderCredentialResponse>;
|
|
70
95
|
export declare const ListAccessibleOrganizationsRequest: MessageFns<ListAccessibleOrganizationsRequest>;
|
|
71
96
|
export declare const ListAccessibleOrganizationsResponse: MessageFns<ListAccessibleOrganizationsResponse>;
|