@opencode/schema 0.0.0-dev-20303 → 0.0.0-dev-20307
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/credential.d.ts +48 -0
- package/dist/credential.js +14 -0
- package/package.json +1 -1
package/dist/credential.d.ts
CHANGED
|
@@ -189,3 +189,51 @@ export declare const Value: Schema.Union<readonly [Schema.Struct<{
|
|
|
189
189
|
readonly configuration: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>>, never, never>;
|
|
190
190
|
}>]>;
|
|
191
191
|
export type Value = Schema.Schema.Type<typeof Value>;
|
|
192
|
+
export interface Entry extends Schema.Schema.Type<typeof Entry> {
|
|
193
|
+
}
|
|
194
|
+
export declare const Entry: Schema.Struct<{
|
|
195
|
+
readonly id: Schema.brand<Schema.String, "Credential.ID"> & {
|
|
196
|
+
create: () => string & import("effect/Brand").Brand<"Credential.ID">;
|
|
197
|
+
};
|
|
198
|
+
readonly integrationID: Schema.brand<Schema.String, "Integration.ID">;
|
|
199
|
+
readonly label: Schema.String;
|
|
200
|
+
readonly active: Schema.Boolean;
|
|
201
|
+
readonly value: Schema.Union<readonly [Schema.Struct<{
|
|
202
|
+
readonly type: Schema.Literal<"oauth">;
|
|
203
|
+
readonly methodID: Schema.brand<Schema.String, "Integration.MethodID">;
|
|
204
|
+
readonly refresh: Schema.String;
|
|
205
|
+
readonly access: Schema.String;
|
|
206
|
+
readonly expires: Schema.Int;
|
|
207
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
208
|
+
}>, Schema.Struct<{
|
|
209
|
+
readonly type: Schema.Literal<"key">;
|
|
210
|
+
readonly key: Schema.String;
|
|
211
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
212
|
+
readonly configuration: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>>, never, never>;
|
|
213
|
+
}>]>;
|
|
214
|
+
}>;
|
|
215
|
+
export interface CreateInput extends Schema.Schema.Type<typeof CreateInput> {
|
|
216
|
+
}
|
|
217
|
+
export declare const CreateInput: Schema.Struct<{
|
|
218
|
+
readonly id: Schema.decodeTo<Schema.optional<Schema.toType<Schema.brand<Schema.String, "Credential.ID"> & {
|
|
219
|
+
create: () => string & import("effect/Brand").Brand<"Credential.ID">;
|
|
220
|
+
}>>, Schema.optionalKey<Schema.brand<Schema.String, "Credential.ID"> & {
|
|
221
|
+
create: () => string & import("effect/Brand").Brand<"Credential.ID">;
|
|
222
|
+
}>, never, never>;
|
|
223
|
+
readonly integrationID: Schema.brand<Schema.String, "Integration.ID">;
|
|
224
|
+
readonly label: Schema.decodeTo<Schema.optional<Schema.toType<Schema.String>>, Schema.optionalKey<Schema.String>, never, never>;
|
|
225
|
+
readonly value: Schema.Union<readonly [Schema.Struct<{
|
|
226
|
+
readonly type: Schema.Literal<"oauth">;
|
|
227
|
+
readonly methodID: Schema.brand<Schema.String, "Integration.MethodID">;
|
|
228
|
+
readonly refresh: Schema.String;
|
|
229
|
+
readonly access: Schema.String;
|
|
230
|
+
readonly expires: Schema.Int;
|
|
231
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
232
|
+
}>, Schema.Struct<{
|
|
233
|
+
readonly type: Schema.Literal<"key">;
|
|
234
|
+
readonly key: Schema.String;
|
|
235
|
+
readonly metadata: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Unknown>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Unknown>>, never, never>;
|
|
236
|
+
readonly configuration: Schema.decodeTo<Schema.optional<Schema.toType<Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>>>, Schema.optionalKey<Schema.$Record<Schema.String, Schema.Union<readonly [Schema.String, Schema.Number, Schema.Boolean, Schema.$Array<Schema.String>]>>>, never, never>;
|
|
237
|
+
}>]>;
|
|
238
|
+
readonly activate: Schema.decodeTo<Schema.optional<Schema.toType<Schema.Boolean>>, Schema.optionalKey<Schema.Boolean>, never, never>;
|
|
239
|
+
}>;
|
package/dist/credential.js
CHANGED
|
@@ -37,3 +37,17 @@ export const Key = Schema.Struct({
|
|
|
37
37
|
export const Value = Schema.Union([OAuth, Key])
|
|
38
38
|
.pipe(Schema.toTaggedUnion("type"))
|
|
39
39
|
.annotate({ identifier: "Credential.Value" });
|
|
40
|
+
export const Entry = Schema.Struct({
|
|
41
|
+
id: ID,
|
|
42
|
+
integrationID: IntegrationID,
|
|
43
|
+
label: Schema.String,
|
|
44
|
+
active: Schema.Boolean,
|
|
45
|
+
value: Value,
|
|
46
|
+
}).annotate({ identifier: "Credential.Entry" });
|
|
47
|
+
export const CreateInput = Schema.Struct({
|
|
48
|
+
id: optional(ID),
|
|
49
|
+
integrationID: IntegrationID,
|
|
50
|
+
label: optional(Schema.String),
|
|
51
|
+
value: Value,
|
|
52
|
+
activate: optional(Schema.Boolean),
|
|
53
|
+
}).annotate({ identifier: "Credential.CreateInput" });
|