@effect/ai-openai 0.11.4 → 0.12.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/cjs/Generated.js +284 -334
- package/dist/cjs/Generated.js.map +1 -1
- package/dist/cjs/OpenAiClient.js +4 -1
- package/dist/cjs/OpenAiClient.js.map +1 -1
- package/dist/cjs/OpenAiConfig.js +10 -5
- package/dist/cjs/OpenAiConfig.js.map +1 -1
- package/dist/dts/Generated.d.ts +91 -75
- package/dist/dts/Generated.d.ts.map +1 -1
- package/dist/dts/OpenAiClient.d.ts.map +1 -1
- package/dist/dts/OpenAiConfig.d.ts +22 -58
- package/dist/dts/OpenAiConfig.d.ts.map +1 -1
- package/dist/esm/Generated.js +280 -331
- package/dist/esm/Generated.js.map +1 -1
- package/dist/esm/OpenAiClient.js +4 -1
- package/dist/esm/OpenAiClient.js.map +1 -1
- package/dist/esm/OpenAiConfig.js +9 -3
- package/dist/esm/OpenAiConfig.js.map +1 -1
- package/package.json +5 -5
- package/src/Generated.ts +983 -750
- package/src/OpenAiClient.ts +7 -1
- package/src/OpenAiConfig.ts +53 -8
package/src/Generated.ts
CHANGED
|
@@ -64,6 +64,8 @@ export class AssistantToolsFunction extends S.Struct({
|
|
|
64
64
|
"function": FunctionObject
|
|
65
65
|
}) {}
|
|
66
66
|
|
|
67
|
+
export class Metadata extends S.Record({ key: S.String, value: S.Unknown }) {}
|
|
68
|
+
|
|
67
69
|
export class ResponseFormatTextType extends S.Literal("text") {}
|
|
68
70
|
|
|
69
71
|
export class ResponseFormatText extends S.Struct({
|
|
@@ -124,7 +126,7 @@ export class AssistantObject extends S.Struct({
|
|
|
124
126
|
}),
|
|
125
127
|
{ nullable: true }
|
|
126
128
|
),
|
|
127
|
-
"metadata": S.NullOr(
|
|
129
|
+
"metadata": S.NullOr(Metadata),
|
|
128
130
|
"temperature": S.optionalWith(S.Number.pipe(S.greaterThanOrEqualTo(0), S.lessThanOrEqualTo(2)), {
|
|
129
131
|
nullable: true,
|
|
130
132
|
default: () => 1 as const
|
|
@@ -205,7 +207,7 @@ export class CreateAssistantRequest extends S.Class<CreateAssistantRequest>("Cre
|
|
|
205
207
|
S.Array(S.Struct({
|
|
206
208
|
"file_ids": S.optionalWith(S.Array(S.String).pipe(S.maxItems(10000)), { nullable: true }),
|
|
207
209
|
"chunking_strategy": S.optionalWith(S.Record({ key: S.String, value: S.Unknown }), { nullable: true }),
|
|
208
|
-
"metadata": S.optionalWith(
|
|
210
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
209
211
|
})).pipe(S.maxItems(1)),
|
|
210
212
|
{ nullable: true }
|
|
211
213
|
)
|
|
@@ -215,7 +217,7 @@ export class CreateAssistantRequest extends S.Class<CreateAssistantRequest>("Cre
|
|
|
215
217
|
}),
|
|
216
218
|
{ nullable: true }
|
|
217
219
|
),
|
|
218
|
-
"metadata": S.optionalWith(
|
|
220
|
+
"metadata": S.optionalWith(Metadata, { nullable: true }),
|
|
219
221
|
"temperature": S.optionalWith(S.Number.pipe(S.greaterThanOrEqualTo(0), S.lessThanOrEqualTo(2)), {
|
|
220
222
|
nullable: true,
|
|
221
223
|
default: () => 1 as const
|
|
@@ -259,7 +261,7 @@ export class ModifyAssistantRequest extends S.Class<ModifyAssistantRequest>("Mod
|
|
|
259
261
|
}),
|
|
260
262
|
{ nullable: true }
|
|
261
263
|
),
|
|
262
|
-
"metadata": S.optionalWith(
|
|
264
|
+
"metadata": S.optionalWith(Metadata, { nullable: true }),
|
|
263
265
|
"temperature": S.optionalWith(S.Number.pipe(S.greaterThanOrEqualTo(0), S.lessThanOrEqualTo(2)), {
|
|
264
266
|
nullable: true,
|
|
265
267
|
default: () => 1 as const
|
|
@@ -326,7 +328,7 @@ export class TranscriptionSegment extends S.Struct({
|
|
|
326
328
|
|
|
327
329
|
export class CreateTranscriptionResponseVerboseJson extends S.Struct({
|
|
328
330
|
"language": S.String,
|
|
329
|
-
"duration": S.
|
|
331
|
+
"duration": S.Number,
|
|
330
332
|
"text": S.String,
|
|
331
333
|
"words": S.optionalWith(S.Array(TranscriptionWord), { nullable: true }),
|
|
332
334
|
"segments": S.optionalWith(S.Array(TranscriptionSegment), { nullable: true })
|
|
@@ -342,7 +344,7 @@ export class CreateTranslationResponseJson extends S.Struct({
|
|
|
342
344
|
|
|
343
345
|
export class CreateTranslationResponseVerboseJson extends S.Struct({
|
|
344
346
|
"language": S.String,
|
|
345
|
-
"duration": S.
|
|
347
|
+
"duration": S.Number,
|
|
346
348
|
"text": S.String,
|
|
347
349
|
"segments": S.optionalWith(S.Array(TranscriptionSegment), { nullable: true })
|
|
348
350
|
}) {}
|
|
@@ -410,7 +412,7 @@ export class Batch extends S.Struct({
|
|
|
410
412
|
}),
|
|
411
413
|
{ nullable: true }
|
|
412
414
|
),
|
|
413
|
-
"metadata": S.optionalWith(
|
|
415
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
414
416
|
}) {}
|
|
415
417
|
|
|
416
418
|
export class ListBatchesResponseObject extends S.Literal("list") {}
|
|
@@ -433,7 +435,7 @@ export class CreateBatchRequest extends S.Class<CreateBatchRequest>("CreateBatch
|
|
|
433
435
|
"input_file_id": S.String,
|
|
434
436
|
"endpoint": CreateBatchRequestEndpoint,
|
|
435
437
|
"completion_window": CreateBatchRequestCompletionWindow,
|
|
436
|
-
"metadata": S.optionalWith(
|
|
438
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
437
439
|
}) {}
|
|
438
440
|
|
|
439
441
|
export class ChatCompletionRequestMessageContentPartTextType extends S.Literal("text") {}
|
|
@@ -579,6 +581,8 @@ export class ChatCompletionRequestMessage extends S.Union(
|
|
|
579
581
|
) {}
|
|
580
582
|
|
|
581
583
|
export class CreateChatCompletionRequestModel extends S.Literal(
|
|
584
|
+
"o3-mini",
|
|
585
|
+
"o3-mini-2025-01-31",
|
|
582
586
|
"o1",
|
|
583
587
|
"o1-2024-12-17",
|
|
584
588
|
"o1-preview",
|
|
@@ -683,7 +687,7 @@ export class CreateChatCompletionRequest extends S.Class<CreateChatCompletionReq
|
|
|
683
687
|
nullable: true,
|
|
684
688
|
default: () => "medium" as const
|
|
685
689
|
}),
|
|
686
|
-
"metadata": S.optionalWith(
|
|
690
|
+
"metadata": S.optionalWith(Metadata, { nullable: true }),
|
|
687
691
|
"frequency_penalty": S.optionalWith(S.Number.pipe(S.greaterThanOrEqualTo(-2), S.lessThanOrEqualTo(2)), {
|
|
688
692
|
nullable: true,
|
|
689
693
|
default: () => 0 as const
|
|
@@ -784,22 +788,22 @@ export class CreateChatCompletionResponseServiceTier extends S.Literal("scale",
|
|
|
784
788
|
export class CreateChatCompletionResponseObject extends S.Literal("chat.completion") {}
|
|
785
789
|
|
|
786
790
|
export class CompletionUsage extends S.Struct({
|
|
787
|
-
"completion_tokens": S.Int,
|
|
788
|
-
"prompt_tokens": S.Int,
|
|
789
|
-
"total_tokens": S.Int,
|
|
791
|
+
"completion_tokens": S.Int.pipe(S.propertySignature, S.withConstructorDefault(() => 0 as const)),
|
|
792
|
+
"prompt_tokens": S.Int.pipe(S.propertySignature, S.withConstructorDefault(() => 0 as const)),
|
|
793
|
+
"total_tokens": S.Int.pipe(S.propertySignature, S.withConstructorDefault(() => 0 as const)),
|
|
790
794
|
"completion_tokens_details": S.optionalWith(
|
|
791
795
|
S.Struct({
|
|
792
|
-
"accepted_prediction_tokens": S.optionalWith(S.Int, { nullable: true }),
|
|
793
|
-
"audio_tokens": S.optionalWith(S.Int, { nullable: true }),
|
|
794
|
-
"reasoning_tokens": S.optionalWith(S.Int, { nullable: true }),
|
|
795
|
-
"rejected_prediction_tokens": S.optionalWith(S.Int, { nullable: true })
|
|
796
|
+
"accepted_prediction_tokens": S.optionalWith(S.Int, { nullable: true, default: () => 0 as const }),
|
|
797
|
+
"audio_tokens": S.optionalWith(S.Int, { nullable: true, default: () => 0 as const }),
|
|
798
|
+
"reasoning_tokens": S.optionalWith(S.Int, { nullable: true, default: () => 0 as const }),
|
|
799
|
+
"rejected_prediction_tokens": S.optionalWith(S.Int, { nullable: true, default: () => 0 as const })
|
|
796
800
|
}),
|
|
797
801
|
{ nullable: true }
|
|
798
802
|
),
|
|
799
803
|
"prompt_tokens_details": S.optionalWith(
|
|
800
804
|
S.Struct({
|
|
801
|
-
"audio_tokens": S.optionalWith(S.Int, { nullable: true }),
|
|
802
|
-
"cached_tokens": S.optionalWith(S.Int, { nullable: true })
|
|
805
|
+
"audio_tokens": S.optionalWith(S.Int, { nullable: true, default: () => 0 as const }),
|
|
806
|
+
"cached_tokens": S.optionalWith(S.Int, { nullable: true, default: () => 0 as const })
|
|
803
807
|
}),
|
|
804
808
|
{ nullable: true }
|
|
805
809
|
)
|
|
@@ -2428,7 +2432,8 @@ export class UsageVectorStoresParams extends S.Struct({
|
|
|
2428
2432
|
|
|
2429
2433
|
export class ListUsersParams extends S.Struct({
|
|
2430
2434
|
"limit": S.optionalWith(S.Int, { nullable: true, default: () => 20 as const }),
|
|
2431
|
-
"after": S.optionalWith(S.String, { nullable: true })
|
|
2435
|
+
"after": S.optionalWith(S.String, { nullable: true }),
|
|
2436
|
+
"emails": S.optionalWith(S.Array(S.String), { nullable: true })
|
|
2432
2437
|
}) {}
|
|
2433
2438
|
|
|
2434
2439
|
export class UserListResponseObject extends S.Literal("list") {}
|
|
@@ -2497,7 +2502,9 @@ export class RealtimeSessionCreateRequest
|
|
|
2497
2502
|
"output_audio_format": S.optionalWith(RealtimeSessionCreateRequestOutputAudioFormat, { nullable: true }),
|
|
2498
2503
|
"input_audio_transcription": S.optionalWith(
|
|
2499
2504
|
S.Struct({
|
|
2500
|
-
"model": S.optionalWith(S.String, { nullable: true })
|
|
2505
|
+
"model": S.optionalWith(S.String, { nullable: true }),
|
|
2506
|
+
"language": S.optionalWith(S.String, { nullable: true }),
|
|
2507
|
+
"prompt": S.optionalWith(S.String, { nullable: true })
|
|
2501
2508
|
}),
|
|
2502
2509
|
{ nullable: true }
|
|
2503
2510
|
),
|
|
@@ -2538,13 +2545,10 @@ export class RealtimeSessionCreateResponseMaxResponseOutputTokens extends S.Lite
|
|
|
2538
2545
|
|
|
2539
2546
|
export class RealtimeSessionCreateResponse
|
|
2540
2547
|
extends S.Class<RealtimeSessionCreateResponse>("RealtimeSessionCreateResponse")({
|
|
2541
|
-
"client_secret": S.
|
|
2542
|
-
S.
|
|
2543
|
-
|
|
2544
|
-
|
|
2545
|
-
}),
|
|
2546
|
-
{ nullable: true }
|
|
2547
|
-
),
|
|
2548
|
+
"client_secret": S.Struct({
|
|
2549
|
+
"value": S.String,
|
|
2550
|
+
"expires_at": S.Int
|
|
2551
|
+
}),
|
|
2548
2552
|
"instructions": S.optionalWith(S.String, { nullable: true }),
|
|
2549
2553
|
"voice": S.optionalWith(RealtimeSessionCreateResponseVoice, { nullable: true }),
|
|
2550
2554
|
"input_audio_format": S.optionalWith(S.String, { nullable: true }),
|
|
@@ -2643,7 +2647,7 @@ export class CreateMessageRequest extends S.Struct({
|
|
|
2643
2647
|
})),
|
|
2644
2648
|
{ nullable: true }
|
|
2645
2649
|
),
|
|
2646
|
-
"metadata": S.optionalWith(
|
|
2650
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
2647
2651
|
}) {}
|
|
2648
2652
|
|
|
2649
2653
|
export class CreateThreadRequestToolResourcesFileSearchVectorStoresChunkingStrategyType extends S.Literal("static") {}
|
|
@@ -2668,7 +2672,7 @@ export class CreateThreadRequest extends S.Class<CreateThreadRequest>("CreateThr
|
|
|
2668
2672
|
S.Array(S.Struct({
|
|
2669
2673
|
"file_ids": S.optionalWith(S.Array(S.String).pipe(S.maxItems(10000)), { nullable: true }),
|
|
2670
2674
|
"chunking_strategy": S.optionalWith(S.Record({ key: S.String, value: S.Unknown }), { nullable: true }),
|
|
2671
|
-
"metadata": S.optionalWith(
|
|
2675
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
2672
2676
|
})).pipe(S.maxItems(1)),
|
|
2673
2677
|
{ nullable: true }
|
|
2674
2678
|
)
|
|
@@ -2678,7 +2682,7 @@ export class CreateThreadRequest extends S.Class<CreateThreadRequest>("CreateThr
|
|
|
2678
2682
|
}),
|
|
2679
2683
|
{ nullable: true }
|
|
2680
2684
|
),
|
|
2681
|
-
"metadata": S.optionalWith(
|
|
2685
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
2682
2686
|
}) {}
|
|
2683
2687
|
|
|
2684
2688
|
export class ThreadObjectObject extends S.Literal("thread") {}
|
|
@@ -2704,7 +2708,7 @@ export class ThreadObject extends S.Class<ThreadObject>("ThreadObject")({
|
|
|
2704
2708
|
{ nullable: true }
|
|
2705
2709
|
)
|
|
2706
2710
|
})),
|
|
2707
|
-
"metadata": S.NullOr(
|
|
2711
|
+
"metadata": S.NullOr(Metadata)
|
|
2708
2712
|
}) {}
|
|
2709
2713
|
|
|
2710
2714
|
export class CreateThreadAndRunRequestModel extends S.Literal(
|
|
@@ -2786,7 +2790,7 @@ export class CreateThreadAndRunRequest extends S.Class<CreateThreadAndRunRequest
|
|
|
2786
2790
|
}),
|
|
2787
2791
|
{ nullable: true }
|
|
2788
2792
|
),
|
|
2789
|
-
"metadata": S.optionalWith(
|
|
2793
|
+
"metadata": S.optionalWith(Metadata, { nullable: true }),
|
|
2790
2794
|
"temperature": S.optionalWith(S.Number.pipe(S.greaterThanOrEqualTo(0), S.lessThanOrEqualTo(2)), {
|
|
2791
2795
|
nullable: true,
|
|
2792
2796
|
default: () => 1 as const
|
|
@@ -2870,7 +2874,7 @@ export class RunObject extends S.Class<RunObject>("RunObject")({
|
|
|
2870
2874
|
"instructions": S.String,
|
|
2871
2875
|
"tools": S.Array(S.Union(AssistantToolsCode, AssistantToolsFileSearch, AssistantToolsFunction)).pipe(S.maxItems(20))
|
|
2872
2876
|
.pipe(S.propertySignature, S.withConstructorDefault(() => [] as const)),
|
|
2873
|
-
"metadata": S.NullOr(
|
|
2877
|
+
"metadata": S.NullOr(Metadata),
|
|
2874
2878
|
"usage": S.NullOr(RunCompletionUsage),
|
|
2875
2879
|
"temperature": S.optionalWith(S.Number, { nullable: true }),
|
|
2876
2880
|
"top_p": S.optionalWith(S.Number, { nullable: true }),
|
|
@@ -2903,7 +2907,7 @@ export class ModifyThreadRequest extends S.Class<ModifyThreadRequest>("ModifyThr
|
|
|
2903
2907
|
}),
|
|
2904
2908
|
{ nullable: true }
|
|
2905
2909
|
),
|
|
2906
|
-
"metadata": S.optionalWith(
|
|
2910
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
2907
2911
|
}) {}
|
|
2908
2912
|
|
|
2909
2913
|
export class DeleteThreadResponseObject extends S.Literal("thread.deleted") {}
|
|
@@ -3003,7 +3007,7 @@ export class MessageObject extends S.Struct({
|
|
|
3003
3007
|
"file_id": S.optionalWith(S.String, { nullable: true }),
|
|
3004
3008
|
"tools": S.optionalWith(S.Array(S.Union(AssistantToolsCode, AssistantToolsFileSearchTypeOnly)), { nullable: true })
|
|
3005
3009
|
}))),
|
|
3006
|
-
"metadata": S.NullOr(
|
|
3010
|
+
"metadata": S.NullOr(Metadata)
|
|
3007
3011
|
}) {}
|
|
3008
3012
|
|
|
3009
3013
|
export class ListMessagesResponse extends S.Class<ListMessagesResponse>("ListMessagesResponse")({
|
|
@@ -3015,7 +3019,7 @@ export class ListMessagesResponse extends S.Class<ListMessagesResponse>("ListMes
|
|
|
3015
3019
|
}) {}
|
|
3016
3020
|
|
|
3017
3021
|
export class ModifyMessageRequest extends S.Class<ModifyMessageRequest>("ModifyMessageRequest")({
|
|
3018
|
-
"metadata": S.optionalWith(
|
|
3022
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
3019
3023
|
}) {}
|
|
3020
3024
|
|
|
3021
3025
|
export class DeleteMessageResponseObject extends S.Literal("thread.message.deleted") {}
|
|
@@ -3086,7 +3090,7 @@ export class CreateRunRequest extends S.Class<CreateRunRequest>("CreateRunReques
|
|
|
3086
3090
|
S.Array(S.Union(AssistantToolsCode, AssistantToolsFileSearch, AssistantToolsFunction)).pipe(S.maxItems(20)),
|
|
3087
3091
|
{ nullable: true }
|
|
3088
3092
|
),
|
|
3089
|
-
"metadata": S.optionalWith(
|
|
3093
|
+
"metadata": S.optionalWith(Metadata, { nullable: true }),
|
|
3090
3094
|
"temperature": S.optionalWith(S.Number.pipe(S.greaterThanOrEqualTo(0), S.lessThanOrEqualTo(2)), {
|
|
3091
3095
|
nullable: true,
|
|
3092
3096
|
default: () => 1 as const
|
|
@@ -3105,7 +3109,7 @@ export class CreateRunRequest extends S.Class<CreateRunRequest>("CreateRunReques
|
|
|
3105
3109
|
}) {}
|
|
3106
3110
|
|
|
3107
3111
|
export class ModifyRunRequest extends S.Class<ModifyRunRequest>("ModifyRunRequest")({
|
|
3108
|
-
"metadata": S.optionalWith(
|
|
3112
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
3109
3113
|
}) {}
|
|
3110
3114
|
|
|
3111
3115
|
export class ListRunStepsParamsOrder extends S.Literal("asc", "desc") {}
|
|
@@ -3246,7 +3250,7 @@ export class RunStepObject extends S.Struct({
|
|
|
3246
3250
|
"cancelled_at": S.NullOr(S.Int),
|
|
3247
3251
|
"failed_at": S.NullOr(S.Int),
|
|
3248
3252
|
"completed_at": S.NullOr(S.Int),
|
|
3249
|
-
"metadata": S.NullOr(
|
|
3253
|
+
"metadata": S.NullOr(Metadata),
|
|
3250
3254
|
"usage": S.NullOr(RunStepCompletionUsage)
|
|
3251
3255
|
}) {}
|
|
3252
3256
|
|
|
@@ -3348,7 +3352,7 @@ export class VectorStoreObject extends S.Struct({
|
|
|
3348
3352
|
"expires_after": S.optionalWith(VectorStoreExpirationAfter, { nullable: true }),
|
|
3349
3353
|
"expires_at": S.optionalWith(S.Int, { nullable: true }),
|
|
3350
3354
|
"last_active_at": S.NullOr(S.Int),
|
|
3351
|
-
"metadata": S.NullOr(
|
|
3355
|
+
"metadata": S.NullOr(Metadata)
|
|
3352
3356
|
}) {}
|
|
3353
3357
|
|
|
3354
3358
|
export class ListVectorStoresResponse extends S.Class<ListVectorStoresResponse>("ListVectorStoresResponse")({
|
|
@@ -3382,13 +3386,13 @@ export class CreateVectorStoreRequest extends S.Class<CreateVectorStoreRequest>(
|
|
|
3382
3386
|
"name": S.optionalWith(S.String, { nullable: true }),
|
|
3383
3387
|
"expires_after": S.optionalWith(VectorStoreExpirationAfter, { nullable: true }),
|
|
3384
3388
|
"chunking_strategy": S.optionalWith(S.Record({ key: S.String, value: S.Unknown }), { nullable: true }),
|
|
3385
|
-
"metadata": S.optionalWith(
|
|
3389
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
3386
3390
|
}) {}
|
|
3387
3391
|
|
|
3388
3392
|
export class UpdateVectorStoreRequest extends S.Class<UpdateVectorStoreRequest>("UpdateVectorStoreRequest")({
|
|
3389
3393
|
"name": S.optionalWith(S.String, { nullable: true }),
|
|
3390
3394
|
"expires_after": S.optionalWith(VectorStoreExpirationAfter, { nullable: true }),
|
|
3391
|
-
"metadata": S.optionalWith(
|
|
3395
|
+
"metadata": S.optionalWith(Metadata, { nullable: true })
|
|
3392
3396
|
}) {}
|
|
3393
3397
|
|
|
3394
3398
|
export class DeleteVectorStoreResponseObject extends S.Literal("vector_store.deleted") {}
|
|
@@ -3513,7 +3517,12 @@ export class DeleteVectorStoreFileResponse
|
|
|
3513
3517
|
})
|
|
3514
3518
|
{}
|
|
3515
3519
|
|
|
3516
|
-
export const make = (
|
|
3520
|
+
export const make = (
|
|
3521
|
+
httpClient: HttpClient.HttpClient,
|
|
3522
|
+
options: {
|
|
3523
|
+
readonly transformClient?: ((client: HttpClient.HttpClient) => Effect.Effect<HttpClient.HttpClient>) | undefined
|
|
3524
|
+
} = {}
|
|
3525
|
+
): Client => {
|
|
3517
3526
|
const unexpectedStatus = (
|
|
3518
3527
|
request: HttpClientRequest.HttpClientRequest,
|
|
3519
3528
|
response: HttpClientResponse.HttpClientResponse
|
|
@@ -3530,6 +3539,8 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3530
3539
|
})
|
|
3531
3540
|
)
|
|
3532
3541
|
)
|
|
3542
|
+
const applyClientTransform = (client: HttpClient.HttpClient): Effect.Effect<HttpClient.HttpClient> =>
|
|
3543
|
+
options.transformClient ? options.transformClient(client) : Effect.succeed(client)
|
|
3533
3544
|
const decodeError = <A, I, R>(response: HttpClientResponse.HttpClientResponse, schema: S.Schema<A, I, R>) =>
|
|
3534
3545
|
Effect.flatMap(HttpClientResponse.schemaBodyJson(schema)(response), Effect.fail)
|
|
3535
3546
|
return {
|
|
@@ -3543,13 +3554,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3543
3554
|
}),
|
|
3544
3555
|
Effect.succeed,
|
|
3545
3556
|
Effect.flatMap((request) =>
|
|
3546
|
-
Effect.flatMap(
|
|
3547
|
-
|
|
3548
|
-
|
|
3549
|
-
|
|
3550
|
-
|
|
3551
|
-
|
|
3552
|
-
|
|
3557
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3558
|
+
Effect.flatMap(
|
|
3559
|
+
httpClient.execute(request),
|
|
3560
|
+
HttpClientResponse.matchStatus({
|
|
3561
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListAssistantsResponse)(r),
|
|
3562
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3563
|
+
})
|
|
3564
|
+
))
|
|
3553
3565
|
),
|
|
3554
3566
|
Effect.scoped
|
|
3555
3567
|
),
|
|
@@ -3557,13 +3569,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3557
3569
|
HttpClientRequest.make("POST")(`/assistants`).pipe(
|
|
3558
3570
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3559
3571
|
Effect.flatMap((request) =>
|
|
3560
|
-
Effect.flatMap(
|
|
3561
|
-
|
|
3562
|
-
|
|
3563
|
-
|
|
3564
|
-
|
|
3565
|
-
|
|
3566
|
-
|
|
3572
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3573
|
+
Effect.flatMap(
|
|
3574
|
+
httpClient.execute(request),
|
|
3575
|
+
HttpClientResponse.matchStatus({
|
|
3576
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(AssistantObject)(r),
|
|
3577
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3578
|
+
})
|
|
3579
|
+
))
|
|
3567
3580
|
),
|
|
3568
3581
|
Effect.scoped
|
|
3569
3582
|
),
|
|
@@ -3571,13 +3584,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3571
3584
|
HttpClientRequest.make("GET")(`/assistants/${assistantId}`).pipe(
|
|
3572
3585
|
Effect.succeed,
|
|
3573
3586
|
Effect.flatMap((request) =>
|
|
3574
|
-
Effect.flatMap(
|
|
3575
|
-
|
|
3576
|
-
|
|
3577
|
-
|
|
3578
|
-
|
|
3579
|
-
|
|
3580
|
-
|
|
3587
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3588
|
+
Effect.flatMap(
|
|
3589
|
+
httpClient.execute(request),
|
|
3590
|
+
HttpClientResponse.matchStatus({
|
|
3591
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(AssistantObject)(r),
|
|
3592
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3593
|
+
})
|
|
3594
|
+
))
|
|
3581
3595
|
),
|
|
3582
3596
|
Effect.scoped
|
|
3583
3597
|
),
|
|
@@ -3585,13 +3599,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3585
3599
|
HttpClientRequest.make("POST")(`/assistants/${assistantId}`).pipe(
|
|
3586
3600
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3587
3601
|
Effect.flatMap((request) =>
|
|
3588
|
-
Effect.flatMap(
|
|
3589
|
-
|
|
3590
|
-
|
|
3591
|
-
|
|
3592
|
-
|
|
3593
|
-
|
|
3594
|
-
|
|
3602
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3603
|
+
Effect.flatMap(
|
|
3604
|
+
httpClient.execute(request),
|
|
3605
|
+
HttpClientResponse.matchStatus({
|
|
3606
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(AssistantObject)(r),
|
|
3607
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3608
|
+
})
|
|
3609
|
+
))
|
|
3595
3610
|
),
|
|
3596
3611
|
Effect.scoped
|
|
3597
3612
|
),
|
|
@@ -3599,13 +3614,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3599
3614
|
HttpClientRequest.make("DELETE")(`/assistants/${assistantId}`).pipe(
|
|
3600
3615
|
Effect.succeed,
|
|
3601
3616
|
Effect.flatMap((request) =>
|
|
3602
|
-
Effect.flatMap(
|
|
3603
|
-
|
|
3604
|
-
|
|
3605
|
-
|
|
3606
|
-
|
|
3607
|
-
|
|
3608
|
-
|
|
3617
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3618
|
+
Effect.flatMap(
|
|
3619
|
+
httpClient.execute(request),
|
|
3620
|
+
HttpClientResponse.matchStatus({
|
|
3621
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteAssistantResponse)(r),
|
|
3622
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3623
|
+
})
|
|
3624
|
+
))
|
|
3609
3625
|
),
|
|
3610
3626
|
Effect.scoped
|
|
3611
3627
|
),
|
|
@@ -3613,12 +3629,13 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3613
3629
|
HttpClientRequest.make("POST")(`/audio/speech`).pipe(
|
|
3614
3630
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3615
3631
|
Effect.flatMap((request) =>
|
|
3616
|
-
Effect.flatMap(
|
|
3617
|
-
|
|
3618
|
-
|
|
3619
|
-
|
|
3620
|
-
|
|
3621
|
-
|
|
3632
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3633
|
+
Effect.flatMap(
|
|
3634
|
+
httpClient.execute(request),
|
|
3635
|
+
HttpClientResponse.matchStatus({
|
|
3636
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3637
|
+
})
|
|
3638
|
+
))
|
|
3622
3639
|
),
|
|
3623
3640
|
Effect.scoped
|
|
3624
3641
|
),
|
|
@@ -3627,13 +3644,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3627
3644
|
HttpClientRequest.bodyFormData(options),
|
|
3628
3645
|
Effect.succeed,
|
|
3629
3646
|
Effect.flatMap((request) =>
|
|
3630
|
-
Effect.flatMap(
|
|
3631
|
-
|
|
3632
|
-
|
|
3633
|
-
|
|
3634
|
-
|
|
3635
|
-
|
|
3636
|
-
|
|
3647
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3648
|
+
Effect.flatMap(
|
|
3649
|
+
httpClient.execute(request),
|
|
3650
|
+
HttpClientResponse.matchStatus({
|
|
3651
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(CreateTranscription200)(r),
|
|
3652
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3653
|
+
})
|
|
3654
|
+
))
|
|
3637
3655
|
),
|
|
3638
3656
|
Effect.scoped
|
|
3639
3657
|
),
|
|
@@ -3642,13 +3660,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3642
3660
|
HttpClientRequest.bodyFormData(options),
|
|
3643
3661
|
Effect.succeed,
|
|
3644
3662
|
Effect.flatMap((request) =>
|
|
3645
|
-
Effect.flatMap(
|
|
3646
|
-
|
|
3647
|
-
|
|
3648
|
-
|
|
3649
|
-
|
|
3650
|
-
|
|
3651
|
-
|
|
3663
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3664
|
+
Effect.flatMap(
|
|
3665
|
+
httpClient.execute(request),
|
|
3666
|
+
HttpClientResponse.matchStatus({
|
|
3667
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(CreateTranslation200)(r),
|
|
3668
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3669
|
+
})
|
|
3670
|
+
))
|
|
3652
3671
|
),
|
|
3653
3672
|
Effect.scoped
|
|
3654
3673
|
),
|
|
@@ -3657,13 +3676,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3657
3676
|
HttpClientRequest.setUrlParams({ "after": options["after"], "limit": options["limit"] }),
|
|
3658
3677
|
Effect.succeed,
|
|
3659
3678
|
Effect.flatMap((request) =>
|
|
3660
|
-
Effect.flatMap(
|
|
3661
|
-
|
|
3662
|
-
|
|
3663
|
-
|
|
3664
|
-
|
|
3665
|
-
|
|
3666
|
-
|
|
3679
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3680
|
+
Effect.flatMap(
|
|
3681
|
+
httpClient.execute(request),
|
|
3682
|
+
HttpClientResponse.matchStatus({
|
|
3683
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListBatchesResponse)(r),
|
|
3684
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3685
|
+
})
|
|
3686
|
+
))
|
|
3667
3687
|
),
|
|
3668
3688
|
Effect.scoped
|
|
3669
3689
|
),
|
|
@@ -3671,13 +3691,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3671
3691
|
HttpClientRequest.make("POST")(`/batches`).pipe(
|
|
3672
3692
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3673
3693
|
Effect.flatMap((request) =>
|
|
3674
|
-
Effect.flatMap(
|
|
3675
|
-
|
|
3676
|
-
|
|
3677
|
-
|
|
3678
|
-
|
|
3679
|
-
|
|
3680
|
-
|
|
3694
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3695
|
+
Effect.flatMap(
|
|
3696
|
+
httpClient.execute(request),
|
|
3697
|
+
HttpClientResponse.matchStatus({
|
|
3698
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Batch)(r),
|
|
3699
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3700
|
+
})
|
|
3701
|
+
))
|
|
3681
3702
|
),
|
|
3682
3703
|
Effect.scoped
|
|
3683
3704
|
),
|
|
@@ -3685,13 +3706,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3685
3706
|
HttpClientRequest.make("GET")(`/batches/${batchId}`).pipe(
|
|
3686
3707
|
Effect.succeed,
|
|
3687
3708
|
Effect.flatMap((request) =>
|
|
3688
|
-
Effect.flatMap(
|
|
3689
|
-
|
|
3690
|
-
|
|
3691
|
-
|
|
3692
|
-
|
|
3693
|
-
|
|
3694
|
-
|
|
3709
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3710
|
+
Effect.flatMap(
|
|
3711
|
+
httpClient.execute(request),
|
|
3712
|
+
HttpClientResponse.matchStatus({
|
|
3713
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Batch)(r),
|
|
3714
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3715
|
+
})
|
|
3716
|
+
))
|
|
3695
3717
|
),
|
|
3696
3718
|
Effect.scoped
|
|
3697
3719
|
),
|
|
@@ -3699,13 +3721,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3699
3721
|
HttpClientRequest.make("POST")(`/batches/${batchId}/cancel`).pipe(
|
|
3700
3722
|
Effect.succeed,
|
|
3701
3723
|
Effect.flatMap((request) =>
|
|
3702
|
-
Effect.flatMap(
|
|
3703
|
-
|
|
3704
|
-
|
|
3705
|
-
|
|
3706
|
-
|
|
3707
|
-
|
|
3708
|
-
|
|
3724
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3725
|
+
Effect.flatMap(
|
|
3726
|
+
httpClient.execute(request),
|
|
3727
|
+
HttpClientResponse.matchStatus({
|
|
3728
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Batch)(r),
|
|
3729
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3730
|
+
})
|
|
3731
|
+
))
|
|
3709
3732
|
),
|
|
3710
3733
|
Effect.scoped
|
|
3711
3734
|
),
|
|
@@ -3713,13 +3736,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3713
3736
|
HttpClientRequest.make("POST")(`/chat/completions`).pipe(
|
|
3714
3737
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3715
3738
|
Effect.flatMap((request) =>
|
|
3716
|
-
Effect.flatMap(
|
|
3717
|
-
|
|
3718
|
-
|
|
3719
|
-
|
|
3720
|
-
|
|
3721
|
-
|
|
3722
|
-
|
|
3739
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3740
|
+
Effect.flatMap(
|
|
3741
|
+
httpClient.execute(request),
|
|
3742
|
+
HttpClientResponse.matchStatus({
|
|
3743
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(CreateChatCompletionResponse)(r),
|
|
3744
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3745
|
+
})
|
|
3746
|
+
))
|
|
3723
3747
|
),
|
|
3724
3748
|
Effect.scoped
|
|
3725
3749
|
),
|
|
@@ -3727,13 +3751,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3727
3751
|
HttpClientRequest.make("POST")(`/completions`).pipe(
|
|
3728
3752
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3729
3753
|
Effect.flatMap((request) =>
|
|
3730
|
-
Effect.flatMap(
|
|
3731
|
-
|
|
3732
|
-
|
|
3733
|
-
|
|
3734
|
-
|
|
3735
|
-
|
|
3736
|
-
|
|
3754
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3755
|
+
Effect.flatMap(
|
|
3756
|
+
httpClient.execute(request),
|
|
3757
|
+
HttpClientResponse.matchStatus({
|
|
3758
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(CreateCompletionResponse)(r),
|
|
3759
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3760
|
+
})
|
|
3761
|
+
))
|
|
3737
3762
|
),
|
|
3738
3763
|
Effect.scoped
|
|
3739
3764
|
),
|
|
@@ -3741,13 +3766,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3741
3766
|
HttpClientRequest.make("POST")(`/embeddings`).pipe(
|
|
3742
3767
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3743
3768
|
Effect.flatMap((request) =>
|
|
3744
|
-
Effect.flatMap(
|
|
3745
|
-
|
|
3746
|
-
|
|
3747
|
-
|
|
3748
|
-
|
|
3749
|
-
|
|
3750
|
-
|
|
3769
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3770
|
+
Effect.flatMap(
|
|
3771
|
+
httpClient.execute(request),
|
|
3772
|
+
HttpClientResponse.matchStatus({
|
|
3773
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(CreateEmbeddingResponse)(r),
|
|
3774
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3775
|
+
})
|
|
3776
|
+
))
|
|
3751
3777
|
),
|
|
3752
3778
|
Effect.scoped
|
|
3753
3779
|
),
|
|
@@ -3761,13 +3787,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3761
3787
|
}),
|
|
3762
3788
|
Effect.succeed,
|
|
3763
3789
|
Effect.flatMap((request) =>
|
|
3764
|
-
Effect.flatMap(
|
|
3765
|
-
|
|
3766
|
-
|
|
3767
|
-
|
|
3768
|
-
|
|
3769
|
-
|
|
3770
|
-
|
|
3790
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3791
|
+
Effect.flatMap(
|
|
3792
|
+
httpClient.execute(request),
|
|
3793
|
+
HttpClientResponse.matchStatus({
|
|
3794
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListFilesResponse)(r),
|
|
3795
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3796
|
+
})
|
|
3797
|
+
))
|
|
3771
3798
|
),
|
|
3772
3799
|
Effect.scoped
|
|
3773
3800
|
),
|
|
@@ -3776,13 +3803,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3776
3803
|
HttpClientRequest.bodyFormData(options),
|
|
3777
3804
|
Effect.succeed,
|
|
3778
3805
|
Effect.flatMap((request) =>
|
|
3779
|
-
Effect.flatMap(
|
|
3780
|
-
|
|
3781
|
-
|
|
3782
|
-
|
|
3783
|
-
|
|
3784
|
-
|
|
3785
|
-
|
|
3806
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3807
|
+
Effect.flatMap(
|
|
3808
|
+
httpClient.execute(request),
|
|
3809
|
+
HttpClientResponse.matchStatus({
|
|
3810
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(OpenAIFile)(r),
|
|
3811
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3812
|
+
})
|
|
3813
|
+
))
|
|
3786
3814
|
),
|
|
3787
3815
|
Effect.scoped
|
|
3788
3816
|
),
|
|
@@ -3790,13 +3818,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3790
3818
|
HttpClientRequest.make("GET")(`/files/${fileId}`).pipe(
|
|
3791
3819
|
Effect.succeed,
|
|
3792
3820
|
Effect.flatMap((request) =>
|
|
3793
|
-
Effect.flatMap(
|
|
3794
|
-
|
|
3795
|
-
|
|
3796
|
-
|
|
3797
|
-
|
|
3798
|
-
|
|
3799
|
-
|
|
3821
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3822
|
+
Effect.flatMap(
|
|
3823
|
+
httpClient.execute(request),
|
|
3824
|
+
HttpClientResponse.matchStatus({
|
|
3825
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(OpenAIFile)(r),
|
|
3826
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3827
|
+
})
|
|
3828
|
+
))
|
|
3800
3829
|
),
|
|
3801
3830
|
Effect.scoped
|
|
3802
3831
|
),
|
|
@@ -3804,13 +3833,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3804
3833
|
HttpClientRequest.make("DELETE")(`/files/${fileId}`).pipe(
|
|
3805
3834
|
Effect.succeed,
|
|
3806
3835
|
Effect.flatMap((request) =>
|
|
3807
|
-
Effect.flatMap(
|
|
3808
|
-
|
|
3809
|
-
|
|
3810
|
-
|
|
3811
|
-
|
|
3812
|
-
|
|
3813
|
-
|
|
3836
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3837
|
+
Effect.flatMap(
|
|
3838
|
+
httpClient.execute(request),
|
|
3839
|
+
HttpClientResponse.matchStatus({
|
|
3840
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteFileResponse)(r),
|
|
3841
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3842
|
+
})
|
|
3843
|
+
))
|
|
3814
3844
|
),
|
|
3815
3845
|
Effect.scoped
|
|
3816
3846
|
),
|
|
@@ -3818,13 +3848,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3818
3848
|
HttpClientRequest.make("GET")(`/files/${fileId}/content`).pipe(
|
|
3819
3849
|
Effect.succeed,
|
|
3820
3850
|
Effect.flatMap((request) =>
|
|
3821
|
-
Effect.flatMap(
|
|
3822
|
-
|
|
3823
|
-
|
|
3824
|
-
|
|
3825
|
-
|
|
3826
|
-
|
|
3827
|
-
|
|
3851
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3852
|
+
Effect.flatMap(
|
|
3853
|
+
httpClient.execute(request),
|
|
3854
|
+
HttpClientResponse.matchStatus({
|
|
3855
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DownloadFile200)(r),
|
|
3856
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3857
|
+
})
|
|
3858
|
+
))
|
|
3828
3859
|
),
|
|
3829
3860
|
Effect.scoped
|
|
3830
3861
|
),
|
|
@@ -3833,13 +3864,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3833
3864
|
HttpClientRequest.setUrlParams({ "after": options["after"], "limit": options["limit"] }),
|
|
3834
3865
|
Effect.succeed,
|
|
3835
3866
|
Effect.flatMap((request) =>
|
|
3836
|
-
Effect.flatMap(
|
|
3837
|
-
|
|
3838
|
-
|
|
3839
|
-
|
|
3840
|
-
|
|
3841
|
-
|
|
3842
|
-
|
|
3867
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3868
|
+
Effect.flatMap(
|
|
3869
|
+
httpClient.execute(request),
|
|
3870
|
+
HttpClientResponse.matchStatus({
|
|
3871
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListPaginatedFineTuningJobsResponse)(r),
|
|
3872
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3873
|
+
})
|
|
3874
|
+
))
|
|
3843
3875
|
),
|
|
3844
3876
|
Effect.scoped
|
|
3845
3877
|
),
|
|
@@ -3847,13 +3879,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3847
3879
|
HttpClientRequest.make("POST")(`/fine_tuning/jobs`).pipe(
|
|
3848
3880
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3849
3881
|
Effect.flatMap((request) =>
|
|
3850
|
-
Effect.flatMap(
|
|
3851
|
-
|
|
3852
|
-
|
|
3853
|
-
|
|
3854
|
-
|
|
3855
|
-
|
|
3856
|
-
|
|
3882
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3883
|
+
Effect.flatMap(
|
|
3884
|
+
httpClient.execute(request),
|
|
3885
|
+
HttpClientResponse.matchStatus({
|
|
3886
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(FineTuningJob)(r),
|
|
3887
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3888
|
+
})
|
|
3889
|
+
))
|
|
3857
3890
|
),
|
|
3858
3891
|
Effect.scoped
|
|
3859
3892
|
),
|
|
@@ -3862,11 +3895,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3862
3895
|
Effect.succeed,
|
|
3863
3896
|
Effect.flatMap((request) =>
|
|
3864
3897
|
Effect.flatMap(
|
|
3865
|
-
httpClient
|
|
3866
|
-
|
|
3867
|
-
|
|
3868
|
-
|
|
3869
|
-
|
|
3898
|
+
applyClientTransform(httpClient),
|
|
3899
|
+
(httpClient) =>
|
|
3900
|
+
Effect.flatMap(
|
|
3901
|
+
httpClient.execute(request),
|
|
3902
|
+
HttpClientResponse.matchStatus({
|
|
3903
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(FineTuningJob)(r),
|
|
3904
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3905
|
+
})
|
|
3906
|
+
)
|
|
3870
3907
|
)
|
|
3871
3908
|
),
|
|
3872
3909
|
Effect.scoped
|
|
@@ -3876,11 +3913,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3876
3913
|
Effect.succeed,
|
|
3877
3914
|
Effect.flatMap((request) =>
|
|
3878
3915
|
Effect.flatMap(
|
|
3879
|
-
httpClient
|
|
3880
|
-
|
|
3881
|
-
|
|
3882
|
-
|
|
3883
|
-
|
|
3916
|
+
applyClientTransform(httpClient),
|
|
3917
|
+
(httpClient) =>
|
|
3918
|
+
Effect.flatMap(
|
|
3919
|
+
httpClient.execute(request),
|
|
3920
|
+
HttpClientResponse.matchStatus({
|
|
3921
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(FineTuningJob)(r),
|
|
3922
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3923
|
+
})
|
|
3924
|
+
)
|
|
3884
3925
|
)
|
|
3885
3926
|
),
|
|
3886
3927
|
Effect.scoped
|
|
@@ -3891,11 +3932,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3891
3932
|
Effect.succeed,
|
|
3892
3933
|
Effect.flatMap((request) =>
|
|
3893
3934
|
Effect.flatMap(
|
|
3894
|
-
httpClient
|
|
3895
|
-
|
|
3896
|
-
|
|
3897
|
-
|
|
3898
|
-
|
|
3935
|
+
applyClientTransform(httpClient),
|
|
3936
|
+
(httpClient) =>
|
|
3937
|
+
Effect.flatMap(
|
|
3938
|
+
httpClient.execute(request),
|
|
3939
|
+
HttpClientResponse.matchStatus({
|
|
3940
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListFineTuningJobCheckpointsResponse)(r),
|
|
3941
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3942
|
+
})
|
|
3943
|
+
)
|
|
3899
3944
|
)
|
|
3900
3945
|
),
|
|
3901
3946
|
Effect.scoped
|
|
@@ -3906,11 +3951,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3906
3951
|
Effect.succeed,
|
|
3907
3952
|
Effect.flatMap((request) =>
|
|
3908
3953
|
Effect.flatMap(
|
|
3909
|
-
httpClient
|
|
3910
|
-
|
|
3911
|
-
|
|
3912
|
-
|
|
3913
|
-
|
|
3954
|
+
applyClientTransform(httpClient),
|
|
3955
|
+
(httpClient) =>
|
|
3956
|
+
Effect.flatMap(
|
|
3957
|
+
httpClient.execute(request),
|
|
3958
|
+
HttpClientResponse.matchStatus({
|
|
3959
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListFineTuningJobEventsResponse)(r),
|
|
3960
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3961
|
+
})
|
|
3962
|
+
)
|
|
3914
3963
|
)
|
|
3915
3964
|
),
|
|
3916
3965
|
Effect.scoped
|
|
@@ -3920,13 +3969,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3920
3969
|
HttpClientRequest.bodyFormData(options),
|
|
3921
3970
|
Effect.succeed,
|
|
3922
3971
|
Effect.flatMap((request) =>
|
|
3923
|
-
Effect.flatMap(
|
|
3924
|
-
|
|
3925
|
-
|
|
3926
|
-
|
|
3927
|
-
|
|
3928
|
-
|
|
3929
|
-
|
|
3972
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3973
|
+
Effect.flatMap(
|
|
3974
|
+
httpClient.execute(request),
|
|
3975
|
+
HttpClientResponse.matchStatus({
|
|
3976
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ImagesResponse)(r),
|
|
3977
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3978
|
+
})
|
|
3979
|
+
))
|
|
3930
3980
|
),
|
|
3931
3981
|
Effect.scoped
|
|
3932
3982
|
),
|
|
@@ -3934,13 +3984,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3934
3984
|
HttpClientRequest.make("POST")(`/images/generations`).pipe(
|
|
3935
3985
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
3936
3986
|
Effect.flatMap((request) =>
|
|
3937
|
-
Effect.flatMap(
|
|
3938
|
-
|
|
3939
|
-
|
|
3940
|
-
|
|
3941
|
-
|
|
3942
|
-
|
|
3943
|
-
|
|
3987
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
3988
|
+
Effect.flatMap(
|
|
3989
|
+
httpClient.execute(request),
|
|
3990
|
+
HttpClientResponse.matchStatus({
|
|
3991
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ImagesResponse)(r),
|
|
3992
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
3993
|
+
})
|
|
3994
|
+
))
|
|
3944
3995
|
),
|
|
3945
3996
|
Effect.scoped
|
|
3946
3997
|
),
|
|
@@ -3949,13 +4000,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3949
4000
|
HttpClientRequest.bodyFormData(options),
|
|
3950
4001
|
Effect.succeed,
|
|
3951
4002
|
Effect.flatMap((request) =>
|
|
3952
|
-
Effect.flatMap(
|
|
3953
|
-
|
|
3954
|
-
|
|
3955
|
-
|
|
3956
|
-
|
|
3957
|
-
|
|
3958
|
-
|
|
4003
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4004
|
+
Effect.flatMap(
|
|
4005
|
+
httpClient.execute(request),
|
|
4006
|
+
HttpClientResponse.matchStatus({
|
|
4007
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ImagesResponse)(r),
|
|
4008
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4009
|
+
})
|
|
4010
|
+
))
|
|
3959
4011
|
),
|
|
3960
4012
|
Effect.scoped
|
|
3961
4013
|
),
|
|
@@ -3963,13 +4015,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3963
4015
|
HttpClientRequest.make("GET")(`/models`).pipe(
|
|
3964
4016
|
Effect.succeed,
|
|
3965
4017
|
Effect.flatMap((request) =>
|
|
3966
|
-
Effect.flatMap(
|
|
3967
|
-
|
|
3968
|
-
|
|
3969
|
-
|
|
3970
|
-
|
|
3971
|
-
|
|
3972
|
-
|
|
4018
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4019
|
+
Effect.flatMap(
|
|
4020
|
+
httpClient.execute(request),
|
|
4021
|
+
HttpClientResponse.matchStatus({
|
|
4022
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListModelsResponse)(r),
|
|
4023
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4024
|
+
})
|
|
4025
|
+
))
|
|
3973
4026
|
),
|
|
3974
4027
|
Effect.scoped
|
|
3975
4028
|
),
|
|
@@ -3977,13 +4030,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3977
4030
|
HttpClientRequest.make("GET")(`/models/${model}`).pipe(
|
|
3978
4031
|
Effect.succeed,
|
|
3979
4032
|
Effect.flatMap((request) =>
|
|
3980
|
-
Effect.flatMap(
|
|
3981
|
-
|
|
3982
|
-
|
|
3983
|
-
|
|
3984
|
-
|
|
3985
|
-
|
|
3986
|
-
|
|
4033
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4034
|
+
Effect.flatMap(
|
|
4035
|
+
httpClient.execute(request),
|
|
4036
|
+
HttpClientResponse.matchStatus({
|
|
4037
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Model)(r),
|
|
4038
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4039
|
+
})
|
|
4040
|
+
))
|
|
3987
4041
|
),
|
|
3988
4042
|
Effect.scoped
|
|
3989
4043
|
),
|
|
@@ -3991,13 +4045,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
3991
4045
|
HttpClientRequest.make("DELETE")(`/models/${model}`).pipe(
|
|
3992
4046
|
Effect.succeed,
|
|
3993
4047
|
Effect.flatMap((request) =>
|
|
3994
|
-
Effect.flatMap(
|
|
3995
|
-
|
|
3996
|
-
|
|
3997
|
-
|
|
3998
|
-
|
|
3999
|
-
|
|
4000
|
-
|
|
4048
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4049
|
+
Effect.flatMap(
|
|
4050
|
+
httpClient.execute(request),
|
|
4051
|
+
HttpClientResponse.matchStatus({
|
|
4052
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteModelResponse)(r),
|
|
4053
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4054
|
+
})
|
|
4055
|
+
))
|
|
4001
4056
|
),
|
|
4002
4057
|
Effect.scoped
|
|
4003
4058
|
),
|
|
@@ -4005,13 +4060,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4005
4060
|
HttpClientRequest.make("POST")(`/moderations`).pipe(
|
|
4006
4061
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4007
4062
|
Effect.flatMap((request) =>
|
|
4008
|
-
Effect.flatMap(
|
|
4009
|
-
|
|
4010
|
-
|
|
4011
|
-
|
|
4012
|
-
|
|
4013
|
-
|
|
4014
|
-
|
|
4063
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4064
|
+
Effect.flatMap(
|
|
4065
|
+
httpClient.execute(request),
|
|
4066
|
+
HttpClientResponse.matchStatus({
|
|
4067
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(CreateModerationResponse)(r),
|
|
4068
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4069
|
+
})
|
|
4070
|
+
))
|
|
4015
4071
|
),
|
|
4016
4072
|
Effect.scoped
|
|
4017
4073
|
),
|
|
@@ -4024,13 +4080,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4024
4080
|
}),
|
|
4025
4081
|
Effect.succeed,
|
|
4026
4082
|
Effect.flatMap((request) =>
|
|
4027
|
-
Effect.flatMap(
|
|
4028
|
-
|
|
4029
|
-
|
|
4030
|
-
|
|
4031
|
-
|
|
4032
|
-
|
|
4033
|
-
|
|
4083
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4084
|
+
Effect.flatMap(
|
|
4085
|
+
httpClient.execute(request),
|
|
4086
|
+
HttpClientResponse.matchStatus({
|
|
4087
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ApiKeyList)(r),
|
|
4088
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4089
|
+
})
|
|
4090
|
+
))
|
|
4034
4091
|
),
|
|
4035
4092
|
Effect.scoped
|
|
4036
4093
|
),
|
|
@@ -4038,13 +4095,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4038
4095
|
HttpClientRequest.make("POST")(`/organization/admin_api_keys`).pipe(
|
|
4039
4096
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4040
4097
|
Effect.flatMap((request) =>
|
|
4041
|
-
Effect.flatMap(
|
|
4042
|
-
|
|
4043
|
-
|
|
4044
|
-
|
|
4045
|
-
|
|
4046
|
-
|
|
4047
|
-
|
|
4098
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4099
|
+
Effect.flatMap(
|
|
4100
|
+
httpClient.execute(request),
|
|
4101
|
+
HttpClientResponse.matchStatus({
|
|
4102
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(AdminApiKey)(r),
|
|
4103
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4104
|
+
})
|
|
4105
|
+
))
|
|
4048
4106
|
),
|
|
4049
4107
|
Effect.scoped
|
|
4050
4108
|
),
|
|
@@ -4052,13 +4110,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4052
4110
|
HttpClientRequest.make("GET")(`/organization/admin_api_keys/${keyId}`).pipe(
|
|
4053
4111
|
Effect.succeed,
|
|
4054
4112
|
Effect.flatMap((request) =>
|
|
4055
|
-
Effect.flatMap(
|
|
4056
|
-
|
|
4057
|
-
|
|
4058
|
-
|
|
4059
|
-
|
|
4060
|
-
|
|
4061
|
-
|
|
4113
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4114
|
+
Effect.flatMap(
|
|
4115
|
+
httpClient.execute(request),
|
|
4116
|
+
HttpClientResponse.matchStatus({
|
|
4117
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(AdminApiKey)(r),
|
|
4118
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4119
|
+
})
|
|
4120
|
+
))
|
|
4062
4121
|
),
|
|
4063
4122
|
Effect.scoped
|
|
4064
4123
|
),
|
|
@@ -4066,13 +4125,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4066
4125
|
HttpClientRequest.make("DELETE")(`/organization/admin_api_keys/${keyId}`).pipe(
|
|
4067
4126
|
Effect.succeed,
|
|
4068
4127
|
Effect.flatMap((request) =>
|
|
4069
|
-
Effect.flatMap(
|
|
4070
|
-
|
|
4071
|
-
|
|
4072
|
-
|
|
4073
|
-
|
|
4074
|
-
|
|
4075
|
-
|
|
4128
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4129
|
+
Effect.flatMap(
|
|
4130
|
+
httpClient.execute(request),
|
|
4131
|
+
HttpClientResponse.matchStatus({
|
|
4132
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(AdminApiKeysDelete200)(r),
|
|
4133
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4134
|
+
})
|
|
4135
|
+
))
|
|
4076
4136
|
),
|
|
4077
4137
|
Effect.scoped
|
|
4078
4138
|
),
|
|
@@ -4094,13 +4154,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4094
4154
|
}),
|
|
4095
4155
|
Effect.succeed,
|
|
4096
4156
|
Effect.flatMap((request) =>
|
|
4097
|
-
Effect.flatMap(
|
|
4098
|
-
|
|
4099
|
-
|
|
4100
|
-
|
|
4101
|
-
|
|
4102
|
-
|
|
4103
|
-
|
|
4157
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4158
|
+
Effect.flatMap(
|
|
4159
|
+
httpClient.execute(request),
|
|
4160
|
+
HttpClientResponse.matchStatus({
|
|
4161
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListAuditLogsResponse)(r),
|
|
4162
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4163
|
+
})
|
|
4164
|
+
))
|
|
4104
4165
|
),
|
|
4105
4166
|
Effect.scoped
|
|
4106
4167
|
),
|
|
@@ -4117,13 +4178,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4117
4178
|
}),
|
|
4118
4179
|
Effect.succeed,
|
|
4119
4180
|
Effect.flatMap((request) =>
|
|
4120
|
-
Effect.flatMap(
|
|
4121
|
-
|
|
4122
|
-
|
|
4123
|
-
|
|
4124
|
-
|
|
4125
|
-
|
|
4126
|
-
|
|
4181
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4182
|
+
Effect.flatMap(
|
|
4183
|
+
httpClient.execute(request),
|
|
4184
|
+
HttpClientResponse.matchStatus({
|
|
4185
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4186
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4187
|
+
})
|
|
4188
|
+
))
|
|
4127
4189
|
),
|
|
4128
4190
|
Effect.scoped
|
|
4129
4191
|
),
|
|
@@ -4132,13 +4194,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4132
4194
|
HttpClientRequest.setUrlParams({ "limit": options["limit"], "after": options["after"] }),
|
|
4133
4195
|
Effect.succeed,
|
|
4134
4196
|
Effect.flatMap((request) =>
|
|
4135
|
-
Effect.flatMap(
|
|
4136
|
-
|
|
4137
|
-
|
|
4138
|
-
|
|
4139
|
-
|
|
4140
|
-
|
|
4141
|
-
|
|
4197
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4198
|
+
Effect.flatMap(
|
|
4199
|
+
httpClient.execute(request),
|
|
4200
|
+
HttpClientResponse.matchStatus({
|
|
4201
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(InviteListResponse)(r),
|
|
4202
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4203
|
+
})
|
|
4204
|
+
))
|
|
4142
4205
|
),
|
|
4143
4206
|
Effect.scoped
|
|
4144
4207
|
),
|
|
@@ -4146,13 +4209,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4146
4209
|
HttpClientRequest.make("POST")(`/organization/invites`).pipe(
|
|
4147
4210
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4148
4211
|
Effect.flatMap((request) =>
|
|
4149
|
-
Effect.flatMap(
|
|
4150
|
-
|
|
4151
|
-
|
|
4152
|
-
|
|
4153
|
-
|
|
4154
|
-
|
|
4155
|
-
|
|
4212
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4213
|
+
Effect.flatMap(
|
|
4214
|
+
httpClient.execute(request),
|
|
4215
|
+
HttpClientResponse.matchStatus({
|
|
4216
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Invite)(r),
|
|
4217
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4218
|
+
})
|
|
4219
|
+
))
|
|
4156
4220
|
),
|
|
4157
4221
|
Effect.scoped
|
|
4158
4222
|
),
|
|
@@ -4160,13 +4224,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4160
4224
|
HttpClientRequest.make("GET")(`/organization/invites/${inviteId}`).pipe(
|
|
4161
4225
|
Effect.succeed,
|
|
4162
4226
|
Effect.flatMap((request) =>
|
|
4163
|
-
Effect.flatMap(
|
|
4164
|
-
|
|
4165
|
-
|
|
4166
|
-
|
|
4167
|
-
|
|
4168
|
-
|
|
4169
|
-
|
|
4227
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4228
|
+
Effect.flatMap(
|
|
4229
|
+
httpClient.execute(request),
|
|
4230
|
+
HttpClientResponse.matchStatus({
|
|
4231
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Invite)(r),
|
|
4232
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4233
|
+
})
|
|
4234
|
+
))
|
|
4170
4235
|
),
|
|
4171
4236
|
Effect.scoped
|
|
4172
4237
|
),
|
|
@@ -4174,13 +4239,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4174
4239
|
HttpClientRequest.make("DELETE")(`/organization/invites/${inviteId}`).pipe(
|
|
4175
4240
|
Effect.succeed,
|
|
4176
4241
|
Effect.flatMap((request) =>
|
|
4177
|
-
Effect.flatMap(
|
|
4178
|
-
|
|
4179
|
-
|
|
4180
|
-
|
|
4181
|
-
|
|
4182
|
-
|
|
4183
|
-
|
|
4242
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4243
|
+
Effect.flatMap(
|
|
4244
|
+
httpClient.execute(request),
|
|
4245
|
+
HttpClientResponse.matchStatus({
|
|
4246
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(InviteDeleteResponse)(r),
|
|
4247
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4248
|
+
})
|
|
4249
|
+
))
|
|
4184
4250
|
),
|
|
4185
4251
|
Effect.scoped
|
|
4186
4252
|
),
|
|
@@ -4193,13 +4259,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4193
4259
|
}),
|
|
4194
4260
|
Effect.succeed,
|
|
4195
4261
|
Effect.flatMap((request) =>
|
|
4196
|
-
Effect.flatMap(
|
|
4197
|
-
|
|
4198
|
-
|
|
4199
|
-
|
|
4200
|
-
|
|
4201
|
-
|
|
4202
|
-
|
|
4262
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4263
|
+
Effect.flatMap(
|
|
4264
|
+
httpClient.execute(request),
|
|
4265
|
+
HttpClientResponse.matchStatus({
|
|
4266
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectListResponse)(r),
|
|
4267
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4268
|
+
})
|
|
4269
|
+
))
|
|
4203
4270
|
),
|
|
4204
4271
|
Effect.scoped
|
|
4205
4272
|
),
|
|
@@ -4207,13 +4274,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4207
4274
|
HttpClientRequest.make("POST")(`/organization/projects`).pipe(
|
|
4208
4275
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4209
4276
|
Effect.flatMap((request) =>
|
|
4210
|
-
Effect.flatMap(
|
|
4211
|
-
|
|
4212
|
-
|
|
4213
|
-
|
|
4214
|
-
|
|
4215
|
-
|
|
4216
|
-
|
|
4277
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4278
|
+
Effect.flatMap(
|
|
4279
|
+
httpClient.execute(request),
|
|
4280
|
+
HttpClientResponse.matchStatus({
|
|
4281
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Project)(r),
|
|
4282
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4283
|
+
})
|
|
4284
|
+
))
|
|
4217
4285
|
),
|
|
4218
4286
|
Effect.scoped
|
|
4219
4287
|
),
|
|
@@ -4221,13 +4289,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4221
4289
|
HttpClientRequest.make("GET")(`/organization/projects/${projectId}`).pipe(
|
|
4222
4290
|
Effect.succeed,
|
|
4223
4291
|
Effect.flatMap((request) =>
|
|
4224
|
-
Effect.flatMap(
|
|
4225
|
-
|
|
4226
|
-
|
|
4227
|
-
|
|
4228
|
-
|
|
4229
|
-
|
|
4230
|
-
|
|
4292
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4293
|
+
Effect.flatMap(
|
|
4294
|
+
httpClient.execute(request),
|
|
4295
|
+
HttpClientResponse.matchStatus({
|
|
4296
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Project)(r),
|
|
4297
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4298
|
+
})
|
|
4299
|
+
))
|
|
4231
4300
|
),
|
|
4232
4301
|
Effect.scoped
|
|
4233
4302
|
),
|
|
@@ -4235,14 +4304,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4235
4304
|
HttpClientRequest.make("POST")(`/organization/projects/${projectId}`).pipe(
|
|
4236
4305
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4237
4306
|
Effect.flatMap((request) =>
|
|
4238
|
-
Effect.flatMap(
|
|
4239
|
-
|
|
4240
|
-
|
|
4241
|
-
|
|
4242
|
-
|
|
4243
|
-
|
|
4244
|
-
|
|
4245
|
-
|
|
4307
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4308
|
+
Effect.flatMap(
|
|
4309
|
+
httpClient.execute(request),
|
|
4310
|
+
HttpClientResponse.matchStatus({
|
|
4311
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Project)(r),
|
|
4312
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4313
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4314
|
+
})
|
|
4315
|
+
))
|
|
4246
4316
|
),
|
|
4247
4317
|
Effect.scoped
|
|
4248
4318
|
),
|
|
@@ -4252,11 +4322,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4252
4322
|
Effect.succeed,
|
|
4253
4323
|
Effect.flatMap((request) =>
|
|
4254
4324
|
Effect.flatMap(
|
|
4255
|
-
httpClient
|
|
4256
|
-
|
|
4257
|
-
|
|
4258
|
-
|
|
4259
|
-
|
|
4325
|
+
applyClientTransform(httpClient),
|
|
4326
|
+
(httpClient) =>
|
|
4327
|
+
Effect.flatMap(
|
|
4328
|
+
httpClient.execute(request),
|
|
4329
|
+
HttpClientResponse.matchStatus({
|
|
4330
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectApiKeyListResponse)(r),
|
|
4331
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4332
|
+
})
|
|
4333
|
+
)
|
|
4260
4334
|
)
|
|
4261
4335
|
),
|
|
4262
4336
|
Effect.scoped
|
|
@@ -4266,11 +4340,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4266
4340
|
Effect.succeed,
|
|
4267
4341
|
Effect.flatMap((request) =>
|
|
4268
4342
|
Effect.flatMap(
|
|
4269
|
-
httpClient
|
|
4270
|
-
|
|
4271
|
-
|
|
4272
|
-
|
|
4273
|
-
|
|
4343
|
+
applyClientTransform(httpClient),
|
|
4344
|
+
(httpClient) =>
|
|
4345
|
+
Effect.flatMap(
|
|
4346
|
+
httpClient.execute(request),
|
|
4347
|
+
HttpClientResponse.matchStatus({
|
|
4348
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectApiKey)(r),
|
|
4349
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4350
|
+
})
|
|
4351
|
+
)
|
|
4274
4352
|
)
|
|
4275
4353
|
),
|
|
4276
4354
|
Effect.scoped
|
|
@@ -4280,12 +4358,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4280
4358
|
Effect.succeed,
|
|
4281
4359
|
Effect.flatMap((request) =>
|
|
4282
4360
|
Effect.flatMap(
|
|
4283
|
-
httpClient
|
|
4284
|
-
|
|
4285
|
-
|
|
4286
|
-
|
|
4287
|
-
|
|
4288
|
-
|
|
4361
|
+
applyClientTransform(httpClient),
|
|
4362
|
+
(httpClient) =>
|
|
4363
|
+
Effect.flatMap(
|
|
4364
|
+
httpClient.execute(request),
|
|
4365
|
+
HttpClientResponse.matchStatus({
|
|
4366
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectApiKeyDeleteResponse)(r),
|
|
4367
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4368
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4369
|
+
})
|
|
4370
|
+
)
|
|
4289
4371
|
)
|
|
4290
4372
|
),
|
|
4291
4373
|
Effect.scoped
|
|
@@ -4294,13 +4376,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4294
4376
|
HttpClientRequest.make("POST")(`/organization/projects/${projectId}/archive`).pipe(
|
|
4295
4377
|
Effect.succeed,
|
|
4296
4378
|
Effect.flatMap((request) =>
|
|
4297
|
-
Effect.flatMap(
|
|
4298
|
-
|
|
4299
|
-
|
|
4300
|
-
|
|
4301
|
-
|
|
4302
|
-
|
|
4303
|
-
|
|
4379
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4380
|
+
Effect.flatMap(
|
|
4381
|
+
httpClient.execute(request),
|
|
4382
|
+
HttpClientResponse.matchStatus({
|
|
4383
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Project)(r),
|
|
4384
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4385
|
+
})
|
|
4386
|
+
))
|
|
4304
4387
|
),
|
|
4305
4388
|
Effect.scoped
|
|
4306
4389
|
),
|
|
@@ -4314,11 +4397,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4314
4397
|
Effect.succeed,
|
|
4315
4398
|
Effect.flatMap((request) =>
|
|
4316
4399
|
Effect.flatMap(
|
|
4317
|
-
httpClient
|
|
4318
|
-
|
|
4319
|
-
|
|
4320
|
-
|
|
4321
|
-
|
|
4400
|
+
applyClientTransform(httpClient),
|
|
4401
|
+
(httpClient) =>
|
|
4402
|
+
Effect.flatMap(
|
|
4403
|
+
httpClient.execute(request),
|
|
4404
|
+
HttpClientResponse.matchStatus({
|
|
4405
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectRateLimitListResponse)(r),
|
|
4406
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4407
|
+
})
|
|
4408
|
+
)
|
|
4322
4409
|
)
|
|
4323
4410
|
),
|
|
4324
4411
|
Effect.scoped
|
|
@@ -4328,12 +4415,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4328
4415
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4329
4416
|
Effect.flatMap((request) =>
|
|
4330
4417
|
Effect.flatMap(
|
|
4331
|
-
httpClient
|
|
4332
|
-
|
|
4333
|
-
|
|
4334
|
-
|
|
4335
|
-
|
|
4336
|
-
|
|
4418
|
+
applyClientTransform(httpClient),
|
|
4419
|
+
(httpClient) =>
|
|
4420
|
+
Effect.flatMap(
|
|
4421
|
+
httpClient.execute(request),
|
|
4422
|
+
HttpClientResponse.matchStatus({
|
|
4423
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectRateLimit)(r),
|
|
4424
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4425
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4426
|
+
})
|
|
4427
|
+
)
|
|
4337
4428
|
)
|
|
4338
4429
|
),
|
|
4339
4430
|
Effect.scoped
|
|
@@ -4344,12 +4435,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4344
4435
|
Effect.succeed,
|
|
4345
4436
|
Effect.flatMap((request) =>
|
|
4346
4437
|
Effect.flatMap(
|
|
4347
|
-
httpClient
|
|
4348
|
-
|
|
4349
|
-
|
|
4350
|
-
|
|
4351
|
-
|
|
4352
|
-
|
|
4438
|
+
applyClientTransform(httpClient),
|
|
4439
|
+
(httpClient) =>
|
|
4440
|
+
Effect.flatMap(
|
|
4441
|
+
httpClient.execute(request),
|
|
4442
|
+
HttpClientResponse.matchStatus({
|
|
4443
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectServiceAccountListResponse)(r),
|
|
4444
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4445
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4446
|
+
})
|
|
4447
|
+
)
|
|
4353
4448
|
)
|
|
4354
4449
|
),
|
|
4355
4450
|
Effect.scoped
|
|
@@ -4359,12 +4454,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4359
4454
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4360
4455
|
Effect.flatMap((request) =>
|
|
4361
4456
|
Effect.flatMap(
|
|
4362
|
-
httpClient
|
|
4363
|
-
|
|
4364
|
-
|
|
4365
|
-
|
|
4366
|
-
|
|
4367
|
-
|
|
4457
|
+
applyClientTransform(httpClient),
|
|
4458
|
+
(httpClient) =>
|
|
4459
|
+
Effect.flatMap(
|
|
4460
|
+
httpClient.execute(request),
|
|
4461
|
+
HttpClientResponse.matchStatus({
|
|
4462
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectServiceAccountCreateResponse)(r),
|
|
4463
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4464
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4465
|
+
})
|
|
4466
|
+
)
|
|
4368
4467
|
)
|
|
4369
4468
|
),
|
|
4370
4469
|
Effect.scoped
|
|
@@ -4374,11 +4473,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4374
4473
|
Effect.succeed,
|
|
4375
4474
|
Effect.flatMap((request) =>
|
|
4376
4475
|
Effect.flatMap(
|
|
4377
|
-
httpClient
|
|
4378
|
-
|
|
4379
|
-
|
|
4380
|
-
|
|
4381
|
-
|
|
4476
|
+
applyClientTransform(httpClient),
|
|
4477
|
+
(httpClient) =>
|
|
4478
|
+
Effect.flatMap(
|
|
4479
|
+
httpClient.execute(request),
|
|
4480
|
+
HttpClientResponse.matchStatus({
|
|
4481
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectServiceAccount)(r),
|
|
4482
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4483
|
+
})
|
|
4484
|
+
)
|
|
4382
4485
|
)
|
|
4383
4486
|
),
|
|
4384
4487
|
Effect.scoped
|
|
@@ -4388,11 +4491,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4388
4491
|
Effect.succeed,
|
|
4389
4492
|
Effect.flatMap((request) =>
|
|
4390
4493
|
Effect.flatMap(
|
|
4391
|
-
httpClient
|
|
4392
|
-
|
|
4393
|
-
|
|
4394
|
-
|
|
4395
|
-
|
|
4494
|
+
applyClientTransform(httpClient),
|
|
4495
|
+
(httpClient) =>
|
|
4496
|
+
Effect.flatMap(
|
|
4497
|
+
httpClient.execute(request),
|
|
4498
|
+
HttpClientResponse.matchStatus({
|
|
4499
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectServiceAccountDeleteResponse)(r),
|
|
4500
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4501
|
+
})
|
|
4502
|
+
)
|
|
4396
4503
|
)
|
|
4397
4504
|
),
|
|
4398
4505
|
Effect.scoped
|
|
@@ -4403,12 +4510,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4403
4510
|
Effect.succeed,
|
|
4404
4511
|
Effect.flatMap((request) =>
|
|
4405
4512
|
Effect.flatMap(
|
|
4406
|
-
httpClient
|
|
4407
|
-
|
|
4408
|
-
|
|
4409
|
-
|
|
4410
|
-
|
|
4411
|
-
|
|
4513
|
+
applyClientTransform(httpClient),
|
|
4514
|
+
(httpClient) =>
|
|
4515
|
+
Effect.flatMap(
|
|
4516
|
+
httpClient.execute(request),
|
|
4517
|
+
HttpClientResponse.matchStatus({
|
|
4518
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectUserListResponse)(r),
|
|
4519
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4520
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4521
|
+
})
|
|
4522
|
+
)
|
|
4412
4523
|
)
|
|
4413
4524
|
),
|
|
4414
4525
|
Effect.scoped
|
|
@@ -4418,12 +4529,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4418
4529
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4419
4530
|
Effect.flatMap((request) =>
|
|
4420
4531
|
Effect.flatMap(
|
|
4421
|
-
httpClient
|
|
4422
|
-
|
|
4423
|
-
|
|
4424
|
-
|
|
4425
|
-
|
|
4426
|
-
|
|
4532
|
+
applyClientTransform(httpClient),
|
|
4533
|
+
(httpClient) =>
|
|
4534
|
+
Effect.flatMap(
|
|
4535
|
+
httpClient.execute(request),
|
|
4536
|
+
HttpClientResponse.matchStatus({
|
|
4537
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectUser)(r),
|
|
4538
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4539
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4540
|
+
})
|
|
4541
|
+
)
|
|
4427
4542
|
)
|
|
4428
4543
|
),
|
|
4429
4544
|
Effect.scoped
|
|
@@ -4433,11 +4548,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4433
4548
|
Effect.succeed,
|
|
4434
4549
|
Effect.flatMap((request) =>
|
|
4435
4550
|
Effect.flatMap(
|
|
4436
|
-
httpClient
|
|
4437
|
-
|
|
4438
|
-
|
|
4439
|
-
|
|
4440
|
-
|
|
4551
|
+
applyClientTransform(httpClient),
|
|
4552
|
+
(httpClient) =>
|
|
4553
|
+
Effect.flatMap(
|
|
4554
|
+
httpClient.execute(request),
|
|
4555
|
+
HttpClientResponse.matchStatus({
|
|
4556
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectUser)(r),
|
|
4557
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4558
|
+
})
|
|
4559
|
+
)
|
|
4441
4560
|
)
|
|
4442
4561
|
),
|
|
4443
4562
|
Effect.scoped
|
|
@@ -4447,12 +4566,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4447
4566
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4448
4567
|
Effect.flatMap((request) =>
|
|
4449
4568
|
Effect.flatMap(
|
|
4450
|
-
httpClient
|
|
4451
|
-
|
|
4452
|
-
|
|
4453
|
-
|
|
4454
|
-
|
|
4455
|
-
|
|
4569
|
+
applyClientTransform(httpClient),
|
|
4570
|
+
(httpClient) =>
|
|
4571
|
+
Effect.flatMap(
|
|
4572
|
+
httpClient.execute(request),
|
|
4573
|
+
HttpClientResponse.matchStatus({
|
|
4574
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectUser)(r),
|
|
4575
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4576
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4577
|
+
})
|
|
4578
|
+
)
|
|
4456
4579
|
)
|
|
4457
4580
|
),
|
|
4458
4581
|
Effect.scoped
|
|
@@ -4462,12 +4585,16 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4462
4585
|
Effect.succeed,
|
|
4463
4586
|
Effect.flatMap((request) =>
|
|
4464
4587
|
Effect.flatMap(
|
|
4465
|
-
httpClient
|
|
4466
|
-
|
|
4467
|
-
|
|
4468
|
-
|
|
4469
|
-
|
|
4470
|
-
|
|
4588
|
+
applyClientTransform(httpClient),
|
|
4589
|
+
(httpClient) =>
|
|
4590
|
+
Effect.flatMap(
|
|
4591
|
+
httpClient.execute(request),
|
|
4592
|
+
HttpClientResponse.matchStatus({
|
|
4593
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ProjectUserDeleteResponse)(r),
|
|
4594
|
+
"400": (r) => decodeError(r, ErrorResponse),
|
|
4595
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4596
|
+
})
|
|
4597
|
+
)
|
|
4471
4598
|
)
|
|
4472
4599
|
),
|
|
4473
4600
|
Effect.scoped
|
|
@@ -4488,13 +4615,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4488
4615
|
}),
|
|
4489
4616
|
Effect.succeed,
|
|
4490
4617
|
Effect.flatMap((request) =>
|
|
4491
|
-
Effect.flatMap(
|
|
4492
|
-
|
|
4493
|
-
|
|
4494
|
-
|
|
4495
|
-
|
|
4496
|
-
|
|
4497
|
-
|
|
4618
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4619
|
+
Effect.flatMap(
|
|
4620
|
+
httpClient.execute(request),
|
|
4621
|
+
HttpClientResponse.matchStatus({
|
|
4622
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4623
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4624
|
+
})
|
|
4625
|
+
))
|
|
4498
4626
|
),
|
|
4499
4627
|
Effect.scoped
|
|
4500
4628
|
),
|
|
@@ -4515,11 +4643,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4515
4643
|
Effect.succeed,
|
|
4516
4644
|
Effect.flatMap((request) =>
|
|
4517
4645
|
Effect.flatMap(
|
|
4518
|
-
httpClient
|
|
4519
|
-
|
|
4520
|
-
|
|
4521
|
-
|
|
4522
|
-
|
|
4646
|
+
applyClientTransform(httpClient),
|
|
4647
|
+
(httpClient) =>
|
|
4648
|
+
Effect.flatMap(
|
|
4649
|
+
httpClient.execute(request),
|
|
4650
|
+
HttpClientResponse.matchStatus({
|
|
4651
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4652
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4653
|
+
})
|
|
4654
|
+
)
|
|
4523
4655
|
)
|
|
4524
4656
|
),
|
|
4525
4657
|
Effect.scoped
|
|
@@ -4538,11 +4670,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4538
4670
|
Effect.succeed,
|
|
4539
4671
|
Effect.flatMap((request) =>
|
|
4540
4672
|
Effect.flatMap(
|
|
4541
|
-
httpClient
|
|
4542
|
-
|
|
4543
|
-
|
|
4544
|
-
|
|
4545
|
-
|
|
4673
|
+
applyClientTransform(httpClient),
|
|
4674
|
+
(httpClient) =>
|
|
4675
|
+
Effect.flatMap(
|
|
4676
|
+
httpClient.execute(request),
|
|
4677
|
+
HttpClientResponse.matchStatus({
|
|
4678
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4679
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4680
|
+
})
|
|
4681
|
+
)
|
|
4546
4682
|
)
|
|
4547
4683
|
),
|
|
4548
4684
|
Effect.scoped
|
|
@@ -4564,13 +4700,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4564
4700
|
}),
|
|
4565
4701
|
Effect.succeed,
|
|
4566
4702
|
Effect.flatMap((request) =>
|
|
4567
|
-
Effect.flatMap(
|
|
4568
|
-
|
|
4569
|
-
|
|
4570
|
-
|
|
4571
|
-
|
|
4572
|
-
|
|
4573
|
-
|
|
4703
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4704
|
+
Effect.flatMap(
|
|
4705
|
+
httpClient.execute(request),
|
|
4706
|
+
HttpClientResponse.matchStatus({
|
|
4707
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4708
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4709
|
+
})
|
|
4710
|
+
))
|
|
4574
4711
|
),
|
|
4575
4712
|
Effect.scoped
|
|
4576
4713
|
),
|
|
@@ -4590,13 +4727,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4590
4727
|
}),
|
|
4591
4728
|
Effect.succeed,
|
|
4592
4729
|
Effect.flatMap((request) =>
|
|
4593
|
-
Effect.flatMap(
|
|
4594
|
-
|
|
4595
|
-
|
|
4596
|
-
|
|
4597
|
-
|
|
4598
|
-
|
|
4599
|
-
|
|
4730
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4731
|
+
Effect.flatMap(
|
|
4732
|
+
httpClient.execute(request),
|
|
4733
|
+
HttpClientResponse.matchStatus({
|
|
4734
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4735
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4736
|
+
})
|
|
4737
|
+
))
|
|
4600
4738
|
),
|
|
4601
4739
|
Effect.scoped
|
|
4602
4740
|
),
|
|
@@ -4618,13 +4756,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4618
4756
|
}),
|
|
4619
4757
|
Effect.succeed,
|
|
4620
4758
|
Effect.flatMap((request) =>
|
|
4621
|
-
Effect.flatMap(
|
|
4622
|
-
|
|
4623
|
-
|
|
4624
|
-
|
|
4625
|
-
|
|
4626
|
-
|
|
4627
|
-
|
|
4759
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4760
|
+
Effect.flatMap(
|
|
4761
|
+
httpClient.execute(request),
|
|
4762
|
+
HttpClientResponse.matchStatus({
|
|
4763
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4764
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4765
|
+
})
|
|
4766
|
+
))
|
|
4628
4767
|
),
|
|
4629
4768
|
Effect.scoped
|
|
4630
4769
|
),
|
|
@@ -4644,13 +4783,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4644
4783
|
}),
|
|
4645
4784
|
Effect.succeed,
|
|
4646
4785
|
Effect.flatMap((request) =>
|
|
4647
|
-
Effect.flatMap(
|
|
4648
|
-
|
|
4649
|
-
|
|
4650
|
-
|
|
4651
|
-
|
|
4652
|
-
|
|
4653
|
-
|
|
4786
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4787
|
+
Effect.flatMap(
|
|
4788
|
+
httpClient.execute(request),
|
|
4789
|
+
HttpClientResponse.matchStatus({
|
|
4790
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4791
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4792
|
+
})
|
|
4793
|
+
))
|
|
4654
4794
|
),
|
|
4655
4795
|
Effect.scoped
|
|
4656
4796
|
),
|
|
@@ -4667,28 +4807,34 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4667
4807
|
}),
|
|
4668
4808
|
Effect.succeed,
|
|
4669
4809
|
Effect.flatMap((request) =>
|
|
4670
|
-
Effect.flatMap(
|
|
4671
|
-
|
|
4672
|
-
|
|
4673
|
-
|
|
4674
|
-
|
|
4675
|
-
|
|
4676
|
-
|
|
4810
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4811
|
+
Effect.flatMap(
|
|
4812
|
+
httpClient.execute(request),
|
|
4813
|
+
HttpClientResponse.matchStatus({
|
|
4814
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UsageResponse)(r),
|
|
4815
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4816
|
+
})
|
|
4817
|
+
))
|
|
4677
4818
|
),
|
|
4678
4819
|
Effect.scoped
|
|
4679
4820
|
),
|
|
4680
4821
|
"listUsers": (options) =>
|
|
4681
4822
|
HttpClientRequest.make("GET")(`/organization/users`).pipe(
|
|
4682
|
-
HttpClientRequest.setUrlParams({
|
|
4823
|
+
HttpClientRequest.setUrlParams({
|
|
4824
|
+
"limit": options["limit"],
|
|
4825
|
+
"after": options["after"],
|
|
4826
|
+
"emails": options["emails"]
|
|
4827
|
+
}),
|
|
4683
4828
|
Effect.succeed,
|
|
4684
4829
|
Effect.flatMap((request) =>
|
|
4685
|
-
Effect.flatMap(
|
|
4686
|
-
|
|
4687
|
-
|
|
4688
|
-
|
|
4689
|
-
|
|
4690
|
-
|
|
4691
|
-
|
|
4830
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4831
|
+
Effect.flatMap(
|
|
4832
|
+
httpClient.execute(request),
|
|
4833
|
+
HttpClientResponse.matchStatus({
|
|
4834
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UserListResponse)(r),
|
|
4835
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4836
|
+
})
|
|
4837
|
+
))
|
|
4692
4838
|
),
|
|
4693
4839
|
Effect.scoped
|
|
4694
4840
|
),
|
|
@@ -4696,13 +4842,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4696
4842
|
HttpClientRequest.make("GET")(`/organization/users/${userId}`).pipe(
|
|
4697
4843
|
Effect.succeed,
|
|
4698
4844
|
Effect.flatMap((request) =>
|
|
4699
|
-
Effect.flatMap(
|
|
4700
|
-
|
|
4701
|
-
|
|
4702
|
-
|
|
4703
|
-
|
|
4704
|
-
|
|
4705
|
-
|
|
4845
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4846
|
+
Effect.flatMap(
|
|
4847
|
+
httpClient.execute(request),
|
|
4848
|
+
HttpClientResponse.matchStatus({
|
|
4849
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(User)(r),
|
|
4850
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4851
|
+
})
|
|
4852
|
+
))
|
|
4706
4853
|
),
|
|
4707
4854
|
Effect.scoped
|
|
4708
4855
|
),
|
|
@@ -4710,13 +4857,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4710
4857
|
HttpClientRequest.make("POST")(`/organization/users/${userId}`).pipe(
|
|
4711
4858
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4712
4859
|
Effect.flatMap((request) =>
|
|
4713
|
-
Effect.flatMap(
|
|
4714
|
-
|
|
4715
|
-
|
|
4716
|
-
|
|
4717
|
-
|
|
4718
|
-
|
|
4719
|
-
|
|
4860
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4861
|
+
Effect.flatMap(
|
|
4862
|
+
httpClient.execute(request),
|
|
4863
|
+
HttpClientResponse.matchStatus({
|
|
4864
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(User)(r),
|
|
4865
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4866
|
+
})
|
|
4867
|
+
))
|
|
4720
4868
|
),
|
|
4721
4869
|
Effect.scoped
|
|
4722
4870
|
),
|
|
@@ -4724,13 +4872,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4724
4872
|
HttpClientRequest.make("DELETE")(`/organization/users/${userId}`).pipe(
|
|
4725
4873
|
Effect.succeed,
|
|
4726
4874
|
Effect.flatMap((request) =>
|
|
4727
|
-
Effect.flatMap(
|
|
4728
|
-
|
|
4729
|
-
|
|
4730
|
-
|
|
4731
|
-
|
|
4732
|
-
|
|
4733
|
-
|
|
4875
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4876
|
+
Effect.flatMap(
|
|
4877
|
+
httpClient.execute(request),
|
|
4878
|
+
HttpClientResponse.matchStatus({
|
|
4879
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UserDeleteResponse)(r),
|
|
4880
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4881
|
+
})
|
|
4882
|
+
))
|
|
4734
4883
|
),
|
|
4735
4884
|
Effect.scoped
|
|
4736
4885
|
),
|
|
@@ -4738,13 +4887,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4738
4887
|
HttpClientRequest.make("POST")(`/realtime/sessions`).pipe(
|
|
4739
4888
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4740
4889
|
Effect.flatMap((request) =>
|
|
4741
|
-
Effect.flatMap(
|
|
4742
|
-
|
|
4743
|
-
|
|
4744
|
-
|
|
4745
|
-
|
|
4746
|
-
|
|
4747
|
-
|
|
4890
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4891
|
+
Effect.flatMap(
|
|
4892
|
+
httpClient.execute(request),
|
|
4893
|
+
HttpClientResponse.matchStatus({
|
|
4894
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RealtimeSessionCreateResponse)(r),
|
|
4895
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4896
|
+
})
|
|
4897
|
+
))
|
|
4748
4898
|
),
|
|
4749
4899
|
Effect.scoped
|
|
4750
4900
|
),
|
|
@@ -4752,13 +4902,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4752
4902
|
HttpClientRequest.make("POST")(`/threads`).pipe(
|
|
4753
4903
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4754
4904
|
Effect.flatMap((request) =>
|
|
4755
|
-
Effect.flatMap(
|
|
4756
|
-
|
|
4757
|
-
|
|
4758
|
-
|
|
4759
|
-
|
|
4760
|
-
|
|
4761
|
-
|
|
4905
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4906
|
+
Effect.flatMap(
|
|
4907
|
+
httpClient.execute(request),
|
|
4908
|
+
HttpClientResponse.matchStatus({
|
|
4909
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ThreadObject)(r),
|
|
4910
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4911
|
+
})
|
|
4912
|
+
))
|
|
4762
4913
|
),
|
|
4763
4914
|
Effect.scoped
|
|
4764
4915
|
),
|
|
@@ -4766,13 +4917,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4766
4917
|
HttpClientRequest.make("POST")(`/threads/runs`).pipe(
|
|
4767
4918
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4768
4919
|
Effect.flatMap((request) =>
|
|
4769
|
-
Effect.flatMap(
|
|
4770
|
-
|
|
4771
|
-
|
|
4772
|
-
|
|
4773
|
-
|
|
4774
|
-
|
|
4775
|
-
|
|
4920
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4921
|
+
Effect.flatMap(
|
|
4922
|
+
httpClient.execute(request),
|
|
4923
|
+
HttpClientResponse.matchStatus({
|
|
4924
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunObject)(r),
|
|
4925
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4926
|
+
})
|
|
4927
|
+
))
|
|
4776
4928
|
),
|
|
4777
4929
|
Effect.scoped
|
|
4778
4930
|
),
|
|
@@ -4780,13 +4932,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4780
4932
|
HttpClientRequest.make("GET")(`/threads/${threadId}`).pipe(
|
|
4781
4933
|
Effect.succeed,
|
|
4782
4934
|
Effect.flatMap((request) =>
|
|
4783
|
-
Effect.flatMap(
|
|
4784
|
-
|
|
4785
|
-
|
|
4786
|
-
|
|
4787
|
-
|
|
4788
|
-
|
|
4789
|
-
|
|
4935
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4936
|
+
Effect.flatMap(
|
|
4937
|
+
httpClient.execute(request),
|
|
4938
|
+
HttpClientResponse.matchStatus({
|
|
4939
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ThreadObject)(r),
|
|
4940
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4941
|
+
})
|
|
4942
|
+
))
|
|
4790
4943
|
),
|
|
4791
4944
|
Effect.scoped
|
|
4792
4945
|
),
|
|
@@ -4794,13 +4947,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4794
4947
|
HttpClientRequest.make("POST")(`/threads/${threadId}`).pipe(
|
|
4795
4948
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4796
4949
|
Effect.flatMap((request) =>
|
|
4797
|
-
Effect.flatMap(
|
|
4798
|
-
|
|
4799
|
-
|
|
4800
|
-
|
|
4801
|
-
|
|
4802
|
-
|
|
4803
|
-
|
|
4950
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4951
|
+
Effect.flatMap(
|
|
4952
|
+
httpClient.execute(request),
|
|
4953
|
+
HttpClientResponse.matchStatus({
|
|
4954
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ThreadObject)(r),
|
|
4955
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4956
|
+
})
|
|
4957
|
+
))
|
|
4804
4958
|
),
|
|
4805
4959
|
Effect.scoped
|
|
4806
4960
|
),
|
|
@@ -4808,13 +4962,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4808
4962
|
HttpClientRequest.make("DELETE")(`/threads/${threadId}`).pipe(
|
|
4809
4963
|
Effect.succeed,
|
|
4810
4964
|
Effect.flatMap((request) =>
|
|
4811
|
-
Effect.flatMap(
|
|
4812
|
-
|
|
4813
|
-
|
|
4814
|
-
|
|
4815
|
-
|
|
4816
|
-
|
|
4817
|
-
|
|
4965
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4966
|
+
Effect.flatMap(
|
|
4967
|
+
httpClient.execute(request),
|
|
4968
|
+
HttpClientResponse.matchStatus({
|
|
4969
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteThreadResponse)(r),
|
|
4970
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4971
|
+
})
|
|
4972
|
+
))
|
|
4818
4973
|
),
|
|
4819
4974
|
Effect.scoped
|
|
4820
4975
|
),
|
|
@@ -4829,13 +4984,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4829
4984
|
}),
|
|
4830
4985
|
Effect.succeed,
|
|
4831
4986
|
Effect.flatMap((request) =>
|
|
4832
|
-
Effect.flatMap(
|
|
4833
|
-
|
|
4834
|
-
|
|
4835
|
-
|
|
4836
|
-
|
|
4837
|
-
|
|
4838
|
-
|
|
4987
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
4988
|
+
Effect.flatMap(
|
|
4989
|
+
httpClient.execute(request),
|
|
4990
|
+
HttpClientResponse.matchStatus({
|
|
4991
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListMessagesResponse)(r),
|
|
4992
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
4993
|
+
})
|
|
4994
|
+
))
|
|
4839
4995
|
),
|
|
4840
4996
|
Effect.scoped
|
|
4841
4997
|
),
|
|
@@ -4843,13 +4999,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4843
4999
|
HttpClientRequest.make("POST")(`/threads/${threadId}/messages`).pipe(
|
|
4844
5000
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4845
5001
|
Effect.flatMap((request) =>
|
|
4846
|
-
Effect.flatMap(
|
|
4847
|
-
|
|
4848
|
-
|
|
4849
|
-
|
|
4850
|
-
|
|
4851
|
-
|
|
4852
|
-
|
|
5002
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5003
|
+
Effect.flatMap(
|
|
5004
|
+
httpClient.execute(request),
|
|
5005
|
+
HttpClientResponse.matchStatus({
|
|
5006
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(MessageObject)(r),
|
|
5007
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5008
|
+
})
|
|
5009
|
+
))
|
|
4853
5010
|
),
|
|
4854
5011
|
Effect.scoped
|
|
4855
5012
|
),
|
|
@@ -4858,11 +5015,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4858
5015
|
Effect.succeed,
|
|
4859
5016
|
Effect.flatMap((request) =>
|
|
4860
5017
|
Effect.flatMap(
|
|
4861
|
-
httpClient
|
|
4862
|
-
|
|
4863
|
-
|
|
4864
|
-
|
|
4865
|
-
|
|
5018
|
+
applyClientTransform(httpClient),
|
|
5019
|
+
(httpClient) =>
|
|
5020
|
+
Effect.flatMap(
|
|
5021
|
+
httpClient.execute(request),
|
|
5022
|
+
HttpClientResponse.matchStatus({
|
|
5023
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(MessageObject)(r),
|
|
5024
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5025
|
+
})
|
|
5026
|
+
)
|
|
4866
5027
|
)
|
|
4867
5028
|
),
|
|
4868
5029
|
Effect.scoped
|
|
@@ -4872,11 +5033,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4872
5033
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4873
5034
|
Effect.flatMap((request) =>
|
|
4874
5035
|
Effect.flatMap(
|
|
4875
|
-
httpClient
|
|
4876
|
-
|
|
4877
|
-
|
|
4878
|
-
|
|
4879
|
-
|
|
5036
|
+
applyClientTransform(httpClient),
|
|
5037
|
+
(httpClient) =>
|
|
5038
|
+
Effect.flatMap(
|
|
5039
|
+
httpClient.execute(request),
|
|
5040
|
+
HttpClientResponse.matchStatus({
|
|
5041
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(MessageObject)(r),
|
|
5042
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5043
|
+
})
|
|
5044
|
+
)
|
|
4880
5045
|
)
|
|
4881
5046
|
),
|
|
4882
5047
|
Effect.scoped
|
|
@@ -4886,11 +5051,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4886
5051
|
Effect.succeed,
|
|
4887
5052
|
Effect.flatMap((request) =>
|
|
4888
5053
|
Effect.flatMap(
|
|
4889
|
-
httpClient
|
|
4890
|
-
|
|
4891
|
-
|
|
4892
|
-
|
|
4893
|
-
|
|
5054
|
+
applyClientTransform(httpClient),
|
|
5055
|
+
(httpClient) =>
|
|
5056
|
+
Effect.flatMap(
|
|
5057
|
+
httpClient.execute(request),
|
|
5058
|
+
HttpClientResponse.matchStatus({
|
|
5059
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteMessageResponse)(r),
|
|
5060
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5061
|
+
})
|
|
5062
|
+
)
|
|
4894
5063
|
)
|
|
4895
5064
|
),
|
|
4896
5065
|
Effect.scoped
|
|
@@ -4905,13 +5074,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4905
5074
|
}),
|
|
4906
5075
|
Effect.succeed,
|
|
4907
5076
|
Effect.flatMap((request) =>
|
|
4908
|
-
Effect.flatMap(
|
|
4909
|
-
|
|
4910
|
-
|
|
4911
|
-
|
|
4912
|
-
|
|
4913
|
-
|
|
4914
|
-
|
|
5077
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5078
|
+
Effect.flatMap(
|
|
5079
|
+
httpClient.execute(request),
|
|
5080
|
+
HttpClientResponse.matchStatus({
|
|
5081
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListRunsResponse)(r),
|
|
5082
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5083
|
+
})
|
|
5084
|
+
))
|
|
4915
5085
|
),
|
|
4916
5086
|
Effect.scoped
|
|
4917
5087
|
),
|
|
@@ -4920,13 +5090,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4920
5090
|
HttpClientRequest.setUrlParams({ "include[]": options.params["include[]"] }),
|
|
4921
5091
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options.payload)),
|
|
4922
5092
|
Effect.flatMap((request) =>
|
|
4923
|
-
Effect.flatMap(
|
|
4924
|
-
|
|
4925
|
-
|
|
4926
|
-
|
|
4927
|
-
|
|
4928
|
-
|
|
4929
|
-
|
|
5093
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5094
|
+
Effect.flatMap(
|
|
5095
|
+
httpClient.execute(request),
|
|
5096
|
+
HttpClientResponse.matchStatus({
|
|
5097
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunObject)(r),
|
|
5098
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5099
|
+
})
|
|
5100
|
+
))
|
|
4930
5101
|
),
|
|
4931
5102
|
Effect.scoped
|
|
4932
5103
|
),
|
|
@@ -4934,13 +5105,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4934
5105
|
HttpClientRequest.make("GET")(`/threads/${threadId}/runs/${runId}`).pipe(
|
|
4935
5106
|
Effect.succeed,
|
|
4936
5107
|
Effect.flatMap((request) =>
|
|
4937
|
-
Effect.flatMap(
|
|
4938
|
-
|
|
4939
|
-
|
|
4940
|
-
|
|
4941
|
-
|
|
4942
|
-
|
|
4943
|
-
|
|
5108
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5109
|
+
Effect.flatMap(
|
|
5110
|
+
httpClient.execute(request),
|
|
5111
|
+
HttpClientResponse.matchStatus({
|
|
5112
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunObject)(r),
|
|
5113
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5114
|
+
})
|
|
5115
|
+
))
|
|
4944
5116
|
),
|
|
4945
5117
|
Effect.scoped
|
|
4946
5118
|
),
|
|
@@ -4949,11 +5121,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4949
5121
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
4950
5122
|
Effect.flatMap((request) =>
|
|
4951
5123
|
Effect.flatMap(
|
|
4952
|
-
httpClient
|
|
4953
|
-
|
|
4954
|
-
|
|
4955
|
-
|
|
4956
|
-
|
|
5124
|
+
applyClientTransform(httpClient),
|
|
5125
|
+
(httpClient) =>
|
|
5126
|
+
Effect.flatMap(
|
|
5127
|
+
httpClient.execute(request),
|
|
5128
|
+
HttpClientResponse.matchStatus({
|
|
5129
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunObject)(r),
|
|
5130
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5131
|
+
})
|
|
5132
|
+
)
|
|
4957
5133
|
)
|
|
4958
5134
|
),
|
|
4959
5135
|
Effect.scoped
|
|
@@ -4962,13 +5138,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4962
5138
|
HttpClientRequest.make("POST")(`/threads/${threadId}/runs/${runId}/cancel`).pipe(
|
|
4963
5139
|
Effect.succeed,
|
|
4964
5140
|
Effect.flatMap((request) =>
|
|
4965
|
-
Effect.flatMap(
|
|
4966
|
-
|
|
4967
|
-
|
|
4968
|
-
|
|
4969
|
-
|
|
4970
|
-
|
|
4971
|
-
|
|
5141
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5142
|
+
Effect.flatMap(
|
|
5143
|
+
httpClient.execute(request),
|
|
5144
|
+
HttpClientResponse.matchStatus({
|
|
5145
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunObject)(r),
|
|
5146
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5147
|
+
})
|
|
5148
|
+
))
|
|
4972
5149
|
),
|
|
4973
5150
|
Effect.scoped
|
|
4974
5151
|
),
|
|
@@ -4984,11 +5161,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4984
5161
|
Effect.succeed,
|
|
4985
5162
|
Effect.flatMap((request) =>
|
|
4986
5163
|
Effect.flatMap(
|
|
4987
|
-
httpClient
|
|
4988
|
-
|
|
4989
|
-
|
|
4990
|
-
|
|
4991
|
-
|
|
5164
|
+
applyClientTransform(httpClient),
|
|
5165
|
+
(httpClient) =>
|
|
5166
|
+
Effect.flatMap(
|
|
5167
|
+
httpClient.execute(request),
|
|
5168
|
+
HttpClientResponse.matchStatus({
|
|
5169
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListRunStepsResponse)(r),
|
|
5170
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5171
|
+
})
|
|
5172
|
+
)
|
|
4992
5173
|
)
|
|
4993
5174
|
),
|
|
4994
5175
|
Effect.scoped
|
|
@@ -4999,11 +5180,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
4999
5180
|
Effect.succeed,
|
|
5000
5181
|
Effect.flatMap((request) =>
|
|
5001
5182
|
Effect.flatMap(
|
|
5002
|
-
httpClient
|
|
5003
|
-
|
|
5004
|
-
|
|
5005
|
-
|
|
5006
|
-
|
|
5183
|
+
applyClientTransform(httpClient),
|
|
5184
|
+
(httpClient) =>
|
|
5185
|
+
Effect.flatMap(
|
|
5186
|
+
httpClient.execute(request),
|
|
5187
|
+
HttpClientResponse.matchStatus({
|
|
5188
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunStepObject)(r),
|
|
5189
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5190
|
+
})
|
|
5191
|
+
)
|
|
5007
5192
|
)
|
|
5008
5193
|
),
|
|
5009
5194
|
Effect.scoped
|
|
@@ -5013,11 +5198,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5013
5198
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5014
5199
|
Effect.flatMap((request) =>
|
|
5015
5200
|
Effect.flatMap(
|
|
5016
|
-
httpClient
|
|
5017
|
-
|
|
5018
|
-
|
|
5019
|
-
|
|
5020
|
-
|
|
5201
|
+
applyClientTransform(httpClient),
|
|
5202
|
+
(httpClient) =>
|
|
5203
|
+
Effect.flatMap(
|
|
5204
|
+
httpClient.execute(request),
|
|
5205
|
+
HttpClientResponse.matchStatus({
|
|
5206
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(RunObject)(r),
|
|
5207
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5208
|
+
})
|
|
5209
|
+
)
|
|
5021
5210
|
)
|
|
5022
5211
|
),
|
|
5023
5212
|
Effect.scoped
|
|
@@ -5026,13 +5215,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5026
5215
|
HttpClientRequest.make("POST")(`/uploads`).pipe(
|
|
5027
5216
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5028
5217
|
Effect.flatMap((request) =>
|
|
5029
|
-
Effect.flatMap(
|
|
5030
|
-
|
|
5031
|
-
|
|
5032
|
-
|
|
5033
|
-
|
|
5034
|
-
|
|
5035
|
-
|
|
5218
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5219
|
+
Effect.flatMap(
|
|
5220
|
+
httpClient.execute(request),
|
|
5221
|
+
HttpClientResponse.matchStatus({
|
|
5222
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Upload)(r),
|
|
5223
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5224
|
+
})
|
|
5225
|
+
))
|
|
5036
5226
|
),
|
|
5037
5227
|
Effect.scoped
|
|
5038
5228
|
),
|
|
@@ -5040,13 +5230,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5040
5230
|
HttpClientRequest.make("POST")(`/uploads/${uploadId}/cancel`).pipe(
|
|
5041
5231
|
Effect.succeed,
|
|
5042
5232
|
Effect.flatMap((request) =>
|
|
5043
|
-
Effect.flatMap(
|
|
5044
|
-
|
|
5045
|
-
|
|
5046
|
-
|
|
5047
|
-
|
|
5048
|
-
|
|
5049
|
-
|
|
5233
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5234
|
+
Effect.flatMap(
|
|
5235
|
+
httpClient.execute(request),
|
|
5236
|
+
HttpClientResponse.matchStatus({
|
|
5237
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Upload)(r),
|
|
5238
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5239
|
+
})
|
|
5240
|
+
))
|
|
5050
5241
|
),
|
|
5051
5242
|
Effect.scoped
|
|
5052
5243
|
),
|
|
@@ -5054,13 +5245,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5054
5245
|
HttpClientRequest.make("POST")(`/uploads/${uploadId}/complete`).pipe(
|
|
5055
5246
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5056
5247
|
Effect.flatMap((request) =>
|
|
5057
|
-
Effect.flatMap(
|
|
5058
|
-
|
|
5059
|
-
|
|
5060
|
-
|
|
5061
|
-
|
|
5062
|
-
|
|
5063
|
-
|
|
5248
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5249
|
+
Effect.flatMap(
|
|
5250
|
+
httpClient.execute(request),
|
|
5251
|
+
HttpClientResponse.matchStatus({
|
|
5252
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(Upload)(r),
|
|
5253
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5254
|
+
})
|
|
5255
|
+
))
|
|
5064
5256
|
),
|
|
5065
5257
|
Effect.scoped
|
|
5066
5258
|
),
|
|
@@ -5069,13 +5261,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5069
5261
|
HttpClientRequest.bodyFormData(options),
|
|
5070
5262
|
Effect.succeed,
|
|
5071
5263
|
Effect.flatMap((request) =>
|
|
5072
|
-
Effect.flatMap(
|
|
5073
|
-
|
|
5074
|
-
|
|
5075
|
-
|
|
5076
|
-
|
|
5077
|
-
|
|
5078
|
-
|
|
5264
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5265
|
+
Effect.flatMap(
|
|
5266
|
+
httpClient.execute(request),
|
|
5267
|
+
HttpClientResponse.matchStatus({
|
|
5268
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(UploadPart)(r),
|
|
5269
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5270
|
+
})
|
|
5271
|
+
))
|
|
5079
5272
|
),
|
|
5080
5273
|
Effect.scoped
|
|
5081
5274
|
),
|
|
@@ -5089,13 +5282,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5089
5282
|
}),
|
|
5090
5283
|
Effect.succeed,
|
|
5091
5284
|
Effect.flatMap((request) =>
|
|
5092
|
-
Effect.flatMap(
|
|
5093
|
-
|
|
5094
|
-
|
|
5095
|
-
|
|
5096
|
-
|
|
5097
|
-
|
|
5098
|
-
|
|
5285
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5286
|
+
Effect.flatMap(
|
|
5287
|
+
httpClient.execute(request),
|
|
5288
|
+
HttpClientResponse.matchStatus({
|
|
5289
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListVectorStoresResponse)(r),
|
|
5290
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5291
|
+
})
|
|
5292
|
+
))
|
|
5099
5293
|
),
|
|
5100
5294
|
Effect.scoped
|
|
5101
5295
|
),
|
|
@@ -5103,13 +5297,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5103
5297
|
HttpClientRequest.make("POST")(`/vector_stores`).pipe(
|
|
5104
5298
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5105
5299
|
Effect.flatMap((request) =>
|
|
5106
|
-
Effect.flatMap(
|
|
5107
|
-
|
|
5108
|
-
|
|
5109
|
-
|
|
5110
|
-
|
|
5111
|
-
|
|
5112
|
-
|
|
5300
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5301
|
+
Effect.flatMap(
|
|
5302
|
+
httpClient.execute(request),
|
|
5303
|
+
HttpClientResponse.matchStatus({
|
|
5304
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreObject)(r),
|
|
5305
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5306
|
+
})
|
|
5307
|
+
))
|
|
5113
5308
|
),
|
|
5114
5309
|
Effect.scoped
|
|
5115
5310
|
),
|
|
@@ -5117,13 +5312,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5117
5312
|
HttpClientRequest.make("GET")(`/vector_stores/${vectorStoreId}`).pipe(
|
|
5118
5313
|
Effect.succeed,
|
|
5119
5314
|
Effect.flatMap((request) =>
|
|
5120
|
-
Effect.flatMap(
|
|
5121
|
-
|
|
5122
|
-
|
|
5123
|
-
|
|
5124
|
-
|
|
5125
|
-
|
|
5126
|
-
|
|
5315
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5316
|
+
Effect.flatMap(
|
|
5317
|
+
httpClient.execute(request),
|
|
5318
|
+
HttpClientResponse.matchStatus({
|
|
5319
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreObject)(r),
|
|
5320
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5321
|
+
})
|
|
5322
|
+
))
|
|
5127
5323
|
),
|
|
5128
5324
|
Effect.scoped
|
|
5129
5325
|
),
|
|
@@ -5132,11 +5328,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5132
5328
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5133
5329
|
Effect.flatMap((request) =>
|
|
5134
5330
|
Effect.flatMap(
|
|
5135
|
-
httpClient
|
|
5136
|
-
|
|
5137
|
-
|
|
5138
|
-
|
|
5139
|
-
|
|
5331
|
+
applyClientTransform(httpClient),
|
|
5332
|
+
(httpClient) =>
|
|
5333
|
+
Effect.flatMap(
|
|
5334
|
+
httpClient.execute(request),
|
|
5335
|
+
HttpClientResponse.matchStatus({
|
|
5336
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreObject)(r),
|
|
5337
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5338
|
+
})
|
|
5339
|
+
)
|
|
5140
5340
|
)
|
|
5141
5341
|
),
|
|
5142
5342
|
Effect.scoped
|
|
@@ -5145,13 +5345,14 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5145
5345
|
HttpClientRequest.make("DELETE")(`/vector_stores/${vectorStoreId}`).pipe(
|
|
5146
5346
|
Effect.succeed,
|
|
5147
5347
|
Effect.flatMap((request) =>
|
|
5148
|
-
Effect.flatMap(
|
|
5149
|
-
|
|
5150
|
-
|
|
5151
|
-
|
|
5152
|
-
|
|
5153
|
-
|
|
5154
|
-
|
|
5348
|
+
Effect.flatMap(applyClientTransform(httpClient), (httpClient) =>
|
|
5349
|
+
Effect.flatMap(
|
|
5350
|
+
httpClient.execute(request),
|
|
5351
|
+
HttpClientResponse.matchStatus({
|
|
5352
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteVectorStoreResponse)(r),
|
|
5353
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5354
|
+
})
|
|
5355
|
+
))
|
|
5155
5356
|
),
|
|
5156
5357
|
Effect.scoped
|
|
5157
5358
|
),
|
|
@@ -5160,11 +5361,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5160
5361
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5161
5362
|
Effect.flatMap((request) =>
|
|
5162
5363
|
Effect.flatMap(
|
|
5163
|
-
httpClient
|
|
5164
|
-
|
|
5165
|
-
|
|
5166
|
-
|
|
5167
|
-
|
|
5364
|
+
applyClientTransform(httpClient),
|
|
5365
|
+
(httpClient) =>
|
|
5366
|
+
Effect.flatMap(
|
|
5367
|
+
httpClient.execute(request),
|
|
5368
|
+
HttpClientResponse.matchStatus({
|
|
5369
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreFileBatchObject)(r),
|
|
5370
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5371
|
+
})
|
|
5372
|
+
)
|
|
5168
5373
|
)
|
|
5169
5374
|
),
|
|
5170
5375
|
Effect.scoped
|
|
@@ -5174,11 +5379,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5174
5379
|
Effect.succeed,
|
|
5175
5380
|
Effect.flatMap((request) =>
|
|
5176
5381
|
Effect.flatMap(
|
|
5177
|
-
httpClient
|
|
5178
|
-
|
|
5179
|
-
|
|
5180
|
-
|
|
5181
|
-
|
|
5382
|
+
applyClientTransform(httpClient),
|
|
5383
|
+
(httpClient) =>
|
|
5384
|
+
Effect.flatMap(
|
|
5385
|
+
httpClient.execute(request),
|
|
5386
|
+
HttpClientResponse.matchStatus({
|
|
5387
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreFileBatchObject)(r),
|
|
5388
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5389
|
+
})
|
|
5390
|
+
)
|
|
5182
5391
|
)
|
|
5183
5392
|
),
|
|
5184
5393
|
Effect.scoped
|
|
@@ -5188,11 +5397,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5188
5397
|
Effect.succeed,
|
|
5189
5398
|
Effect.flatMap((request) =>
|
|
5190
5399
|
Effect.flatMap(
|
|
5191
|
-
httpClient
|
|
5192
|
-
|
|
5193
|
-
|
|
5194
|
-
|
|
5195
|
-
|
|
5400
|
+
applyClientTransform(httpClient),
|
|
5401
|
+
(httpClient) =>
|
|
5402
|
+
Effect.flatMap(
|
|
5403
|
+
httpClient.execute(request),
|
|
5404
|
+
HttpClientResponse.matchStatus({
|
|
5405
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreFileBatchObject)(r),
|
|
5406
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5407
|
+
})
|
|
5408
|
+
)
|
|
5196
5409
|
)
|
|
5197
5410
|
),
|
|
5198
5411
|
Effect.scoped
|
|
@@ -5209,11 +5422,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5209
5422
|
Effect.succeed,
|
|
5210
5423
|
Effect.flatMap((request) =>
|
|
5211
5424
|
Effect.flatMap(
|
|
5212
|
-
httpClient
|
|
5213
|
-
|
|
5214
|
-
|
|
5215
|
-
|
|
5216
|
-
|
|
5425
|
+
applyClientTransform(httpClient),
|
|
5426
|
+
(httpClient) =>
|
|
5427
|
+
Effect.flatMap(
|
|
5428
|
+
httpClient.execute(request),
|
|
5429
|
+
HttpClientResponse.matchStatus({
|
|
5430
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListVectorStoreFilesResponse)(r),
|
|
5431
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5432
|
+
})
|
|
5433
|
+
)
|
|
5217
5434
|
)
|
|
5218
5435
|
),
|
|
5219
5436
|
Effect.scoped
|
|
@@ -5230,11 +5447,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5230
5447
|
Effect.succeed,
|
|
5231
5448
|
Effect.flatMap((request) =>
|
|
5232
5449
|
Effect.flatMap(
|
|
5233
|
-
httpClient
|
|
5234
|
-
|
|
5235
|
-
|
|
5236
|
-
|
|
5237
|
-
|
|
5450
|
+
applyClientTransform(httpClient),
|
|
5451
|
+
(httpClient) =>
|
|
5452
|
+
Effect.flatMap(
|
|
5453
|
+
httpClient.execute(request),
|
|
5454
|
+
HttpClientResponse.matchStatus({
|
|
5455
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(ListVectorStoreFilesResponse)(r),
|
|
5456
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5457
|
+
})
|
|
5458
|
+
)
|
|
5238
5459
|
)
|
|
5239
5460
|
),
|
|
5240
5461
|
Effect.scoped
|
|
@@ -5244,11 +5465,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5244
5465
|
(req) => Effect.orDie(HttpClientRequest.bodyJson(req, options)),
|
|
5245
5466
|
Effect.flatMap((request) =>
|
|
5246
5467
|
Effect.flatMap(
|
|
5247
|
-
httpClient
|
|
5248
|
-
|
|
5249
|
-
|
|
5250
|
-
|
|
5251
|
-
|
|
5468
|
+
applyClientTransform(httpClient),
|
|
5469
|
+
(httpClient) =>
|
|
5470
|
+
Effect.flatMap(
|
|
5471
|
+
httpClient.execute(request),
|
|
5472
|
+
HttpClientResponse.matchStatus({
|
|
5473
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreFileObject)(r),
|
|
5474
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5475
|
+
})
|
|
5476
|
+
)
|
|
5252
5477
|
)
|
|
5253
5478
|
),
|
|
5254
5479
|
Effect.scoped
|
|
@@ -5258,11 +5483,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5258
5483
|
Effect.succeed,
|
|
5259
5484
|
Effect.flatMap((request) =>
|
|
5260
5485
|
Effect.flatMap(
|
|
5261
|
-
httpClient
|
|
5262
|
-
|
|
5263
|
-
|
|
5264
|
-
|
|
5265
|
-
|
|
5486
|
+
applyClientTransform(httpClient),
|
|
5487
|
+
(httpClient) =>
|
|
5488
|
+
Effect.flatMap(
|
|
5489
|
+
httpClient.execute(request),
|
|
5490
|
+
HttpClientResponse.matchStatus({
|
|
5491
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(VectorStoreFileObject)(r),
|
|
5492
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5493
|
+
})
|
|
5494
|
+
)
|
|
5266
5495
|
)
|
|
5267
5496
|
),
|
|
5268
5497
|
Effect.scoped
|
|
@@ -5272,11 +5501,15 @@ export const make = (httpClient: HttpClient.HttpClient): Client => {
|
|
|
5272
5501
|
Effect.succeed,
|
|
5273
5502
|
Effect.flatMap((request) =>
|
|
5274
5503
|
Effect.flatMap(
|
|
5275
|
-
httpClient
|
|
5276
|
-
|
|
5277
|
-
|
|
5278
|
-
|
|
5279
|
-
|
|
5504
|
+
applyClientTransform(httpClient),
|
|
5505
|
+
(httpClient) =>
|
|
5506
|
+
Effect.flatMap(
|
|
5507
|
+
httpClient.execute(request),
|
|
5508
|
+
HttpClientResponse.matchStatus({
|
|
5509
|
+
"200": (r) => HttpClientResponse.schemaBodyJson(DeleteVectorStoreFileResponse)(r),
|
|
5510
|
+
orElse: (response) => unexpectedStatus(request, response)
|
|
5511
|
+
})
|
|
5512
|
+
)
|
|
5280
5513
|
)
|
|
5281
5514
|
),
|
|
5282
5515
|
Effect.scoped
|