openai_openapi_http/
generated.rs

1#[doc = "List assistants"]
2pub fn list_assistants<C, Fut, B, E>(
3    client: C,
4    params: &crate::__types::list_assistants::Params,
5) -> ListAssistants<Fut, B, E>
6where
7    C: FnOnce(http::Request<String>) -> Fut,
8    Fut: Future<Output = Result<http::Response<B>, E>>,
9    B: http_body::Body,
10{
11    ListAssistants(futures::TryFutureExt::and_then(
12        crate::__combinators::Send::new(
13            client,
14            || {
15                let path = {
16                    #[serde_with::serde_as]
17                    #[derive(serde :: Serialize)]
18                    struct Query<'a> {
19                        #[serde(rename = "limit")]
20                        #[serde(skip_serializing_if = "Option::is_none")]
21                        limit: &'a Option<i64>,
22                        #[serde(rename = "order")]
23                        #[serde(skip_serializing_if = "Option::is_none")]
24                        order: &'a Option<crate::__types::list_assistants::params::Order>,
25                        #[serde(rename = "after")]
26                        #[serde(skip_serializing_if = "Option::is_none")]
27                        after: &'a Option<String>,
28                        #[serde(rename = "before")]
29                        #[serde(skip_serializing_if = "Option::is_none")]
30                        before: &'a Option<String>,
31                        #[serde(skip_serializing)]
32                        _phantom: std::marker::PhantomData<&'a ()>,
33                    }
34                    let crate::__types::list_assistants::Params {
35                        limit,
36                        order,
37                        after,
38                        before,
39                    } = params;
40                    #[allow(clippy::useless_format)]
41                    let mut path = format!("/assistants");
42                    let query = serde_urlencoded::to_string(Query {
43                        limit,
44                        order,
45                        after,
46                        before,
47                        _phantom: std::marker::PhantomData,
48                    })?;
49                    if !query.is_empty() {
50                        path.push('?');
51                        path.push_str(&query);
52                    }
53                    path
54                };
55                let body = String::new();
56                Ok(http::Request::builder()
57                    .method(http::Method::GET)
58                    .uri(path)
59                    .header(http::header::CONTENT_LENGTH, body.len())
60                    .body(body)?)
61            },
62            (
63                http::StatusCode::from_u16(200u16).unwrap(),
64                Some(mime::APPLICATION_JSON),
65            ),
66        ),
67        crate::__combinators::Json::new,
68    ))
69}
70future!(
71    ListAssistants,
72    futures::future::AndThen<
73        crate::__combinators::Send<Fut, B, E>,
74        crate::__combinators::Json<B, E, crate::__types::ListAssistantsResponse>,
75        fn(
76            http::Response<B>,
77        ) -> crate::__combinators::Json<B, E, crate::__types::ListAssistantsResponse>,
78    >,
79    crate::__types::ListAssistantsResponse
80);
81#[doc = "Create assistant"]
82pub fn create_assistant<C, Fut, B, E>(
83    client: C,
84    request: &crate::__types::CreateAssistantRequest,
85) -> CreateAssistant<Fut, B, E>
86where
87    C: FnOnce(http::Request<String>) -> Fut,
88    Fut: Future<Output = Result<http::Response<B>, E>>,
89    B: http_body::Body,
90{
91    CreateAssistant(futures::TryFutureExt::and_then(
92        crate::__combinators::Send::new(
93            client,
94            || {
95                let path = "/assistants";
96                let body = serde_json::to_string(request)?;
97                Ok(http::Request::builder()
98                    .method(http::Method::POST)
99                    .uri(path)
100                    .header(http::header::CONTENT_LENGTH, body.len())
101                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
102                    .body(body)?)
103            },
104            (
105                http::StatusCode::from_u16(200u16).unwrap(),
106                Some(mime::APPLICATION_JSON),
107            ),
108        ),
109        crate::__combinators::Json::new,
110    ))
111}
112future!(
113    CreateAssistant,
114    futures::future::AndThen<
115        crate::__combinators::Send<Fut, B, E>,
116        crate::__combinators::Json<B, E, crate::__types::AssistantObject>,
117        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::AssistantObject>,
118    >,
119    crate::__types::AssistantObject
120);
121#[doc = "Retrieve assistant"]
122pub fn get_assistant<C, Fut, B, E>(
123    client: C,
124    params: &crate::__types::get_assistant::Params,
125) -> GetAssistant<Fut, B, E>
126where
127    C: FnOnce(http::Request<String>) -> Fut,
128    Fut: Future<Output = Result<http::Response<B>, E>>,
129    B: http_body::Body,
130{
131    GetAssistant(futures::TryFutureExt::and_then(
132        crate::__combinators::Send::new(
133            client,
134            || {
135                let path = {
136                    #[serde_with::serde_as]
137                    #[derive(serde :: Serialize)]
138                    struct Query<'a> {
139                        #[serde(skip_serializing)]
140                        _phantom: std::marker::PhantomData<&'a ()>,
141                    }
142                    let crate::__types::get_assistant::Params { assistant_id } = params;
143                    #[allow(clippy::useless_format)]
144                    let mut path = format!("/assistants/{assistant_id}");
145                    let query = serde_urlencoded::to_string(Query {
146                        _phantom: std::marker::PhantomData,
147                    })?;
148                    if !query.is_empty() {
149                        path.push('?');
150                        path.push_str(&query);
151                    }
152                    path
153                };
154                let body = String::new();
155                Ok(http::Request::builder()
156                    .method(http::Method::GET)
157                    .uri(path)
158                    .header(http::header::CONTENT_LENGTH, body.len())
159                    .body(body)?)
160            },
161            (
162                http::StatusCode::from_u16(200u16).unwrap(),
163                Some(mime::APPLICATION_JSON),
164            ),
165        ),
166        crate::__combinators::Json::new,
167    ))
168}
169future!(
170    GetAssistant,
171    futures::future::AndThen<
172        crate::__combinators::Send<Fut, B, E>,
173        crate::__combinators::Json<B, E, crate::__types::AssistantObject>,
174        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::AssistantObject>,
175    >,
176    crate::__types::AssistantObject
177);
178#[doc = "Modify assistant"]
179pub fn modify_assistant<C, Fut, B, E>(
180    client: C,
181    params: &crate::__types::modify_assistant::Params,
182    request: &crate::__types::ModifyAssistantRequest,
183) -> ModifyAssistant<Fut, B, E>
184where
185    C: FnOnce(http::Request<String>) -> Fut,
186    Fut: Future<Output = Result<http::Response<B>, E>>,
187    B: http_body::Body,
188{
189    ModifyAssistant(futures::TryFutureExt::and_then(
190        crate::__combinators::Send::new(
191            client,
192            || {
193                let path = {
194                    #[serde_with::serde_as]
195                    #[derive(serde :: Serialize)]
196                    struct Query<'a> {
197                        #[serde(skip_serializing)]
198                        _phantom: std::marker::PhantomData<&'a ()>,
199                    }
200                    let crate::__types::modify_assistant::Params { assistant_id } = params;
201                    #[allow(clippy::useless_format)]
202                    let mut path = format!("/assistants/{assistant_id}");
203                    let query = serde_urlencoded::to_string(Query {
204                        _phantom: std::marker::PhantomData,
205                    })?;
206                    if !query.is_empty() {
207                        path.push('?');
208                        path.push_str(&query);
209                    }
210                    path
211                };
212                let body = serde_json::to_string(request)?;
213                Ok(http::Request::builder()
214                    .method(http::Method::POST)
215                    .uri(path)
216                    .header(http::header::CONTENT_LENGTH, body.len())
217                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
218                    .body(body)?)
219            },
220            (
221                http::StatusCode::from_u16(200u16).unwrap(),
222                Some(mime::APPLICATION_JSON),
223            ),
224        ),
225        crate::__combinators::Json::new,
226    ))
227}
228future!(
229    ModifyAssistant,
230    futures::future::AndThen<
231        crate::__combinators::Send<Fut, B, E>,
232        crate::__combinators::Json<B, E, crate::__types::AssistantObject>,
233        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::AssistantObject>,
234    >,
235    crate::__types::AssistantObject
236);
237#[doc = "Delete assistant"]
238pub fn delete_assistant<C, Fut, B, E>(
239    client: C,
240    params: &crate::__types::delete_assistant::Params,
241) -> DeleteAssistant<Fut, B, E>
242where
243    C: FnOnce(http::Request<String>) -> Fut,
244    Fut: Future<Output = Result<http::Response<B>, E>>,
245    B: http_body::Body,
246{
247    DeleteAssistant(futures::TryFutureExt::and_then(
248        crate::__combinators::Send::new(
249            client,
250            || {
251                let path = {
252                    #[serde_with::serde_as]
253                    #[derive(serde :: Serialize)]
254                    struct Query<'a> {
255                        #[serde(skip_serializing)]
256                        _phantom: std::marker::PhantomData<&'a ()>,
257                    }
258                    let crate::__types::delete_assistant::Params { assistant_id } = params;
259                    #[allow(clippy::useless_format)]
260                    let mut path = format!("/assistants/{assistant_id}");
261                    let query = serde_urlencoded::to_string(Query {
262                        _phantom: std::marker::PhantomData,
263                    })?;
264                    if !query.is_empty() {
265                        path.push('?');
266                        path.push_str(&query);
267                    }
268                    path
269                };
270                let body = String::new();
271                Ok(http::Request::builder()
272                    .method(http::Method::DELETE)
273                    .uri(path)
274                    .header(http::header::CONTENT_LENGTH, body.len())
275                    .body(body)?)
276            },
277            (
278                http::StatusCode::from_u16(200u16).unwrap(),
279                Some(mime::APPLICATION_JSON),
280            ),
281        ),
282        crate::__combinators::Json::new,
283    ))
284}
285future!(
286    DeleteAssistant,
287    futures::future::AndThen<
288        crate::__combinators::Send<Fut, B, E>,
289        crate::__combinators::Json<B, E, crate::__types::DeleteAssistantResponse>,
290        fn(
291            http::Response<B>,
292        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteAssistantResponse>,
293    >,
294    crate::__types::DeleteAssistantResponse
295);
296#[doc = "Create speech"]
297pub fn create_speech_stream<C, Fut, B, E>(
298    client: C,
299    request: &crate::__types::CreateSpeechRequest,
300) -> CreateSpeechStream<Fut, B, E>
301where
302    C: FnOnce(http::Request<String>) -> Fut,
303    Fut: Future<Output = Result<http::Response<B>, E>>,
304    B: http_body::Body,
305{
306    CreateSpeechStream(futures::TryFutureExt::map_ok(
307        crate::__combinators::Send::new(
308            client,
309            || {
310                let path = "/audio/speech";
311                let body = serde_json::to_string(request)?;
312                Ok(http::Request::builder()
313                    .method(http::Method::POST)
314                    .uri(path)
315                    .header(http::header::CONTENT_LENGTH, body.len())
316                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
317                    .body(body)?)
318            },
319            (
320                http::StatusCode::from_u16(200u16).unwrap(),
321                Some(mime::TEXT_EVENT_STREAM),
322            ),
323        ),
324        crate::__combinators::EventStream::new,
325    ))
326}
327future ! (CreateSpeechStream , futures :: future :: MapOk < crate :: __combinators :: Send < Fut , B , E > , fn (http :: Response < B >) -> crate :: __combinators :: EventStream < B , crate :: __types :: CreateSpeechResponseStreamEvent > , > , crate :: __combinators :: EventStream < B , crate :: __types :: CreateSpeechResponseStreamEvent >);
328#[doc = "Create batch"]
329pub fn create_batch<C, Fut, B, E>(
330    client: C,
331    request: &crate::__types::create_batch::Request,
332) -> CreateBatch<Fut, B, E>
333where
334    C: FnOnce(http::Request<String>) -> Fut,
335    Fut: Future<Output = Result<http::Response<B>, E>>,
336    B: http_body::Body,
337{
338    CreateBatch(futures::TryFutureExt::and_then(
339        crate::__combinators::Send::new(
340            client,
341            || {
342                let path = "/batches";
343                let body = serde_json::to_string(request)?;
344                Ok(http::Request::builder()
345                    .method(http::Method::POST)
346                    .uri(path)
347                    .header(http::header::CONTENT_LENGTH, body.len())
348                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
349                    .body(body)?)
350            },
351            (
352                http::StatusCode::from_u16(200u16).unwrap(),
353                Some(mime::APPLICATION_JSON),
354            ),
355        ),
356        crate::__combinators::Json::new,
357    ))
358}
359future!(
360    CreateBatch,
361    futures::future::AndThen<
362        crate::__combinators::Send<Fut, B, E>,
363        crate::__combinators::Json<B, E, crate::__types::Batch>,
364        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Batch>,
365    >,
366    crate::__types::Batch
367);
368#[doc = "List batch"]
369pub fn list_batches<C, Fut, B, E>(
370    client: C,
371    params: &crate::__types::list_batches::Params,
372) -> ListBatches<Fut, B, E>
373where
374    C: FnOnce(http::Request<String>) -> Fut,
375    Fut: Future<Output = Result<http::Response<B>, E>>,
376    B: http_body::Body,
377{
378    ListBatches(futures::TryFutureExt::and_then(
379        crate::__combinators::Send::new(
380            client,
381            || {
382                let path = {
383                    #[serde_with::serde_as]
384                    #[derive(serde :: Serialize)]
385                    struct Query<'a> {
386                        #[serde(rename = "after")]
387                        #[serde(skip_serializing_if = "Option::is_none")]
388                        after: &'a Option<String>,
389                        #[serde(rename = "limit")]
390                        #[serde(skip_serializing_if = "Option::is_none")]
391                        limit: &'a Option<i64>,
392                        #[serde(skip_serializing)]
393                        _phantom: std::marker::PhantomData<&'a ()>,
394                    }
395                    let crate::__types::list_batches::Params { after, limit } = params;
396                    #[allow(clippy::useless_format)]
397                    let mut path = format!("/batches");
398                    let query = serde_urlencoded::to_string(Query {
399                        after,
400                        limit,
401                        _phantom: std::marker::PhantomData,
402                    })?;
403                    if !query.is_empty() {
404                        path.push('?');
405                        path.push_str(&query);
406                    }
407                    path
408                };
409                let body = String::new();
410                Ok(http::Request::builder()
411                    .method(http::Method::GET)
412                    .uri(path)
413                    .header(http::header::CONTENT_LENGTH, body.len())
414                    .body(body)?)
415            },
416            (
417                http::StatusCode::from_u16(200u16).unwrap(),
418                Some(mime::APPLICATION_JSON),
419            ),
420        ),
421        crate::__combinators::Json::new,
422    ))
423}
424future!(
425    ListBatches,
426    futures::future::AndThen<
427        crate::__combinators::Send<Fut, B, E>,
428        crate::__combinators::Json<B, E, crate::__types::ListBatchesResponse>,
429        fn(
430            http::Response<B>,
431        ) -> crate::__combinators::Json<B, E, crate::__types::ListBatchesResponse>,
432    >,
433    crate::__types::ListBatchesResponse
434);
435#[doc = "Retrieve batch"]
436pub fn retrieve_batch<C, Fut, B, E>(
437    client: C,
438    params: &crate::__types::retrieve_batch::Params,
439) -> RetrieveBatch<Fut, B, E>
440where
441    C: FnOnce(http::Request<String>) -> Fut,
442    Fut: Future<Output = Result<http::Response<B>, E>>,
443    B: http_body::Body,
444{
445    RetrieveBatch(futures::TryFutureExt::and_then(
446        crate::__combinators::Send::new(
447            client,
448            || {
449                let path = {
450                    #[serde_with::serde_as]
451                    #[derive(serde :: Serialize)]
452                    struct Query<'a> {
453                        #[serde(skip_serializing)]
454                        _phantom: std::marker::PhantomData<&'a ()>,
455                    }
456                    let crate::__types::retrieve_batch::Params { batch_id } = params;
457                    #[allow(clippy::useless_format)]
458                    let mut path = format!("/batches/{batch_id}");
459                    let query = serde_urlencoded::to_string(Query {
460                        _phantom: std::marker::PhantomData,
461                    })?;
462                    if !query.is_empty() {
463                        path.push('?');
464                        path.push_str(&query);
465                    }
466                    path
467                };
468                let body = String::new();
469                Ok(http::Request::builder()
470                    .method(http::Method::GET)
471                    .uri(path)
472                    .header(http::header::CONTENT_LENGTH, body.len())
473                    .body(body)?)
474            },
475            (
476                http::StatusCode::from_u16(200u16).unwrap(),
477                Some(mime::APPLICATION_JSON),
478            ),
479        ),
480        crate::__combinators::Json::new,
481    ))
482}
483future!(
484    RetrieveBatch,
485    futures::future::AndThen<
486        crate::__combinators::Send<Fut, B, E>,
487        crate::__combinators::Json<B, E, crate::__types::Batch>,
488        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Batch>,
489    >,
490    crate::__types::Batch
491);
492#[doc = "Cancel batch"]
493pub fn cancel_batch<C, Fut, B, E>(
494    client: C,
495    params: &crate::__types::cancel_batch::Params,
496) -> CancelBatch<Fut, B, E>
497where
498    C: FnOnce(http::Request<String>) -> Fut,
499    Fut: Future<Output = Result<http::Response<B>, E>>,
500    B: http_body::Body,
501{
502    CancelBatch(futures::TryFutureExt::and_then(
503        crate::__combinators::Send::new(
504            client,
505            || {
506                let path = {
507                    #[serde_with::serde_as]
508                    #[derive(serde :: Serialize)]
509                    struct Query<'a> {
510                        #[serde(skip_serializing)]
511                        _phantom: std::marker::PhantomData<&'a ()>,
512                    }
513                    let crate::__types::cancel_batch::Params { batch_id } = params;
514                    #[allow(clippy::useless_format)]
515                    let mut path = format!("/batches/{batch_id}/cancel");
516                    let query = serde_urlencoded::to_string(Query {
517                        _phantom: std::marker::PhantomData,
518                    })?;
519                    if !query.is_empty() {
520                        path.push('?');
521                        path.push_str(&query);
522                    }
523                    path
524                };
525                let body = String::new();
526                Ok(http::Request::builder()
527                    .method(http::Method::POST)
528                    .uri(path)
529                    .header(http::header::CONTENT_LENGTH, body.len())
530                    .body(body)?)
531            },
532            (
533                http::StatusCode::from_u16(200u16).unwrap(),
534                Some(mime::APPLICATION_JSON),
535            ),
536        ),
537        crate::__combinators::Json::new,
538    ))
539}
540future!(
541    CancelBatch,
542    futures::future::AndThen<
543        crate::__combinators::Send<Fut, B, E>,
544        crate::__combinators::Json<B, E, crate::__types::Batch>,
545        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Batch>,
546    >,
547    crate::__types::Batch
548);
549#[doc = "List Chat Completions"]
550pub fn list_chat_completions<C, Fut, B, E>(
551    client: C,
552    params: &crate::__types::list_chat_completions::Params,
553) -> ListChatCompletions<Fut, B, E>
554where
555    C: FnOnce(http::Request<String>) -> Fut,
556    Fut: Future<Output = Result<http::Response<B>, E>>,
557    B: http_body::Body,
558{
559    ListChatCompletions(futures::TryFutureExt::and_then(
560        crate::__combinators::Send::new(
561            client,
562            || {
563                let path = {
564                    #[serde_with::serde_as]
565                    #[derive(serde :: Serialize)]
566                    struct Query<'a> {
567                        #[serde(rename = "model")]
568                        #[serde(skip_serializing_if = "Option::is_none")]
569                        model: &'a Option<String>,
570                        #[serde(rename = "metadata")]
571                        #[serde(skip_serializing_if = "Option::is_none")]
572                        metadata: &'a Option<crate::__types::Metadata>,
573                        #[serde(rename = "after")]
574                        #[serde(skip_serializing_if = "Option::is_none")]
575                        after: &'a Option<String>,
576                        #[serde(rename = "limit")]
577                        #[serde(skip_serializing_if = "Option::is_none")]
578                        limit: &'a Option<i64>,
579                        #[serde(rename = "order")]
580                        #[serde(skip_serializing_if = "Option::is_none")]
581                        order: &'a Option<crate::__types::list_chat_completions::params::Order>,
582                        #[serde(skip_serializing)]
583                        _phantom: std::marker::PhantomData<&'a ()>,
584                    }
585                    let crate::__types::list_chat_completions::Params {
586                        model,
587                        metadata,
588                        after,
589                        limit,
590                        order,
591                    } = params;
592                    #[allow(clippy::useless_format)]
593                    let mut path = format!("/chat/completions");
594                    let query = serde_urlencoded::to_string(Query {
595                        model,
596                        metadata,
597                        after,
598                        limit,
599                        order,
600                        _phantom: std::marker::PhantomData,
601                    })?;
602                    if !query.is_empty() {
603                        path.push('?');
604                        path.push_str(&query);
605                    }
606                    path
607                };
608                let body = String::new();
609                Ok(http::Request::builder()
610                    .method(http::Method::GET)
611                    .uri(path)
612                    .header(http::header::CONTENT_LENGTH, body.len())
613                    .body(body)?)
614            },
615            (
616                http::StatusCode::from_u16(200u16).unwrap(),
617                Some(mime::APPLICATION_JSON),
618            ),
619        ),
620        crate::__combinators::Json::new,
621    ))
622}
623future!(
624    ListChatCompletions,
625    futures::future::AndThen<
626        crate::__combinators::Send<Fut, B, E>,
627        crate::__combinators::Json<B, E, crate::__types::ChatCompletionList>,
628        fn(
629            http::Response<B>,
630        ) -> crate::__combinators::Json<B, E, crate::__types::ChatCompletionList>,
631    >,
632    crate::__types::ChatCompletionList
633);
634#[doc = "Create chat completion"]
635pub fn create_chat_completion<C, Fut, B, E>(
636    client: C,
637    request: &crate::__types::CreateChatCompletionRequest,
638) -> CreateChatCompletion<Fut, B, E>
639where
640    C: FnOnce(http::Request<String>) -> Fut,
641    Fut: Future<Output = Result<http::Response<B>, E>>,
642    B: http_body::Body,
643{
644    CreateChatCompletion(futures::TryFutureExt::and_then(
645        crate::__combinators::Send::new(
646            client,
647            || {
648                let path = "/chat/completions";
649                let body = serde_json::to_string(request)?;
650                Ok(http::Request::builder()
651                    .method(http::Method::POST)
652                    .uri(path)
653                    .header(http::header::CONTENT_LENGTH, body.len())
654                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
655                    .body(body)?)
656            },
657            (
658                http::StatusCode::from_u16(200u16).unwrap(),
659                Some(mime::APPLICATION_JSON),
660            ),
661        ),
662        crate::__combinators::Json::new,
663    ))
664}
665future!(
666    CreateChatCompletion,
667    futures::future::AndThen<
668        crate::__combinators::Send<Fut, B, E>,
669        crate::__combinators::Json<B, E, crate::__types::CreateChatCompletionResponse>,
670        fn(
671            http::Response<B>,
672        )
673            -> crate::__combinators::Json<B, E, crate::__types::CreateChatCompletionResponse>,
674    >,
675    crate::__types::CreateChatCompletionResponse
676);
677#[doc = "Create chat completion"]
678pub fn create_chat_completion_stream<C, Fut, B, E>(
679    client: C,
680    request: &crate::__types::CreateChatCompletionRequest,
681) -> CreateChatCompletionStream<Fut, B, E>
682where
683    C: FnOnce(http::Request<String>) -> Fut,
684    Fut: Future<Output = Result<http::Response<B>, E>>,
685    B: http_body::Body,
686{
687    CreateChatCompletionStream(futures::TryFutureExt::map_ok(
688        crate::__combinators::Send::new(
689            client,
690            || {
691                let path = "/chat/completions";
692                let body = serde_json::to_string(request)?;
693                Ok(http::Request::builder()
694                    .method(http::Method::POST)
695                    .uri(path)
696                    .header(http::header::CONTENT_LENGTH, body.len())
697                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
698                    .body(body)?)
699            },
700            (
701                http::StatusCode::from_u16(200u16).unwrap(),
702                Some(mime::TEXT_EVENT_STREAM),
703            ),
704        ),
705        crate::__combinators::EventStream::new,
706    ))
707}
708future ! (CreateChatCompletionStream , futures :: future :: MapOk < crate :: __combinators :: Send < Fut , B , E > , fn (http :: Response < B >) -> crate :: __combinators :: EventStream < B , crate :: __types :: CreateChatCompletionStreamResponse > , > , crate :: __combinators :: EventStream < B , crate :: __types :: CreateChatCompletionStreamResponse >);
709#[doc = "Get chat completion"]
710pub fn get_chat_completion<C, Fut, B, E>(
711    client: C,
712    params: &crate::__types::get_chat_completion::Params,
713) -> GetChatCompletion<Fut, B, E>
714where
715    C: FnOnce(http::Request<String>) -> Fut,
716    Fut: Future<Output = Result<http::Response<B>, E>>,
717    B: http_body::Body,
718{
719    GetChatCompletion(futures::TryFutureExt::and_then(
720        crate::__combinators::Send::new(
721            client,
722            || {
723                let path = {
724                    #[serde_with::serde_as]
725                    #[derive(serde :: Serialize)]
726                    struct Query<'a> {
727                        #[serde(skip_serializing)]
728                        _phantom: std::marker::PhantomData<&'a ()>,
729                    }
730                    let crate::__types::get_chat_completion::Params { completion_id } = params;
731                    #[allow(clippy::useless_format)]
732                    let mut path = format!("/chat/completions/{completion_id}");
733                    let query = serde_urlencoded::to_string(Query {
734                        _phantom: std::marker::PhantomData,
735                    })?;
736                    if !query.is_empty() {
737                        path.push('?');
738                        path.push_str(&query);
739                    }
740                    path
741                };
742                let body = String::new();
743                Ok(http::Request::builder()
744                    .method(http::Method::GET)
745                    .uri(path)
746                    .header(http::header::CONTENT_LENGTH, body.len())
747                    .body(body)?)
748            },
749            (
750                http::StatusCode::from_u16(200u16).unwrap(),
751                Some(mime::APPLICATION_JSON),
752            ),
753        ),
754        crate::__combinators::Json::new,
755    ))
756}
757future!(
758    GetChatCompletion,
759    futures::future::AndThen<
760        crate::__combinators::Send<Fut, B, E>,
761        crate::__combinators::Json<B, E, crate::__types::CreateChatCompletionResponse>,
762        fn(
763            http::Response<B>,
764        )
765            -> crate::__combinators::Json<B, E, crate::__types::CreateChatCompletionResponse>,
766    >,
767    crate::__types::CreateChatCompletionResponse
768);
769#[doc = "Update chat completion"]
770pub fn update_chat_completion<C, Fut, B, E>(
771    client: C,
772    params: &crate::__types::update_chat_completion::Params,
773    request: &crate::__types::update_chat_completion::Request,
774) -> UpdateChatCompletion<Fut, B, E>
775where
776    C: FnOnce(http::Request<String>) -> Fut,
777    Fut: Future<Output = Result<http::Response<B>, E>>,
778    B: http_body::Body,
779{
780    UpdateChatCompletion(futures::TryFutureExt::and_then(
781        crate::__combinators::Send::new(
782            client,
783            || {
784                let path = {
785                    #[serde_with::serde_as]
786                    #[derive(serde :: Serialize)]
787                    struct Query<'a> {
788                        #[serde(skip_serializing)]
789                        _phantom: std::marker::PhantomData<&'a ()>,
790                    }
791                    let crate::__types::update_chat_completion::Params { completion_id } = params;
792                    #[allow(clippy::useless_format)]
793                    let mut path = format!("/chat/completions/{completion_id}");
794                    let query = serde_urlencoded::to_string(Query {
795                        _phantom: std::marker::PhantomData,
796                    })?;
797                    if !query.is_empty() {
798                        path.push('?');
799                        path.push_str(&query);
800                    }
801                    path
802                };
803                let body = serde_json::to_string(request)?;
804                Ok(http::Request::builder()
805                    .method(http::Method::POST)
806                    .uri(path)
807                    .header(http::header::CONTENT_LENGTH, body.len())
808                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
809                    .body(body)?)
810            },
811            (
812                http::StatusCode::from_u16(200u16).unwrap(),
813                Some(mime::APPLICATION_JSON),
814            ),
815        ),
816        crate::__combinators::Json::new,
817    ))
818}
819future!(
820    UpdateChatCompletion,
821    futures::future::AndThen<
822        crate::__combinators::Send<Fut, B, E>,
823        crate::__combinators::Json<B, E, crate::__types::CreateChatCompletionResponse>,
824        fn(
825            http::Response<B>,
826        )
827            -> crate::__combinators::Json<B, E, crate::__types::CreateChatCompletionResponse>,
828    >,
829    crate::__types::CreateChatCompletionResponse
830);
831#[doc = "Delete chat completion"]
832pub fn delete_chat_completion<C, Fut, B, E>(
833    client: C,
834    params: &crate::__types::delete_chat_completion::Params,
835) -> DeleteChatCompletion<Fut, B, E>
836where
837    C: FnOnce(http::Request<String>) -> Fut,
838    Fut: Future<Output = Result<http::Response<B>, E>>,
839    B: http_body::Body,
840{
841    DeleteChatCompletion(futures::TryFutureExt::and_then(
842        crate::__combinators::Send::new(
843            client,
844            || {
845                let path = {
846                    #[serde_with::serde_as]
847                    #[derive(serde :: Serialize)]
848                    struct Query<'a> {
849                        #[serde(skip_serializing)]
850                        _phantom: std::marker::PhantomData<&'a ()>,
851                    }
852                    let crate::__types::delete_chat_completion::Params { completion_id } = params;
853                    #[allow(clippy::useless_format)]
854                    let mut path = format!("/chat/completions/{completion_id}");
855                    let query = serde_urlencoded::to_string(Query {
856                        _phantom: std::marker::PhantomData,
857                    })?;
858                    if !query.is_empty() {
859                        path.push('?');
860                        path.push_str(&query);
861                    }
862                    path
863                };
864                let body = String::new();
865                Ok(http::Request::builder()
866                    .method(http::Method::DELETE)
867                    .uri(path)
868                    .header(http::header::CONTENT_LENGTH, body.len())
869                    .body(body)?)
870            },
871            (
872                http::StatusCode::from_u16(200u16).unwrap(),
873                Some(mime::APPLICATION_JSON),
874            ),
875        ),
876        crate::__combinators::Json::new,
877    ))
878}
879future!(
880    DeleteChatCompletion,
881    futures::future::AndThen<
882        crate::__combinators::Send<Fut, B, E>,
883        crate::__combinators::Json<B, E, crate::__types::ChatCompletionDeleted>,
884        fn(
885            http::Response<B>,
886        ) -> crate::__combinators::Json<B, E, crate::__types::ChatCompletionDeleted>,
887    >,
888    crate::__types::ChatCompletionDeleted
889);
890#[doc = "Get chat messages"]
891pub fn get_chat_completion_messages<C, Fut, B, E>(
892    client: C,
893    params: &crate::__types::get_chat_completion_messages::Params,
894) -> GetChatCompletionMessages<Fut, B, E>
895where
896    C: FnOnce(http::Request<String>) -> Fut,
897    Fut: Future<Output = Result<http::Response<B>, E>>,
898    B: http_body::Body,
899{
900    GetChatCompletionMessages(futures::TryFutureExt::and_then(
901        crate::__combinators::Send::new(
902            client,
903            || {
904                let path = {
905                    #[serde_with::serde_as]
906                    #[derive(serde :: Serialize)]
907                    struct Query<'a> {
908                        #[serde(rename = "after")]
909                        #[serde(skip_serializing_if = "Option::is_none")]
910                        after: &'a Option<String>,
911                        #[serde(rename = "limit")]
912                        #[serde(skip_serializing_if = "Option::is_none")]
913                        limit: &'a Option<i64>,
914                        #[serde(rename = "order")]
915                        #[serde(skip_serializing_if = "Option::is_none")]
916                        order:
917                            &'a Option<crate::__types::get_chat_completion_messages::params::Order>,
918                        #[serde(skip_serializing)]
919                        _phantom: std::marker::PhantomData<&'a ()>,
920                    }
921                    let crate::__types::get_chat_completion_messages::Params {
922                        completion_id,
923                        after,
924                        limit,
925                        order,
926                    } = params;
927                    #[allow(clippy::useless_format)]
928                    let mut path = format!("/chat/completions/{completion_id}/messages");
929                    let query = serde_urlencoded::to_string(Query {
930                        after,
931                        limit,
932                        order,
933                        _phantom: std::marker::PhantomData,
934                    })?;
935                    if !query.is_empty() {
936                        path.push('?');
937                        path.push_str(&query);
938                    }
939                    path
940                };
941                let body = String::new();
942                Ok(http::Request::builder()
943                    .method(http::Method::GET)
944                    .uri(path)
945                    .header(http::header::CONTENT_LENGTH, body.len())
946                    .body(body)?)
947            },
948            (
949                http::StatusCode::from_u16(200u16).unwrap(),
950                Some(mime::APPLICATION_JSON),
951            ),
952        ),
953        crate::__combinators::Json::new,
954    ))
955}
956future!(
957    GetChatCompletionMessages,
958    futures::future::AndThen<
959        crate::__combinators::Send<Fut, B, E>,
960        crate::__combinators::Json<B, E, crate::__types::ChatCompletionMessageList>,
961        fn(
962            http::Response<B>,
963        ) -> crate::__combinators::Json<B, E, crate::__types::ChatCompletionMessageList>,
964    >,
965    crate::__types::ChatCompletionMessageList
966);
967#[doc = "Create completion"]
968pub fn create_completion<C, Fut, B, E>(
969    client: C,
970    request: &crate::__types::CreateCompletionRequest,
971) -> CreateCompletion<Fut, B, E>
972where
973    C: FnOnce(http::Request<String>) -> Fut,
974    Fut: Future<Output = Result<http::Response<B>, E>>,
975    B: http_body::Body,
976{
977    CreateCompletion(futures::TryFutureExt::and_then(
978        crate::__combinators::Send::new(
979            client,
980            || {
981                let path = "/completions";
982                let body = serde_json::to_string(request)?;
983                Ok(http::Request::builder()
984                    .method(http::Method::POST)
985                    .uri(path)
986                    .header(http::header::CONTENT_LENGTH, body.len())
987                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
988                    .body(body)?)
989            },
990            (
991                http::StatusCode::from_u16(200u16).unwrap(),
992                Some(mime::APPLICATION_JSON),
993            ),
994        ),
995        crate::__combinators::Json::new,
996    ))
997}
998future!(
999    CreateCompletion,
1000    futures::future::AndThen<
1001        crate::__combinators::Send<Fut, B, E>,
1002        crate::__combinators::Json<B, E, crate::__types::CreateCompletionResponse>,
1003        fn(
1004            http::Response<B>,
1005        ) -> crate::__combinators::Json<B, E, crate::__types::CreateCompletionResponse>,
1006    >,
1007    crate::__types::CreateCompletionResponse
1008);
1009#[doc = "List containers"]
1010pub fn list_containers<C, Fut, B, E>(
1011    client: C,
1012    params: &crate::__types::list_containers::Params,
1013) -> ListContainers<Fut, B, E>
1014where
1015    C: FnOnce(http::Request<String>) -> Fut,
1016    Fut: Future<Output = Result<http::Response<B>, E>>,
1017    B: http_body::Body,
1018{
1019    ListContainers(futures::TryFutureExt::and_then(
1020        crate::__combinators::Send::new(
1021            client,
1022            || {
1023                let path = {
1024                    #[serde_with::serde_as]
1025                    #[derive(serde :: Serialize)]
1026                    struct Query<'a> {
1027                        #[serde(rename = "limit")]
1028                        #[serde(skip_serializing_if = "Option::is_none")]
1029                        limit: &'a Option<i64>,
1030                        #[serde(rename = "order")]
1031                        #[serde(skip_serializing_if = "Option::is_none")]
1032                        order: &'a Option<crate::__types::list_containers::params::Order>,
1033                        #[serde(rename = "after")]
1034                        #[serde(skip_serializing_if = "Option::is_none")]
1035                        after: &'a Option<String>,
1036                        #[serde(skip_serializing)]
1037                        _phantom: std::marker::PhantomData<&'a ()>,
1038                    }
1039                    let crate::__types::list_containers::Params {
1040                        limit,
1041                        order,
1042                        after,
1043                    } = params;
1044                    #[allow(clippy::useless_format)]
1045                    let mut path = format!("/containers");
1046                    let query = serde_urlencoded::to_string(Query {
1047                        limit,
1048                        order,
1049                        after,
1050                        _phantom: std::marker::PhantomData,
1051                    })?;
1052                    if !query.is_empty() {
1053                        path.push('?');
1054                        path.push_str(&query);
1055                    }
1056                    path
1057                };
1058                let body = String::new();
1059                Ok(http::Request::builder()
1060                    .method(http::Method::GET)
1061                    .uri(path)
1062                    .header(http::header::CONTENT_LENGTH, body.len())
1063                    .body(body)?)
1064            },
1065            (
1066                http::StatusCode::from_u16(200u16).unwrap(),
1067                Some(mime::APPLICATION_JSON),
1068            ),
1069        ),
1070        crate::__combinators::Json::new,
1071    ))
1072}
1073future!(
1074    ListContainers,
1075    futures::future::AndThen<
1076        crate::__combinators::Send<Fut, B, E>,
1077        crate::__combinators::Json<B, E, crate::__types::ContainerListResource>,
1078        fn(
1079            http::Response<B>,
1080        ) -> crate::__combinators::Json<B, E, crate::__types::ContainerListResource>,
1081    >,
1082    crate::__types::ContainerListResource
1083);
1084#[doc = "Retrieve container"]
1085pub fn retrieve_container<C, Fut, B, E>(
1086    client: C,
1087    params: &crate::__types::retrieve_container::Params,
1088) -> RetrieveContainer<Fut, B, E>
1089where
1090    C: FnOnce(http::Request<String>) -> Fut,
1091    Fut: Future<Output = Result<http::Response<B>, E>>,
1092    B: http_body::Body,
1093{
1094    RetrieveContainer(futures::TryFutureExt::and_then(
1095        crate::__combinators::Send::new(
1096            client,
1097            || {
1098                let path = {
1099                    #[serde_with::serde_as]
1100                    #[derive(serde :: Serialize)]
1101                    struct Query<'a> {
1102                        #[serde(skip_serializing)]
1103                        _phantom: std::marker::PhantomData<&'a ()>,
1104                    }
1105                    let crate::__types::retrieve_container::Params { container_id } = params;
1106                    #[allow(clippy::useless_format)]
1107                    let mut path = format!("/containers/{container_id}");
1108                    let query = serde_urlencoded::to_string(Query {
1109                        _phantom: std::marker::PhantomData,
1110                    })?;
1111                    if !query.is_empty() {
1112                        path.push('?');
1113                        path.push_str(&query);
1114                    }
1115                    path
1116                };
1117                let body = String::new();
1118                Ok(http::Request::builder()
1119                    .method(http::Method::GET)
1120                    .uri(path)
1121                    .header(http::header::CONTENT_LENGTH, body.len())
1122                    .body(body)?)
1123            },
1124            (
1125                http::StatusCode::from_u16(200u16).unwrap(),
1126                Some(mime::APPLICATION_JSON),
1127            ),
1128        ),
1129        crate::__combinators::Json::new,
1130    ))
1131}
1132future!(
1133    RetrieveContainer,
1134    futures::future::AndThen<
1135        crate::__combinators::Send<Fut, B, E>,
1136        crate::__combinators::Json<B, E, crate::__types::ContainerResource>,
1137        fn(
1138            http::Response<B>,
1139        ) -> crate::__combinators::Json<B, E, crate::__types::ContainerResource>,
1140    >,
1141    crate::__types::ContainerResource
1142);
1143#[doc = "Delete a container"]
1144pub fn delete_container<C, Fut, B, E>(
1145    client: C,
1146    params: &crate::__types::delete_container::Params,
1147) -> DeleteContainer<Fut, B, E>
1148where
1149    C: FnOnce(http::Request<String>) -> Fut,
1150    Fut: Future<Output = Result<http::Response<B>, E>>,
1151    B: http_body::Body,
1152{
1153    DeleteContainer(futures::TryFutureExt::map_ok(
1154        crate::__combinators::Send::new(
1155            client,
1156            || {
1157                let path = {
1158                    #[serde_with::serde_as]
1159                    #[derive(serde :: Serialize)]
1160                    struct Query<'a> {
1161                        #[serde(skip_serializing)]
1162                        _phantom: std::marker::PhantomData<&'a ()>,
1163                    }
1164                    let crate::__types::delete_container::Params { container_id } = params;
1165                    #[allow(clippy::useless_format)]
1166                    let mut path = format!("/containers/{container_id}");
1167                    let query = serde_urlencoded::to_string(Query {
1168                        _phantom: std::marker::PhantomData,
1169                    })?;
1170                    if !query.is_empty() {
1171                        path.push('?');
1172                        path.push_str(&query);
1173                    }
1174                    path
1175                };
1176                let body = String::new();
1177                Ok(http::Request::builder()
1178                    .method(http::Method::DELETE)
1179                    .uri(path)
1180                    .header(http::header::CONTENT_LENGTH, body.len())
1181                    .body(body)?)
1182            },
1183            (http::StatusCode::from_u16(200u16).unwrap(), None),
1184        ),
1185        |_| (),
1186    ))
1187}
1188future!(
1189    DeleteContainer,
1190    futures::future::MapOk<crate::__combinators::Send<Fut, B, E>, fn(http::Response<B>) -> ()>,
1191    ()
1192);
1193#[doc = "List container files"]
1194pub fn list_container_files<C, Fut, B, E>(
1195    client: C,
1196    params: &crate::__types::list_container_files::Params,
1197) -> ListContainerFiles<Fut, B, E>
1198where
1199    C: FnOnce(http::Request<String>) -> Fut,
1200    Fut: Future<Output = Result<http::Response<B>, E>>,
1201    B: http_body::Body,
1202{
1203    ListContainerFiles(futures::TryFutureExt::and_then(
1204        crate::__combinators::Send::new(
1205            client,
1206            || {
1207                let path = {
1208                    #[serde_with::serde_as]
1209                    #[derive(serde :: Serialize)]
1210                    struct Query<'a> {
1211                        #[serde(rename = "limit")]
1212                        #[serde(skip_serializing_if = "Option::is_none")]
1213                        limit: &'a Option<i64>,
1214                        #[serde(rename = "order")]
1215                        #[serde(skip_serializing_if = "Option::is_none")]
1216                        order: &'a Option<crate::__types::list_container_files::params::Order>,
1217                        #[serde(rename = "after")]
1218                        #[serde(skip_serializing_if = "Option::is_none")]
1219                        after: &'a Option<String>,
1220                        #[serde(skip_serializing)]
1221                        _phantom: std::marker::PhantomData<&'a ()>,
1222                    }
1223                    let crate::__types::list_container_files::Params {
1224                        container_id,
1225                        limit,
1226                        order,
1227                        after,
1228                    } = params;
1229                    #[allow(clippy::useless_format)]
1230                    let mut path = format!("/containers/{container_id}/files");
1231                    let query = serde_urlencoded::to_string(Query {
1232                        limit,
1233                        order,
1234                        after,
1235                        _phantom: std::marker::PhantomData,
1236                    })?;
1237                    if !query.is_empty() {
1238                        path.push('?');
1239                        path.push_str(&query);
1240                    }
1241                    path
1242                };
1243                let body = String::new();
1244                Ok(http::Request::builder()
1245                    .method(http::Method::GET)
1246                    .uri(path)
1247                    .header(http::header::CONTENT_LENGTH, body.len())
1248                    .body(body)?)
1249            },
1250            (
1251                http::StatusCode::from_u16(200u16).unwrap(),
1252                Some(mime::APPLICATION_JSON),
1253            ),
1254        ),
1255        crate::__combinators::Json::new,
1256    ))
1257}
1258future!(
1259    ListContainerFiles,
1260    futures::future::AndThen<
1261        crate::__combinators::Send<Fut, B, E>,
1262        crate::__combinators::Json<B, E, crate::__types::ContainerFileListResource>,
1263        fn(
1264            http::Response<B>,
1265        ) -> crate::__combinators::Json<B, E, crate::__types::ContainerFileListResource>,
1266    >,
1267    crate::__types::ContainerFileListResource
1268);
1269#[doc = "Retrieve container file"]
1270pub fn retrieve_container_file<C, Fut, B, E>(
1271    client: C,
1272    params: &crate::__types::retrieve_container_file::Params,
1273) -> RetrieveContainerFile<Fut, B, E>
1274where
1275    C: FnOnce(http::Request<String>) -> Fut,
1276    Fut: Future<Output = Result<http::Response<B>, E>>,
1277    B: http_body::Body,
1278{
1279    RetrieveContainerFile(futures::TryFutureExt::and_then(
1280        crate::__combinators::Send::new(
1281            client,
1282            || {
1283                let path = {
1284                    #[serde_with::serde_as]
1285                    #[derive(serde :: Serialize)]
1286                    struct Query<'a> {
1287                        #[serde(skip_serializing)]
1288                        _phantom: std::marker::PhantomData<&'a ()>,
1289                    }
1290                    let crate::__types::retrieve_container_file::Params {
1291                        container_id,
1292                        file_id,
1293                    } = params;
1294                    #[allow(clippy::useless_format)]
1295                    let mut path = format!("/containers/{container_id}/files/{file_id}");
1296                    let query = serde_urlencoded::to_string(Query {
1297                        _phantom: std::marker::PhantomData,
1298                    })?;
1299                    if !query.is_empty() {
1300                        path.push('?');
1301                        path.push_str(&query);
1302                    }
1303                    path
1304                };
1305                let body = String::new();
1306                Ok(http::Request::builder()
1307                    .method(http::Method::GET)
1308                    .uri(path)
1309                    .header(http::header::CONTENT_LENGTH, body.len())
1310                    .body(body)?)
1311            },
1312            (
1313                http::StatusCode::from_u16(200u16).unwrap(),
1314                Some(mime::APPLICATION_JSON),
1315            ),
1316        ),
1317        crate::__combinators::Json::new,
1318    ))
1319}
1320future!(
1321    RetrieveContainerFile,
1322    futures::future::AndThen<
1323        crate::__combinators::Send<Fut, B, E>,
1324        crate::__combinators::Json<B, E, crate::__types::ContainerFileResource>,
1325        fn(
1326            http::Response<B>,
1327        ) -> crate::__combinators::Json<B, E, crate::__types::ContainerFileResource>,
1328    >,
1329    crate::__types::ContainerFileResource
1330);
1331#[doc = "Delete a container file"]
1332pub fn delete_container_file<C, Fut, B, E>(
1333    client: C,
1334    params: &crate::__types::delete_container_file::Params,
1335) -> DeleteContainerFile<Fut, B, E>
1336where
1337    C: FnOnce(http::Request<String>) -> Fut,
1338    Fut: Future<Output = Result<http::Response<B>, E>>,
1339    B: http_body::Body,
1340{
1341    DeleteContainerFile(futures::TryFutureExt::map_ok(
1342        crate::__combinators::Send::new(
1343            client,
1344            || {
1345                let path = {
1346                    #[serde_with::serde_as]
1347                    #[derive(serde :: Serialize)]
1348                    struct Query<'a> {
1349                        #[serde(skip_serializing)]
1350                        _phantom: std::marker::PhantomData<&'a ()>,
1351                    }
1352                    let crate::__types::delete_container_file::Params {
1353                        container_id,
1354                        file_id,
1355                    } = params;
1356                    #[allow(clippy::useless_format)]
1357                    let mut path = format!("/containers/{container_id}/files/{file_id}");
1358                    let query = serde_urlencoded::to_string(Query {
1359                        _phantom: std::marker::PhantomData,
1360                    })?;
1361                    if !query.is_empty() {
1362                        path.push('?');
1363                        path.push_str(&query);
1364                    }
1365                    path
1366                };
1367                let body = String::new();
1368                Ok(http::Request::builder()
1369                    .method(http::Method::DELETE)
1370                    .uri(path)
1371                    .header(http::header::CONTENT_LENGTH, body.len())
1372                    .body(body)?)
1373            },
1374            (http::StatusCode::from_u16(200u16).unwrap(), None),
1375        ),
1376        |_| (),
1377    ))
1378}
1379future!(
1380    DeleteContainerFile,
1381    futures::future::MapOk<crate::__combinators::Send<Fut, B, E>, fn(http::Response<B>) -> ()>,
1382    ()
1383);
1384#[doc = "Retrieve container file content"]
1385pub fn retrieve_container_file_content<C, Fut, B, E>(
1386    client: C,
1387    params: &crate::__types::retrieve_container_file_content::Params,
1388) -> RetrieveContainerFileContent<Fut, B, E>
1389where
1390    C: FnOnce(http::Request<String>) -> Fut,
1391    Fut: Future<Output = Result<http::Response<B>, E>>,
1392    B: http_body::Body,
1393{
1394    RetrieveContainerFileContent(futures::TryFutureExt::map_ok(
1395        crate::__combinators::Send::new(
1396            client,
1397            || {
1398                let path = {
1399                    #[serde_with::serde_as]
1400                    #[derive(serde :: Serialize)]
1401                    struct Query<'a> {
1402                        #[serde(skip_serializing)]
1403                        _phantom: std::marker::PhantomData<&'a ()>,
1404                    }
1405                    let crate::__types::retrieve_container_file_content::Params {
1406                        container_id,
1407                        file_id,
1408                    } = params;
1409                    #[allow(clippy::useless_format)]
1410                    let mut path = format!("/containers/{container_id}/files/{file_id}/content");
1411                    let query = serde_urlencoded::to_string(Query {
1412                        _phantom: std::marker::PhantomData,
1413                    })?;
1414                    if !query.is_empty() {
1415                        path.push('?');
1416                        path.push_str(&query);
1417                    }
1418                    path
1419                };
1420                let body = String::new();
1421                Ok(http::Request::builder()
1422                    .method(http::Method::GET)
1423                    .uri(path)
1424                    .header(http::header::CONTENT_LENGTH, body.len())
1425                    .body(body)?)
1426            },
1427            (http::StatusCode::from_u16(200u16).unwrap(), None),
1428        ),
1429        http::Response::into_body,
1430    ))
1431}
1432future!(
1433    RetrieveContainerFileContent,
1434    futures::future::MapOk<crate::__combinators::Send<Fut, B, E>, fn(http::Response<B>) -> B>,
1435    B
1436);
1437#[doc = "Create a conversation"]
1438pub fn create_conversation<C, Fut, B, E>(
1439    client: C,
1440    request: &crate::__types::CreateConversationRequest,
1441) -> CreateConversation<Fut, B, E>
1442where
1443    C: FnOnce(http::Request<String>) -> Fut,
1444    Fut: Future<Output = Result<http::Response<B>, E>>,
1445    B: http_body::Body,
1446{
1447    CreateConversation(futures::TryFutureExt::and_then(
1448        crate::__combinators::Send::new(
1449            client,
1450            || {
1451                let path = "/conversations";
1452                let body = serde_json::to_string(request)?;
1453                Ok(http::Request::builder()
1454                    .method(http::Method::POST)
1455                    .uri(path)
1456                    .header(http::header::CONTENT_LENGTH, body.len())
1457                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
1458                    .body(body)?)
1459            },
1460            (
1461                http::StatusCode::from_u16(200u16).unwrap(),
1462                Some(mime::APPLICATION_JSON),
1463            ),
1464        ),
1465        crate::__combinators::Json::new,
1466    ))
1467}
1468future!(
1469    CreateConversation,
1470    futures::future::AndThen<
1471        crate::__combinators::Send<Fut, B, E>,
1472        crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1473        fn(
1474            http::Response<B>,
1475        ) -> crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1476    >,
1477    crate::__types::ConversationResource
1478);
1479#[doc = "Retrieve a conversation"]
1480pub fn get_conversation<C, Fut, B, E>(
1481    client: C,
1482    params: &crate::__types::get_conversation::Params,
1483) -> GetConversation<Fut, B, E>
1484where
1485    C: FnOnce(http::Request<String>) -> Fut,
1486    Fut: Future<Output = Result<http::Response<B>, E>>,
1487    B: http_body::Body,
1488{
1489    GetConversation(futures::TryFutureExt::and_then(
1490        crate::__combinators::Send::new(
1491            client,
1492            || {
1493                let path = {
1494                    #[serde_with::serde_as]
1495                    #[derive(serde :: Serialize)]
1496                    struct Query<'a> {
1497                        #[serde(skip_serializing)]
1498                        _phantom: std::marker::PhantomData<&'a ()>,
1499                    }
1500                    let crate::__types::get_conversation::Params { conversation_id } = params;
1501                    #[allow(clippy::useless_format)]
1502                    let mut path = format!("/conversations/{conversation_id}");
1503                    let query = serde_urlencoded::to_string(Query {
1504                        _phantom: std::marker::PhantomData,
1505                    })?;
1506                    if !query.is_empty() {
1507                        path.push('?');
1508                        path.push_str(&query);
1509                    }
1510                    path
1511                };
1512                let body = String::new();
1513                Ok(http::Request::builder()
1514                    .method(http::Method::GET)
1515                    .uri(path)
1516                    .header(http::header::CONTENT_LENGTH, body.len())
1517                    .body(body)?)
1518            },
1519            (
1520                http::StatusCode::from_u16(200u16).unwrap(),
1521                Some(mime::APPLICATION_JSON),
1522            ),
1523        ),
1524        crate::__combinators::Json::new,
1525    ))
1526}
1527future!(
1528    GetConversation,
1529    futures::future::AndThen<
1530        crate::__combinators::Send<Fut, B, E>,
1531        crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1532        fn(
1533            http::Response<B>,
1534        ) -> crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1535    >,
1536    crate::__types::ConversationResource
1537);
1538#[doc = "Update a conversation"]
1539pub fn update_conversation<C, Fut, B, E>(
1540    client: C,
1541    params: &crate::__types::update_conversation::Params,
1542    request: &crate::__types::UpdateConversationBody,
1543) -> UpdateConversation<Fut, B, E>
1544where
1545    C: FnOnce(http::Request<String>) -> Fut,
1546    Fut: Future<Output = Result<http::Response<B>, E>>,
1547    B: http_body::Body,
1548{
1549    UpdateConversation(futures::TryFutureExt::and_then(
1550        crate::__combinators::Send::new(
1551            client,
1552            || {
1553                let path = {
1554                    #[serde_with::serde_as]
1555                    #[derive(serde :: Serialize)]
1556                    struct Query<'a> {
1557                        #[serde(skip_serializing)]
1558                        _phantom: std::marker::PhantomData<&'a ()>,
1559                    }
1560                    let crate::__types::update_conversation::Params { conversation_id } = params;
1561                    #[allow(clippy::useless_format)]
1562                    let mut path = format!("/conversations/{conversation_id}");
1563                    let query = serde_urlencoded::to_string(Query {
1564                        _phantom: std::marker::PhantomData,
1565                    })?;
1566                    if !query.is_empty() {
1567                        path.push('?');
1568                        path.push_str(&query);
1569                    }
1570                    path
1571                };
1572                let body = serde_json::to_string(request)?;
1573                Ok(http::Request::builder()
1574                    .method(http::Method::POST)
1575                    .uri(path)
1576                    .header(http::header::CONTENT_LENGTH, body.len())
1577                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
1578                    .body(body)?)
1579            },
1580            (
1581                http::StatusCode::from_u16(200u16).unwrap(),
1582                Some(mime::APPLICATION_JSON),
1583            ),
1584        ),
1585        crate::__combinators::Json::new,
1586    ))
1587}
1588future!(
1589    UpdateConversation,
1590    futures::future::AndThen<
1591        crate::__combinators::Send<Fut, B, E>,
1592        crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1593        fn(
1594            http::Response<B>,
1595        ) -> crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1596    >,
1597    crate::__types::ConversationResource
1598);
1599#[doc = "Delete a conversation"]
1600pub fn delete_conversation<C, Fut, B, E>(
1601    client: C,
1602    params: &crate::__types::delete_conversation::Params,
1603) -> DeleteConversation<Fut, B, E>
1604where
1605    C: FnOnce(http::Request<String>) -> Fut,
1606    Fut: Future<Output = Result<http::Response<B>, E>>,
1607    B: http_body::Body,
1608{
1609    DeleteConversation(futures::TryFutureExt::and_then(
1610        crate::__combinators::Send::new(
1611            client,
1612            || {
1613                let path = {
1614                    #[serde_with::serde_as]
1615                    #[derive(serde :: Serialize)]
1616                    struct Query<'a> {
1617                        #[serde(skip_serializing)]
1618                        _phantom: std::marker::PhantomData<&'a ()>,
1619                    }
1620                    let crate::__types::delete_conversation::Params { conversation_id } = params;
1621                    #[allow(clippy::useless_format)]
1622                    let mut path = format!("/conversations/{conversation_id}");
1623                    let query = serde_urlencoded::to_string(Query {
1624                        _phantom: std::marker::PhantomData,
1625                    })?;
1626                    if !query.is_empty() {
1627                        path.push('?');
1628                        path.push_str(&query);
1629                    }
1630                    path
1631                };
1632                let body = String::new();
1633                Ok(http::Request::builder()
1634                    .method(http::Method::DELETE)
1635                    .uri(path)
1636                    .header(http::header::CONTENT_LENGTH, body.len())
1637                    .body(body)?)
1638            },
1639            (
1640                http::StatusCode::from_u16(200u16).unwrap(),
1641                Some(mime::APPLICATION_JSON),
1642            ),
1643        ),
1644        crate::__combinators::Json::new,
1645    ))
1646}
1647future!(
1648    DeleteConversation,
1649    futures::future::AndThen<
1650        crate::__combinators::Send<Fut, B, E>,
1651        crate::__combinators::Json<B, E, crate::__types::DeletedConversationResource>,
1652        fn(
1653            http::Response<B>,
1654        )
1655            -> crate::__combinators::Json<B, E, crate::__types::DeletedConversationResource>,
1656    >,
1657    crate::__types::DeletedConversationResource
1658);
1659#[doc = "Create items"]
1660pub fn create_conversation_items<C, Fut, B, E>(
1661    client: C,
1662    params: &crate::__types::create_conversation_items::Params,
1663    request: &crate::__types::create_conversation_items::Request,
1664) -> CreateConversationItems<Fut, B, E>
1665where
1666    C: FnOnce(http::Request<String>) -> Fut,
1667    Fut: Future<Output = Result<http::Response<B>, E>>,
1668    B: http_body::Body,
1669{
1670    CreateConversationItems(futures::TryFutureExt::and_then(
1671        crate::__combinators::Send::new(
1672            client,
1673            || {
1674                let path = {
1675                    #[serde_with::serde_as]
1676                    #[derive(serde :: Serialize)]
1677                    struct Query<'a> {
1678                        #[serde(rename = "include")]
1679                        #[serde(skip_serializing_if = "Option::is_none")]
1680                        include: &'a Option<Vec<crate::__types::Includable>>,
1681                        #[serde(skip_serializing)]
1682                        _phantom: std::marker::PhantomData<&'a ()>,
1683                    }
1684                    let crate::__types::create_conversation_items::Params {
1685                        conversation_id,
1686                        include,
1687                    } = params;
1688                    #[allow(clippy::useless_format)]
1689                    let mut path = format!("/conversations/{conversation_id}/items");
1690                    let query = serde_urlencoded::to_string(Query {
1691                        include,
1692                        _phantom: std::marker::PhantomData,
1693                    })?;
1694                    if !query.is_empty() {
1695                        path.push('?');
1696                        path.push_str(&query);
1697                    }
1698                    path
1699                };
1700                let body = serde_json::to_string(request)?;
1701                Ok(http::Request::builder()
1702                    .method(http::Method::POST)
1703                    .uri(path)
1704                    .header(http::header::CONTENT_LENGTH, body.len())
1705                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
1706                    .body(body)?)
1707            },
1708            (
1709                http::StatusCode::from_u16(200u16).unwrap(),
1710                Some(mime::APPLICATION_JSON),
1711            ),
1712        ),
1713        crate::__combinators::Json::new,
1714    ))
1715}
1716future!(
1717    CreateConversationItems,
1718    futures::future::AndThen<
1719        crate::__combinators::Send<Fut, B, E>,
1720        crate::__combinators::Json<B, E, crate::__types::ConversationItemList>,
1721        fn(
1722            http::Response<B>,
1723        ) -> crate::__combinators::Json<B, E, crate::__types::ConversationItemList>,
1724    >,
1725    crate::__types::ConversationItemList
1726);
1727#[doc = "List items"]
1728pub fn list_conversation_items<C, Fut, B, E>(
1729    client: C,
1730    params: &crate::__types::list_conversation_items::Params,
1731) -> ListConversationItems<Fut, B, E>
1732where
1733    C: FnOnce(http::Request<String>) -> Fut,
1734    Fut: Future<Output = Result<http::Response<B>, E>>,
1735    B: http_body::Body,
1736{
1737    ListConversationItems(futures::TryFutureExt::and_then(
1738        crate::__combinators::Send::new(
1739            client,
1740            || {
1741                let path = {
1742                    #[serde_with::serde_as]
1743                    #[derive(serde :: Serialize)]
1744                    struct Query<'a> {
1745                        #[serde(rename = "limit")]
1746                        #[serde(skip_serializing_if = "Option::is_none")]
1747                        limit: &'a Option<i64>,
1748                        #[serde(rename = "order")]
1749                        #[serde(skip_serializing_if = "Option::is_none")]
1750                        order: &'a Option<crate::__types::list_conversation_items::params::Order>,
1751                        #[serde(rename = "after")]
1752                        #[serde(skip_serializing_if = "Option::is_none")]
1753                        after: &'a Option<String>,
1754                        #[serde(rename = "include")]
1755                        #[serde(skip_serializing_if = "Option::is_none")]
1756                        include: &'a Option<Vec<crate::__types::Includable>>,
1757                        #[serde(skip_serializing)]
1758                        _phantom: std::marker::PhantomData<&'a ()>,
1759                    }
1760                    let crate::__types::list_conversation_items::Params {
1761                        conversation_id,
1762                        limit,
1763                        order,
1764                        after,
1765                        include,
1766                    } = params;
1767                    #[allow(clippy::useless_format)]
1768                    let mut path = format!("/conversations/{conversation_id}/items");
1769                    let query = serde_urlencoded::to_string(Query {
1770                        limit,
1771                        order,
1772                        after,
1773                        include,
1774                        _phantom: std::marker::PhantomData,
1775                    })?;
1776                    if !query.is_empty() {
1777                        path.push('?');
1778                        path.push_str(&query);
1779                    }
1780                    path
1781                };
1782                let body = String::new();
1783                Ok(http::Request::builder()
1784                    .method(http::Method::GET)
1785                    .uri(path)
1786                    .header(http::header::CONTENT_LENGTH, body.len())
1787                    .body(body)?)
1788            },
1789            (
1790                http::StatusCode::from_u16(200u16).unwrap(),
1791                Some(mime::APPLICATION_JSON),
1792            ),
1793        ),
1794        crate::__combinators::Json::new,
1795    ))
1796}
1797future!(
1798    ListConversationItems,
1799    futures::future::AndThen<
1800        crate::__combinators::Send<Fut, B, E>,
1801        crate::__combinators::Json<B, E, crate::__types::ConversationItemList>,
1802        fn(
1803            http::Response<B>,
1804        ) -> crate::__combinators::Json<B, E, crate::__types::ConversationItemList>,
1805    >,
1806    crate::__types::ConversationItemList
1807);
1808#[doc = "Retrieve an item"]
1809pub fn get_conversation_item<C, Fut, B, E>(
1810    client: C,
1811    params: &crate::__types::get_conversation_item::Params,
1812) -> GetConversationItem<Fut, B, E>
1813where
1814    C: FnOnce(http::Request<String>) -> Fut,
1815    Fut: Future<Output = Result<http::Response<B>, E>>,
1816    B: http_body::Body,
1817{
1818    GetConversationItem(futures::TryFutureExt::and_then(
1819        crate::__combinators::Send::new(
1820            client,
1821            || {
1822                let path = {
1823                    #[serde_with::serde_as]
1824                    #[derive(serde :: Serialize)]
1825                    struct Query<'a> {
1826                        #[serde(rename = "include")]
1827                        #[serde(skip_serializing_if = "Option::is_none")]
1828                        include: &'a Option<Vec<crate::__types::Includable>>,
1829                        #[serde(skip_serializing)]
1830                        _phantom: std::marker::PhantomData<&'a ()>,
1831                    }
1832                    let crate::__types::get_conversation_item::Params {
1833                        conversation_id,
1834                        item_id,
1835                        include,
1836                    } = params;
1837                    #[allow(clippy::useless_format)]
1838                    let mut path = format!("/conversations/{conversation_id}/items/{item_id}");
1839                    let query = serde_urlencoded::to_string(Query {
1840                        include,
1841                        _phantom: std::marker::PhantomData,
1842                    })?;
1843                    if !query.is_empty() {
1844                        path.push('?');
1845                        path.push_str(&query);
1846                    }
1847                    path
1848                };
1849                let body = String::new();
1850                Ok(http::Request::builder()
1851                    .method(http::Method::GET)
1852                    .uri(path)
1853                    .header(http::header::CONTENT_LENGTH, body.len())
1854                    .body(body)?)
1855            },
1856            (
1857                http::StatusCode::from_u16(200u16).unwrap(),
1858                Some(mime::APPLICATION_JSON),
1859            ),
1860        ),
1861        crate::__combinators::Json::new,
1862    ))
1863}
1864future!(
1865    GetConversationItem,
1866    futures::future::AndThen<
1867        crate::__combinators::Send<Fut, B, E>,
1868        crate::__combinators::Json<B, E, crate::__types::ConversationItem>,
1869        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ConversationItem>,
1870    >,
1871    crate::__types::ConversationItem
1872);
1873#[doc = "Delete an item"]
1874pub fn delete_conversation_item<C, Fut, B, E>(
1875    client: C,
1876    params: &crate::__types::delete_conversation_item::Params,
1877) -> DeleteConversationItem<Fut, B, E>
1878where
1879    C: FnOnce(http::Request<String>) -> Fut,
1880    Fut: Future<Output = Result<http::Response<B>, E>>,
1881    B: http_body::Body,
1882{
1883    DeleteConversationItem(futures::TryFutureExt::and_then(
1884        crate::__combinators::Send::new(
1885            client,
1886            || {
1887                let path = {
1888                    #[serde_with::serde_as]
1889                    #[derive(serde :: Serialize)]
1890                    struct Query<'a> {
1891                        #[serde(skip_serializing)]
1892                        _phantom: std::marker::PhantomData<&'a ()>,
1893                    }
1894                    let crate::__types::delete_conversation_item::Params {
1895                        conversation_id,
1896                        item_id,
1897                    } = params;
1898                    #[allow(clippy::useless_format)]
1899                    let mut path = format!("/conversations/{conversation_id}/items/{item_id}");
1900                    let query = serde_urlencoded::to_string(Query {
1901                        _phantom: std::marker::PhantomData,
1902                    })?;
1903                    if !query.is_empty() {
1904                        path.push('?');
1905                        path.push_str(&query);
1906                    }
1907                    path
1908                };
1909                let body = String::new();
1910                Ok(http::Request::builder()
1911                    .method(http::Method::DELETE)
1912                    .uri(path)
1913                    .header(http::header::CONTENT_LENGTH, body.len())
1914                    .body(body)?)
1915            },
1916            (
1917                http::StatusCode::from_u16(200u16).unwrap(),
1918                Some(mime::APPLICATION_JSON),
1919            ),
1920        ),
1921        crate::__combinators::Json::new,
1922    ))
1923}
1924future!(
1925    DeleteConversationItem,
1926    futures::future::AndThen<
1927        crate::__combinators::Send<Fut, B, E>,
1928        crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1929        fn(
1930            http::Response<B>,
1931        ) -> crate::__combinators::Json<B, E, crate::__types::ConversationResource>,
1932    >,
1933    crate::__types::ConversationResource
1934);
1935#[doc = "Create embeddings"]
1936pub fn create_embedding<C, Fut, B, E>(
1937    client: C,
1938    request: &crate::__types::CreateEmbeddingRequest,
1939) -> CreateEmbedding<Fut, B, E>
1940where
1941    C: FnOnce(http::Request<String>) -> Fut,
1942    Fut: Future<Output = Result<http::Response<B>, E>>,
1943    B: http_body::Body,
1944{
1945    CreateEmbedding(futures::TryFutureExt::and_then(
1946        crate::__combinators::Send::new(
1947            client,
1948            || {
1949                let path = "/embeddings";
1950                let body = serde_json::to_string(request)?;
1951                Ok(http::Request::builder()
1952                    .method(http::Method::POST)
1953                    .uri(path)
1954                    .header(http::header::CONTENT_LENGTH, body.len())
1955                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
1956                    .body(body)?)
1957            },
1958            (
1959                http::StatusCode::from_u16(200u16).unwrap(),
1960                Some(mime::APPLICATION_JSON),
1961            ),
1962        ),
1963        crate::__combinators::Json::new,
1964    ))
1965}
1966future!(
1967    CreateEmbedding,
1968    futures::future::AndThen<
1969        crate::__combinators::Send<Fut, B, E>,
1970        crate::__combinators::Json<B, E, crate::__types::CreateEmbeddingResponse>,
1971        fn(
1972            http::Response<B>,
1973        ) -> crate::__combinators::Json<B, E, crate::__types::CreateEmbeddingResponse>,
1974    >,
1975    crate::__types::CreateEmbeddingResponse
1976);
1977#[doc = "List evals"]
1978pub fn list_evals<C, Fut, B, E>(
1979    client: C,
1980    params: &crate::__types::list_evals::Params,
1981) -> ListEvals<Fut, B, E>
1982where
1983    C: FnOnce(http::Request<String>) -> Fut,
1984    Fut: Future<Output = Result<http::Response<B>, E>>,
1985    B: http_body::Body,
1986{
1987    ListEvals(futures::TryFutureExt::and_then(
1988        crate::__combinators::Send::new(
1989            client,
1990            || {
1991                let path = {
1992                    #[serde_with::serde_as]
1993                    #[derive(serde :: Serialize)]
1994                    struct Query<'a> {
1995                        #[serde(rename = "after")]
1996                        #[serde(skip_serializing_if = "Option::is_none")]
1997                        after: &'a Option<String>,
1998                        #[serde(rename = "limit")]
1999                        #[serde(skip_serializing_if = "Option::is_none")]
2000                        limit: &'a Option<i64>,
2001                        #[serde(rename = "order")]
2002                        #[serde(skip_serializing_if = "Option::is_none")]
2003                        order: &'a Option<crate::__types::list_evals::params::Order>,
2004                        #[serde(rename = "order_by")]
2005                        #[serde(skip_serializing_if = "Option::is_none")]
2006                        order_by: &'a Option<crate::__types::list_evals::params::OrderBy>,
2007                        #[serde(skip_serializing)]
2008                        _phantom: std::marker::PhantomData<&'a ()>,
2009                    }
2010                    let crate::__types::list_evals::Params {
2011                        after,
2012                        limit,
2013                        order,
2014                        order_by,
2015                    } = params;
2016                    #[allow(clippy::useless_format)]
2017                    let mut path = format!("/evals");
2018                    let query = serde_urlencoded::to_string(Query {
2019                        after,
2020                        limit,
2021                        order,
2022                        order_by,
2023                        _phantom: std::marker::PhantomData,
2024                    })?;
2025                    if !query.is_empty() {
2026                        path.push('?');
2027                        path.push_str(&query);
2028                    }
2029                    path
2030                };
2031                let body = String::new();
2032                Ok(http::Request::builder()
2033                    .method(http::Method::GET)
2034                    .uri(path)
2035                    .header(http::header::CONTENT_LENGTH, body.len())
2036                    .body(body)?)
2037            },
2038            (
2039                http::StatusCode::from_u16(200u16).unwrap(),
2040                Some(mime::APPLICATION_JSON),
2041            ),
2042        ),
2043        crate::__combinators::Json::new,
2044    ))
2045}
2046future!(
2047    ListEvals,
2048    futures::future::AndThen<
2049        crate::__combinators::Send<Fut, B, E>,
2050        crate::__combinators::Json<B, E, crate::__types::EvalList>,
2051        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::EvalList>,
2052    >,
2053    crate::__types::EvalList
2054);
2055#[doc = "Create eval"]
2056pub fn create_eval<C, Fut, B, E>(
2057    client: C,
2058    request: &crate::__types::CreateEvalRequest,
2059) -> CreateEval<Fut, B, E>
2060where
2061    C: FnOnce(http::Request<String>) -> Fut,
2062    Fut: Future<Output = Result<http::Response<B>, E>>,
2063    B: http_body::Body,
2064{
2065    CreateEval(futures::TryFutureExt::and_then(
2066        crate::__combinators::Send::new(
2067            client,
2068            || {
2069                let path = "/evals";
2070                let body = serde_json::to_string(request)?;
2071                Ok(http::Request::builder()
2072                    .method(http::Method::POST)
2073                    .uri(path)
2074                    .header(http::header::CONTENT_LENGTH, body.len())
2075                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
2076                    .body(body)?)
2077            },
2078            (
2079                http::StatusCode::from_u16(201u16).unwrap(),
2080                Some(mime::APPLICATION_JSON),
2081            ),
2082        ),
2083        crate::__combinators::Json::new,
2084    ))
2085}
2086future!(
2087    CreateEval,
2088    futures::future::AndThen<
2089        crate::__combinators::Send<Fut, B, E>,
2090        crate::__combinators::Json<B, E, crate::__types::Eval>,
2091        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Eval>,
2092    >,
2093    crate::__types::Eval
2094);
2095#[doc = "Get an eval"]
2096pub fn get_eval<C, Fut, B, E>(
2097    client: C,
2098    params: &crate::__types::get_eval::Params,
2099) -> GetEval<Fut, B, E>
2100where
2101    C: FnOnce(http::Request<String>) -> Fut,
2102    Fut: Future<Output = Result<http::Response<B>, E>>,
2103    B: http_body::Body,
2104{
2105    GetEval(futures::TryFutureExt::and_then(
2106        crate::__combinators::Send::new(
2107            client,
2108            || {
2109                let path = {
2110                    #[serde_with::serde_as]
2111                    #[derive(serde :: Serialize)]
2112                    struct Query<'a> {
2113                        #[serde(skip_serializing)]
2114                        _phantom: std::marker::PhantomData<&'a ()>,
2115                    }
2116                    let crate::__types::get_eval::Params { eval_id } = params;
2117                    #[allow(clippy::useless_format)]
2118                    let mut path = format!("/evals/{eval_id}");
2119                    let query = serde_urlencoded::to_string(Query {
2120                        _phantom: std::marker::PhantomData,
2121                    })?;
2122                    if !query.is_empty() {
2123                        path.push('?');
2124                        path.push_str(&query);
2125                    }
2126                    path
2127                };
2128                let body = String::new();
2129                Ok(http::Request::builder()
2130                    .method(http::Method::GET)
2131                    .uri(path)
2132                    .header(http::header::CONTENT_LENGTH, body.len())
2133                    .body(body)?)
2134            },
2135            (
2136                http::StatusCode::from_u16(200u16).unwrap(),
2137                Some(mime::APPLICATION_JSON),
2138            ),
2139        ),
2140        crate::__combinators::Json::new,
2141    ))
2142}
2143future!(
2144    GetEval,
2145    futures::future::AndThen<
2146        crate::__combinators::Send<Fut, B, E>,
2147        crate::__combinators::Json<B, E, crate::__types::Eval>,
2148        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Eval>,
2149    >,
2150    crate::__types::Eval
2151);
2152#[doc = "Update an eval"]
2153pub fn update_eval<C, Fut, B, E>(
2154    client: C,
2155    params: &crate::__types::update_eval::Params,
2156    request: &crate::__types::update_eval::Request,
2157) -> UpdateEval<Fut, B, E>
2158where
2159    C: FnOnce(http::Request<String>) -> Fut,
2160    Fut: Future<Output = Result<http::Response<B>, E>>,
2161    B: http_body::Body,
2162{
2163    UpdateEval(futures::TryFutureExt::and_then(
2164        crate::__combinators::Send::new(
2165            client,
2166            || {
2167                let path = {
2168                    #[serde_with::serde_as]
2169                    #[derive(serde :: Serialize)]
2170                    struct Query<'a> {
2171                        #[serde(skip_serializing)]
2172                        _phantom: std::marker::PhantomData<&'a ()>,
2173                    }
2174                    let crate::__types::update_eval::Params { eval_id } = params;
2175                    #[allow(clippy::useless_format)]
2176                    let mut path = format!("/evals/{eval_id}");
2177                    let query = serde_urlencoded::to_string(Query {
2178                        _phantom: std::marker::PhantomData,
2179                    })?;
2180                    if !query.is_empty() {
2181                        path.push('?');
2182                        path.push_str(&query);
2183                    }
2184                    path
2185                };
2186                let body = serde_json::to_string(request)?;
2187                Ok(http::Request::builder()
2188                    .method(http::Method::POST)
2189                    .uri(path)
2190                    .header(http::header::CONTENT_LENGTH, body.len())
2191                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
2192                    .body(body)?)
2193            },
2194            (
2195                http::StatusCode::from_u16(200u16).unwrap(),
2196                Some(mime::APPLICATION_JSON),
2197            ),
2198        ),
2199        crate::__combinators::Json::new,
2200    ))
2201}
2202future!(
2203    UpdateEval,
2204    futures::future::AndThen<
2205        crate::__combinators::Send<Fut, B, E>,
2206        crate::__combinators::Json<B, E, crate::__types::Eval>,
2207        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Eval>,
2208    >,
2209    crate::__types::Eval
2210);
2211#[doc = "Delete an eval"]
2212pub fn delete_eval<C, Fut, B, E>(
2213    client: C,
2214    params: &crate::__types::delete_eval::Params,
2215) -> DeleteEval<Fut, B, E>
2216where
2217    C: FnOnce(http::Request<String>) -> Fut,
2218    Fut: Future<Output = Result<http::Response<B>, E>>,
2219    B: http_body::Body,
2220{
2221    DeleteEval(futures::TryFutureExt::and_then(
2222        crate::__combinators::Send::new(
2223            client,
2224            || {
2225                let path = {
2226                    #[serde_with::serde_as]
2227                    #[derive(serde :: Serialize)]
2228                    struct Query<'a> {
2229                        #[serde(skip_serializing)]
2230                        _phantom: std::marker::PhantomData<&'a ()>,
2231                    }
2232                    let crate::__types::delete_eval::Params { eval_id } = params;
2233                    #[allow(clippy::useless_format)]
2234                    let mut path = format!("/evals/{eval_id}");
2235                    let query = serde_urlencoded::to_string(Query {
2236                        _phantom: std::marker::PhantomData,
2237                    })?;
2238                    if !query.is_empty() {
2239                        path.push('?');
2240                        path.push_str(&query);
2241                    }
2242                    path
2243                };
2244                let body = String::new();
2245                Ok(http::Request::builder()
2246                    .method(http::Method::DELETE)
2247                    .uri(path)
2248                    .header(http::header::CONTENT_LENGTH, body.len())
2249                    .body(body)?)
2250            },
2251            (
2252                http::StatusCode::from_u16(200u16).unwrap(),
2253                Some(mime::APPLICATION_JSON),
2254            ),
2255        ),
2256        crate::__combinators::Json::new,
2257    ))
2258}
2259future!(
2260    DeleteEval,
2261    futures::future::AndThen<
2262        crate::__combinators::Send<Fut, B, E>,
2263        crate::__combinators::Json<B, E, crate::__types::delete_eval::Response>,
2264        fn(
2265            http::Response<B>,
2266        ) -> crate::__combinators::Json<B, E, crate::__types::delete_eval::Response>,
2267    >,
2268    crate::__types::delete_eval::Response
2269);
2270#[doc = "Get eval runs"]
2271pub fn get_eval_runs<C, Fut, B, E>(
2272    client: C,
2273    params: &crate::__types::get_eval_runs::Params,
2274) -> GetEvalRuns<Fut, B, E>
2275where
2276    C: FnOnce(http::Request<String>) -> Fut,
2277    Fut: Future<Output = Result<http::Response<B>, E>>,
2278    B: http_body::Body,
2279{
2280    GetEvalRuns(futures::TryFutureExt::and_then(
2281        crate::__combinators::Send::new(
2282            client,
2283            || {
2284                let path = {
2285                    #[serde_with::serde_as]
2286                    #[derive(serde :: Serialize)]
2287                    struct Query<'a> {
2288                        #[serde(rename = "after")]
2289                        #[serde(skip_serializing_if = "Option::is_none")]
2290                        after: &'a Option<String>,
2291                        #[serde(rename = "limit")]
2292                        #[serde(skip_serializing_if = "Option::is_none")]
2293                        limit: &'a Option<i64>,
2294                        #[serde(rename = "order")]
2295                        #[serde(skip_serializing_if = "Option::is_none")]
2296                        order: &'a Option<crate::__types::get_eval_runs::params::Order>,
2297                        #[serde(rename = "status")]
2298                        #[serde(skip_serializing_if = "Option::is_none")]
2299                        status: &'a Option<crate::__types::get_eval_runs::params::Status>,
2300                        #[serde(skip_serializing)]
2301                        _phantom: std::marker::PhantomData<&'a ()>,
2302                    }
2303                    let crate::__types::get_eval_runs::Params {
2304                        eval_id,
2305                        after,
2306                        limit,
2307                        order,
2308                        status,
2309                    } = params;
2310                    #[allow(clippy::useless_format)]
2311                    let mut path = format!("/evals/{eval_id}/runs");
2312                    let query = serde_urlencoded::to_string(Query {
2313                        after,
2314                        limit,
2315                        order,
2316                        status,
2317                        _phantom: std::marker::PhantomData,
2318                    })?;
2319                    if !query.is_empty() {
2320                        path.push('?');
2321                        path.push_str(&query);
2322                    }
2323                    path
2324                };
2325                let body = String::new();
2326                Ok(http::Request::builder()
2327                    .method(http::Method::GET)
2328                    .uri(path)
2329                    .header(http::header::CONTENT_LENGTH, body.len())
2330                    .body(body)?)
2331            },
2332            (
2333                http::StatusCode::from_u16(200u16).unwrap(),
2334                Some(mime::APPLICATION_JSON),
2335            ),
2336        ),
2337        crate::__combinators::Json::new,
2338    ))
2339}
2340future!(
2341    GetEvalRuns,
2342    futures::future::AndThen<
2343        crate::__combinators::Send<Fut, B, E>,
2344        crate::__combinators::Json<B, E, crate::__types::EvalRunList>,
2345        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::EvalRunList>,
2346    >,
2347    crate::__types::EvalRunList
2348);
2349#[doc = "Create eval run"]
2350pub fn create_eval_run<C, Fut, B, E>(
2351    client: C,
2352    params: &crate::__types::create_eval_run::Params,
2353    request: &crate::__types::CreateEvalRunRequest,
2354) -> CreateEvalRun<Fut, B, E>
2355where
2356    C: FnOnce(http::Request<String>) -> Fut,
2357    Fut: Future<Output = Result<http::Response<B>, E>>,
2358    B: http_body::Body,
2359{
2360    CreateEvalRun(futures::TryFutureExt::and_then(
2361        crate::__combinators::Send::new(
2362            client,
2363            || {
2364                let path = {
2365                    #[serde_with::serde_as]
2366                    #[derive(serde :: Serialize)]
2367                    struct Query<'a> {
2368                        #[serde(skip_serializing)]
2369                        _phantom: std::marker::PhantomData<&'a ()>,
2370                    }
2371                    let crate::__types::create_eval_run::Params { eval_id } = params;
2372                    #[allow(clippy::useless_format)]
2373                    let mut path = format!("/evals/{eval_id}/runs");
2374                    let query = serde_urlencoded::to_string(Query {
2375                        _phantom: std::marker::PhantomData,
2376                    })?;
2377                    if !query.is_empty() {
2378                        path.push('?');
2379                        path.push_str(&query);
2380                    }
2381                    path
2382                };
2383                let body = serde_json::to_string(request)?;
2384                Ok(http::Request::builder()
2385                    .method(http::Method::POST)
2386                    .uri(path)
2387                    .header(http::header::CONTENT_LENGTH, body.len())
2388                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
2389                    .body(body)?)
2390            },
2391            (
2392                http::StatusCode::from_u16(201u16).unwrap(),
2393                Some(mime::APPLICATION_JSON),
2394            ),
2395        ),
2396        crate::__combinators::Json::new,
2397    ))
2398}
2399future!(
2400    CreateEvalRun,
2401    futures::future::AndThen<
2402        crate::__combinators::Send<Fut, B, E>,
2403        crate::__combinators::Json<B, E, crate::__types::EvalRun>,
2404        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::EvalRun>,
2405    >,
2406    crate::__types::EvalRun
2407);
2408#[doc = "Get an eval run"]
2409pub fn get_eval_run<C, Fut, B, E>(
2410    client: C,
2411    params: &crate::__types::get_eval_run::Params,
2412) -> GetEvalRun<Fut, B, E>
2413where
2414    C: FnOnce(http::Request<String>) -> Fut,
2415    Fut: Future<Output = Result<http::Response<B>, E>>,
2416    B: http_body::Body,
2417{
2418    GetEvalRun(futures::TryFutureExt::and_then(
2419        crate::__combinators::Send::new(
2420            client,
2421            || {
2422                let path = {
2423                    #[serde_with::serde_as]
2424                    #[derive(serde :: Serialize)]
2425                    struct Query<'a> {
2426                        #[serde(skip_serializing)]
2427                        _phantom: std::marker::PhantomData<&'a ()>,
2428                    }
2429                    let crate::__types::get_eval_run::Params { eval_id, run_id } = params;
2430                    #[allow(clippy::useless_format)]
2431                    let mut path = format!("/evals/{eval_id}/runs/{run_id}");
2432                    let query = serde_urlencoded::to_string(Query {
2433                        _phantom: std::marker::PhantomData,
2434                    })?;
2435                    if !query.is_empty() {
2436                        path.push('?');
2437                        path.push_str(&query);
2438                    }
2439                    path
2440                };
2441                let body = String::new();
2442                Ok(http::Request::builder()
2443                    .method(http::Method::GET)
2444                    .uri(path)
2445                    .header(http::header::CONTENT_LENGTH, body.len())
2446                    .body(body)?)
2447            },
2448            (
2449                http::StatusCode::from_u16(200u16).unwrap(),
2450                Some(mime::APPLICATION_JSON),
2451            ),
2452        ),
2453        crate::__combinators::Json::new,
2454    ))
2455}
2456future!(
2457    GetEvalRun,
2458    futures::future::AndThen<
2459        crate::__combinators::Send<Fut, B, E>,
2460        crate::__combinators::Json<B, E, crate::__types::EvalRun>,
2461        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::EvalRun>,
2462    >,
2463    crate::__types::EvalRun
2464);
2465#[doc = "Cancel eval run"]
2466pub fn cancel_eval_run<C, Fut, B, E>(
2467    client: C,
2468    params: &crate::__types::cancel_eval_run::Params,
2469) -> CancelEvalRun<Fut, B, E>
2470where
2471    C: FnOnce(http::Request<String>) -> Fut,
2472    Fut: Future<Output = Result<http::Response<B>, E>>,
2473    B: http_body::Body,
2474{
2475    CancelEvalRun(futures::TryFutureExt::and_then(
2476        crate::__combinators::Send::new(
2477            client,
2478            || {
2479                let path = {
2480                    #[serde_with::serde_as]
2481                    #[derive(serde :: Serialize)]
2482                    struct Query<'a> {
2483                        #[serde(skip_serializing)]
2484                        _phantom: std::marker::PhantomData<&'a ()>,
2485                    }
2486                    let crate::__types::cancel_eval_run::Params { eval_id, run_id } = params;
2487                    #[allow(clippy::useless_format)]
2488                    let mut path = format!("/evals/{eval_id}/runs/{run_id}");
2489                    let query = serde_urlencoded::to_string(Query {
2490                        _phantom: std::marker::PhantomData,
2491                    })?;
2492                    if !query.is_empty() {
2493                        path.push('?');
2494                        path.push_str(&query);
2495                    }
2496                    path
2497                };
2498                let body = String::new();
2499                Ok(http::Request::builder()
2500                    .method(http::Method::POST)
2501                    .uri(path)
2502                    .header(http::header::CONTENT_LENGTH, body.len())
2503                    .body(body)?)
2504            },
2505            (
2506                http::StatusCode::from_u16(200u16).unwrap(),
2507                Some(mime::APPLICATION_JSON),
2508            ),
2509        ),
2510        crate::__combinators::Json::new,
2511    ))
2512}
2513future!(
2514    CancelEvalRun,
2515    futures::future::AndThen<
2516        crate::__combinators::Send<Fut, B, E>,
2517        crate::__combinators::Json<B, E, crate::__types::EvalRun>,
2518        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::EvalRun>,
2519    >,
2520    crate::__types::EvalRun
2521);
2522#[doc = "Delete eval run"]
2523pub fn delete_eval_run<C, Fut, B, E>(
2524    client: C,
2525    params: &crate::__types::delete_eval_run::Params,
2526) -> DeleteEvalRun<Fut, B, E>
2527where
2528    C: FnOnce(http::Request<String>) -> Fut,
2529    Fut: Future<Output = Result<http::Response<B>, E>>,
2530    B: http_body::Body,
2531{
2532    DeleteEvalRun(futures::TryFutureExt::and_then(
2533        crate::__combinators::Send::new(
2534            client,
2535            || {
2536                let path = {
2537                    #[serde_with::serde_as]
2538                    #[derive(serde :: Serialize)]
2539                    struct Query<'a> {
2540                        #[serde(skip_serializing)]
2541                        _phantom: std::marker::PhantomData<&'a ()>,
2542                    }
2543                    let crate::__types::delete_eval_run::Params { eval_id, run_id } = params;
2544                    #[allow(clippy::useless_format)]
2545                    let mut path = format!("/evals/{eval_id}/runs/{run_id}");
2546                    let query = serde_urlencoded::to_string(Query {
2547                        _phantom: std::marker::PhantomData,
2548                    })?;
2549                    if !query.is_empty() {
2550                        path.push('?');
2551                        path.push_str(&query);
2552                    }
2553                    path
2554                };
2555                let body = String::new();
2556                Ok(http::Request::builder()
2557                    .method(http::Method::DELETE)
2558                    .uri(path)
2559                    .header(http::header::CONTENT_LENGTH, body.len())
2560                    .body(body)?)
2561            },
2562            (
2563                http::StatusCode::from_u16(200u16).unwrap(),
2564                Some(mime::APPLICATION_JSON),
2565            ),
2566        ),
2567        crate::__combinators::Json::new,
2568    ))
2569}
2570future!(
2571    DeleteEvalRun,
2572    futures::future::AndThen<
2573        crate::__combinators::Send<Fut, B, E>,
2574        crate::__combinators::Json<B, E, crate::__types::delete_eval_run::Response>,
2575        fn(
2576            http::Response<B>,
2577        ) -> crate::__combinators::Json<B, E, crate::__types::delete_eval_run::Response>,
2578    >,
2579    crate::__types::delete_eval_run::Response
2580);
2581#[doc = "Get eval run output items"]
2582pub fn get_eval_run_output_items<C, Fut, B, E>(
2583    client: C,
2584    params: &crate::__types::get_eval_run_output_items::Params,
2585) -> GetEvalRunOutputItems<Fut, B, E>
2586where
2587    C: FnOnce(http::Request<String>) -> Fut,
2588    Fut: Future<Output = Result<http::Response<B>, E>>,
2589    B: http_body::Body,
2590{
2591    GetEvalRunOutputItems(futures::TryFutureExt::and_then(
2592        crate::__combinators::Send::new(
2593            client,
2594            || {
2595                let path = {
2596                    #[serde_with::serde_as]
2597                    #[derive(serde :: Serialize)]
2598                    struct Query<'a> {
2599                        #[serde(rename = "after")]
2600                        #[serde(skip_serializing_if = "Option::is_none")]
2601                        after: &'a Option<String>,
2602                        #[serde(rename = "limit")]
2603                        #[serde(skip_serializing_if = "Option::is_none")]
2604                        limit: &'a Option<i64>,
2605                        #[serde(rename = "status")]
2606                        #[serde(skip_serializing_if = "Option::is_none")]
2607                        status:
2608                            &'a Option<crate::__types::get_eval_run_output_items::params::Status>,
2609                        #[serde(rename = "order")]
2610                        #[serde(skip_serializing_if = "Option::is_none")]
2611                        order: &'a Option<crate::__types::get_eval_run_output_items::params::Order>,
2612                        #[serde(skip_serializing)]
2613                        _phantom: std::marker::PhantomData<&'a ()>,
2614                    }
2615                    let crate::__types::get_eval_run_output_items::Params {
2616                        eval_id,
2617                        run_id,
2618                        after,
2619                        limit,
2620                        status,
2621                        order,
2622                    } = params;
2623                    #[allow(clippy::useless_format)]
2624                    let mut path = format!("/evals/{eval_id}/runs/{run_id}/output_items");
2625                    let query = serde_urlencoded::to_string(Query {
2626                        after,
2627                        limit,
2628                        status,
2629                        order,
2630                        _phantom: std::marker::PhantomData,
2631                    })?;
2632                    if !query.is_empty() {
2633                        path.push('?');
2634                        path.push_str(&query);
2635                    }
2636                    path
2637                };
2638                let body = String::new();
2639                Ok(http::Request::builder()
2640                    .method(http::Method::GET)
2641                    .uri(path)
2642                    .header(http::header::CONTENT_LENGTH, body.len())
2643                    .body(body)?)
2644            },
2645            (
2646                http::StatusCode::from_u16(200u16).unwrap(),
2647                Some(mime::APPLICATION_JSON),
2648            ),
2649        ),
2650        crate::__combinators::Json::new,
2651    ))
2652}
2653future!(
2654    GetEvalRunOutputItems,
2655    futures::future::AndThen<
2656        crate::__combinators::Send<Fut, B, E>,
2657        crate::__combinators::Json<B, E, crate::__types::EvalRunOutputItemList>,
2658        fn(
2659            http::Response<B>,
2660        ) -> crate::__combinators::Json<B, E, crate::__types::EvalRunOutputItemList>,
2661    >,
2662    crate::__types::EvalRunOutputItemList
2663);
2664#[doc = "Get an output item of an eval run"]
2665pub fn get_eval_run_output_item<C, Fut, B, E>(
2666    client: C,
2667    params: &crate::__types::get_eval_run_output_item::Params,
2668) -> GetEvalRunOutputItem<Fut, B, E>
2669where
2670    C: FnOnce(http::Request<String>) -> Fut,
2671    Fut: Future<Output = Result<http::Response<B>, E>>,
2672    B: http_body::Body,
2673{
2674    GetEvalRunOutputItem(futures::TryFutureExt::and_then(
2675        crate::__combinators::Send::new(
2676            client,
2677            || {
2678                let path = {
2679                    #[serde_with::serde_as]
2680                    #[derive(serde :: Serialize)]
2681                    struct Query<'a> {
2682                        #[serde(skip_serializing)]
2683                        _phantom: std::marker::PhantomData<&'a ()>,
2684                    }
2685                    let crate::__types::get_eval_run_output_item::Params {
2686                        eval_id,
2687                        run_id,
2688                        output_item_id,
2689                    } = params;
2690                    #[allow(clippy::useless_format)]
2691                    let mut path =
2692                        format!("/evals/{eval_id}/runs/{run_id}/output_items/{output_item_id}");
2693                    let query = serde_urlencoded::to_string(Query {
2694                        _phantom: std::marker::PhantomData,
2695                    })?;
2696                    if !query.is_empty() {
2697                        path.push('?');
2698                        path.push_str(&query);
2699                    }
2700                    path
2701                };
2702                let body = String::new();
2703                Ok(http::Request::builder()
2704                    .method(http::Method::GET)
2705                    .uri(path)
2706                    .header(http::header::CONTENT_LENGTH, body.len())
2707                    .body(body)?)
2708            },
2709            (
2710                http::StatusCode::from_u16(200u16).unwrap(),
2711                Some(mime::APPLICATION_JSON),
2712            ),
2713        ),
2714        crate::__combinators::Json::new,
2715    ))
2716}
2717future!(
2718    GetEvalRunOutputItem,
2719    futures::future::AndThen<
2720        crate::__combinators::Send<Fut, B, E>,
2721        crate::__combinators::Json<B, E, crate::__types::EvalRunOutputItem>,
2722        fn(
2723            http::Response<B>,
2724        ) -> crate::__combinators::Json<B, E, crate::__types::EvalRunOutputItem>,
2725    >,
2726    crate::__types::EvalRunOutputItem
2727);
2728#[doc = "List files"]
2729pub fn list_files<C, Fut, B, E>(
2730    client: C,
2731    params: &crate::__types::list_files::Params,
2732) -> ListFiles<Fut, B, E>
2733where
2734    C: FnOnce(http::Request<String>) -> Fut,
2735    Fut: Future<Output = Result<http::Response<B>, E>>,
2736    B: http_body::Body,
2737{
2738    ListFiles(futures::TryFutureExt::and_then(
2739        crate::__combinators::Send::new(
2740            client,
2741            || {
2742                let path = {
2743                    #[serde_with::serde_as]
2744                    #[derive(serde :: Serialize)]
2745                    struct Query<'a> {
2746                        #[serde(rename = "purpose")]
2747                        #[serde(skip_serializing_if = "Option::is_none")]
2748                        purpose: &'a Option<String>,
2749                        #[serde(rename = "limit")]
2750                        #[serde(skip_serializing_if = "Option::is_none")]
2751                        limit: &'a Option<i64>,
2752                        #[serde(rename = "order")]
2753                        #[serde(skip_serializing_if = "Option::is_none")]
2754                        order: &'a Option<crate::__types::list_files::params::Order>,
2755                        #[serde(rename = "after")]
2756                        #[serde(skip_serializing_if = "Option::is_none")]
2757                        after: &'a Option<String>,
2758                        #[serde(skip_serializing)]
2759                        _phantom: std::marker::PhantomData<&'a ()>,
2760                    }
2761                    let crate::__types::list_files::Params {
2762                        purpose,
2763                        limit,
2764                        order,
2765                        after,
2766                    } = params;
2767                    #[allow(clippy::useless_format)]
2768                    let mut path = format!("/files");
2769                    let query = serde_urlencoded::to_string(Query {
2770                        purpose,
2771                        limit,
2772                        order,
2773                        after,
2774                        _phantom: std::marker::PhantomData,
2775                    })?;
2776                    if !query.is_empty() {
2777                        path.push('?');
2778                        path.push_str(&query);
2779                    }
2780                    path
2781                };
2782                let body = String::new();
2783                Ok(http::Request::builder()
2784                    .method(http::Method::GET)
2785                    .uri(path)
2786                    .header(http::header::CONTENT_LENGTH, body.len())
2787                    .body(body)?)
2788            },
2789            (
2790                http::StatusCode::from_u16(200u16).unwrap(),
2791                Some(mime::APPLICATION_JSON),
2792            ),
2793        ),
2794        crate::__combinators::Json::new,
2795    ))
2796}
2797future!(
2798    ListFiles,
2799    futures::future::AndThen<
2800        crate::__combinators::Send<Fut, B, E>,
2801        crate::__combinators::Json<B, E, crate::__types::ListFilesResponse>,
2802        fn(
2803            http::Response<B>,
2804        ) -> crate::__combinators::Json<B, E, crate::__types::ListFilesResponse>,
2805    >,
2806    crate::__types::ListFilesResponse
2807);
2808#[doc = "Delete file"]
2809pub fn delete_file<C, Fut, B, E>(
2810    client: C,
2811    params: &crate::__types::delete_file::Params,
2812) -> DeleteFile<Fut, B, E>
2813where
2814    C: FnOnce(http::Request<String>) -> Fut,
2815    Fut: Future<Output = Result<http::Response<B>, E>>,
2816    B: http_body::Body,
2817{
2818    DeleteFile(futures::TryFutureExt::and_then(
2819        crate::__combinators::Send::new(
2820            client,
2821            || {
2822                let path = {
2823                    #[serde_with::serde_as]
2824                    #[derive(serde :: Serialize)]
2825                    struct Query<'a> {
2826                        #[serde(skip_serializing)]
2827                        _phantom: std::marker::PhantomData<&'a ()>,
2828                    }
2829                    let crate::__types::delete_file::Params { file_id } = params;
2830                    #[allow(clippy::useless_format)]
2831                    let mut path = format!("/files/{file_id}");
2832                    let query = serde_urlencoded::to_string(Query {
2833                        _phantom: std::marker::PhantomData,
2834                    })?;
2835                    if !query.is_empty() {
2836                        path.push('?');
2837                        path.push_str(&query);
2838                    }
2839                    path
2840                };
2841                let body = String::new();
2842                Ok(http::Request::builder()
2843                    .method(http::Method::DELETE)
2844                    .uri(path)
2845                    .header(http::header::CONTENT_LENGTH, body.len())
2846                    .body(body)?)
2847            },
2848            (
2849                http::StatusCode::from_u16(200u16).unwrap(),
2850                Some(mime::APPLICATION_JSON),
2851            ),
2852        ),
2853        crate::__combinators::Json::new,
2854    ))
2855}
2856future!(
2857    DeleteFile,
2858    futures::future::AndThen<
2859        crate::__combinators::Send<Fut, B, E>,
2860        crate::__combinators::Json<B, E, crate::__types::DeleteFileResponse>,
2861        fn(
2862            http::Response<B>,
2863        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteFileResponse>,
2864    >,
2865    crate::__types::DeleteFileResponse
2866);
2867#[doc = "Retrieve file"]
2868pub fn retrieve_file<C, Fut, B, E>(
2869    client: C,
2870    params: &crate::__types::retrieve_file::Params,
2871) -> RetrieveFile<Fut, B, E>
2872where
2873    C: FnOnce(http::Request<String>) -> Fut,
2874    Fut: Future<Output = Result<http::Response<B>, E>>,
2875    B: http_body::Body,
2876{
2877    RetrieveFile(futures::TryFutureExt::and_then(
2878        crate::__combinators::Send::new(
2879            client,
2880            || {
2881                let path = {
2882                    #[serde_with::serde_as]
2883                    #[derive(serde :: Serialize)]
2884                    struct Query<'a> {
2885                        #[serde(skip_serializing)]
2886                        _phantom: std::marker::PhantomData<&'a ()>,
2887                    }
2888                    let crate::__types::retrieve_file::Params { file_id } = params;
2889                    #[allow(clippy::useless_format)]
2890                    let mut path = format!("/files/{file_id}");
2891                    let query = serde_urlencoded::to_string(Query {
2892                        _phantom: std::marker::PhantomData,
2893                    })?;
2894                    if !query.is_empty() {
2895                        path.push('?');
2896                        path.push_str(&query);
2897                    }
2898                    path
2899                };
2900                let body = String::new();
2901                Ok(http::Request::builder()
2902                    .method(http::Method::GET)
2903                    .uri(path)
2904                    .header(http::header::CONTENT_LENGTH, body.len())
2905                    .body(body)?)
2906            },
2907            (
2908                http::StatusCode::from_u16(200u16).unwrap(),
2909                Some(mime::APPLICATION_JSON),
2910            ),
2911        ),
2912        crate::__combinators::Json::new,
2913    ))
2914}
2915future!(
2916    RetrieveFile,
2917    futures::future::AndThen<
2918        crate::__combinators::Send<Fut, B, E>,
2919        crate::__combinators::Json<B, E, crate::__types::OpenAiFile>,
2920        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::OpenAiFile>,
2921    >,
2922    crate::__types::OpenAiFile
2923);
2924#[doc = "Retrieve file content"]
2925pub fn download_file<C, Fut, B, E>(
2926    client: C,
2927    params: &crate::__types::download_file::Params,
2928) -> DownloadFile<Fut, B, E>
2929where
2930    C: FnOnce(http::Request<String>) -> Fut,
2931    Fut: Future<Output = Result<http::Response<B>, E>>,
2932    B: http_body::Body,
2933{
2934    DownloadFile(futures::TryFutureExt::and_then(
2935        crate::__combinators::Send::new(
2936            client,
2937            || {
2938                let path = {
2939                    #[serde_with::serde_as]
2940                    #[derive(serde :: Serialize)]
2941                    struct Query<'a> {
2942                        #[serde(skip_serializing)]
2943                        _phantom: std::marker::PhantomData<&'a ()>,
2944                    }
2945                    let crate::__types::download_file::Params { file_id } = params;
2946                    #[allow(clippy::useless_format)]
2947                    let mut path = format!("/files/{file_id}/content");
2948                    let query = serde_urlencoded::to_string(Query {
2949                        _phantom: std::marker::PhantomData,
2950                    })?;
2951                    if !query.is_empty() {
2952                        path.push('?');
2953                        path.push_str(&query);
2954                    }
2955                    path
2956                };
2957                let body = String::new();
2958                Ok(http::Request::builder()
2959                    .method(http::Method::GET)
2960                    .uri(path)
2961                    .header(http::header::CONTENT_LENGTH, body.len())
2962                    .body(body)?)
2963            },
2964            (
2965                http::StatusCode::from_u16(200u16).unwrap(),
2966                Some(mime::APPLICATION_JSON),
2967            ),
2968        ),
2969        crate::__combinators::Json::new,
2970    ))
2971}
2972future!(
2973    DownloadFile,
2974    futures::future::AndThen<
2975        crate::__combinators::Send<Fut, B, E>,
2976        crate::__combinators::Json<B, E, String>,
2977        fn(http::Response<B>) -> crate::__combinators::Json<B, E, String>,
2978    >,
2979    String
2980);
2981#[doc = "Run grader"]
2982pub fn run_grader<C, Fut, B, E>(
2983    client: C,
2984    request: &crate::__types::RunGraderRequest,
2985) -> RunGrader<Fut, B, E>
2986where
2987    C: FnOnce(http::Request<String>) -> Fut,
2988    Fut: Future<Output = Result<http::Response<B>, E>>,
2989    B: http_body::Body,
2990{
2991    RunGrader(futures::TryFutureExt::and_then(
2992        crate::__combinators::Send::new(
2993            client,
2994            || {
2995                let path = "/fine_tuning/alpha/graders/run";
2996                let body = serde_json::to_string(request)?;
2997                Ok(http::Request::builder()
2998                    .method(http::Method::POST)
2999                    .uri(path)
3000                    .header(http::header::CONTENT_LENGTH, body.len())
3001                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
3002                    .body(body)?)
3003            },
3004            (
3005                http::StatusCode::from_u16(200u16).unwrap(),
3006                Some(mime::APPLICATION_JSON),
3007            ),
3008        ),
3009        crate::__combinators::Json::new,
3010    ))
3011}
3012future!(
3013    RunGrader,
3014    futures::future::AndThen<
3015        crate::__combinators::Send<Fut, B, E>,
3016        crate::__combinators::Json<B, E, crate::__types::RunGraderResponse>,
3017        fn(
3018            http::Response<B>,
3019        ) -> crate::__combinators::Json<B, E, crate::__types::RunGraderResponse>,
3020    >,
3021    crate::__types::RunGraderResponse
3022);
3023#[doc = "Validate grader"]
3024pub fn validate_grader<C, Fut, B, E>(
3025    client: C,
3026    request: &crate::__types::ValidateGraderRequest,
3027) -> ValidateGrader<Fut, B, E>
3028where
3029    C: FnOnce(http::Request<String>) -> Fut,
3030    Fut: Future<Output = Result<http::Response<B>, E>>,
3031    B: http_body::Body,
3032{
3033    ValidateGrader(futures::TryFutureExt::and_then(
3034        crate::__combinators::Send::new(
3035            client,
3036            || {
3037                let path = "/fine_tuning/alpha/graders/validate";
3038                let body = serde_json::to_string(request)?;
3039                Ok(http::Request::builder()
3040                    .method(http::Method::POST)
3041                    .uri(path)
3042                    .header(http::header::CONTENT_LENGTH, body.len())
3043                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
3044                    .body(body)?)
3045            },
3046            (
3047                http::StatusCode::from_u16(200u16).unwrap(),
3048                Some(mime::APPLICATION_JSON),
3049            ),
3050        ),
3051        crate::__combinators::Json::new,
3052    ))
3053}
3054future!(
3055    ValidateGrader,
3056    futures::future::AndThen<
3057        crate::__combinators::Send<Fut, B, E>,
3058        crate::__combinators::Json<B, E, crate::__types::ValidateGraderResponse>,
3059        fn(
3060            http::Response<B>,
3061        ) -> crate::__combinators::Json<B, E, crate::__types::ValidateGraderResponse>,
3062    >,
3063    crate::__types::ValidateGraderResponse
3064);
3065#[doc = "List checkpoint permissions"]
3066pub fn list_fine_tuning_checkpoint_permissions<C, Fut, B, E>(
3067    client: C,
3068    params: &crate::__types::list_fine_tuning_checkpoint_permissions::Params,
3069) -> ListFineTuningCheckpointPermissions<Fut, B, E>
3070where
3071    C: FnOnce(http::Request<String>) -> Fut,
3072    Fut: Future<Output = Result<http::Response<B>, E>>,
3073    B: http_body::Body,
3074{
3075    ListFineTuningCheckpointPermissions(futures::TryFutureExt::and_then(
3076        crate::__combinators::Send::new(
3077            client,
3078            || {
3079                let path = {
3080                    #[serde_with::serde_as]
3081                    #[derive(serde :: Serialize)]
3082                    struct Query<'a> {
3083                        #[serde(rename = "project_id")]
3084                        #[serde(skip_serializing_if = "Option::is_none")]
3085                        project_id: &'a Option<String>,
3086                        #[serde(rename = "after")]
3087                        #[serde(skip_serializing_if = "Option::is_none")]
3088                        after: &'a Option<String>,
3089                        #[serde(rename = "limit")]
3090                        #[serde(skip_serializing_if = "Option::is_none")]
3091                        limit: &'a Option<i64>,
3092                        #[serde(rename = "order")]
3093                        #[serde(skip_serializing_if = "Option::is_none")]
3094                        order: &'a Option<
3095                            crate::__types::list_fine_tuning_checkpoint_permissions::params::Order,
3096                        >,
3097                        #[serde(skip_serializing)]
3098                        _phantom: std::marker::PhantomData<&'a ()>,
3099                    }
3100                    let crate::__types::list_fine_tuning_checkpoint_permissions::Params {
3101                        fine_tuned_model_checkpoint,
3102                        project_id,
3103                        after,
3104                        limit,
3105                        order,
3106                    } = params;
3107                    #[allow(clippy::useless_format)]
3108                    let mut path = format!(
3109                        "/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions"
3110                    );
3111                    let query = serde_urlencoded::to_string(Query {
3112                        project_id,
3113                        after,
3114                        limit,
3115                        order,
3116                        _phantom: std::marker::PhantomData,
3117                    })?;
3118                    if !query.is_empty() {
3119                        path.push('?');
3120                        path.push_str(&query);
3121                    }
3122                    path
3123                };
3124                let body = String::new();
3125                Ok(http::Request::builder()
3126                    .method(http::Method::GET)
3127                    .uri(path)
3128                    .header(http::header::CONTENT_LENGTH, body.len())
3129                    .body(body)?)
3130            },
3131            (
3132                http::StatusCode::from_u16(200u16).unwrap(),
3133                Some(mime::APPLICATION_JSON),
3134            ),
3135        ),
3136        crate::__combinators::Json::new,
3137    ))
3138}
3139future!(
3140    ListFineTuningCheckpointPermissions,
3141    futures::future::AndThen<
3142        crate::__combinators::Send<Fut, B, E>,
3143        crate::__combinators::Json<
3144            B,
3145            E,
3146            crate::__types::ListFineTuningCheckpointPermissionResponse,
3147        >,
3148        fn(
3149            http::Response<B>,
3150        ) -> crate::__combinators::Json<
3151            B,
3152            E,
3153            crate::__types::ListFineTuningCheckpointPermissionResponse,
3154        >,
3155    >,
3156    crate::__types::ListFineTuningCheckpointPermissionResponse
3157);
3158#[doc = "Create checkpoint permissions"]
3159pub fn create_fine_tuning_checkpoint_permission<C, Fut, B, E>(
3160    client: C,
3161    params: &crate::__types::create_fine_tuning_checkpoint_permission::Params,
3162    request: &crate::__types::CreateFineTuningCheckpointPermissionRequest,
3163) -> CreateFineTuningCheckpointPermission<Fut, B, E>
3164where
3165    C: FnOnce(http::Request<String>) -> Fut,
3166    Fut: Future<Output = Result<http::Response<B>, E>>,
3167    B: http_body::Body,
3168{
3169    CreateFineTuningCheckpointPermission(futures::TryFutureExt::and_then(
3170        crate::__combinators::Send::new(
3171            client,
3172            || {
3173                let path = {
3174                    #[serde_with::serde_as]
3175                    #[derive(serde :: Serialize)]
3176                    struct Query<'a> {
3177                        #[serde(skip_serializing)]
3178                        _phantom: std::marker::PhantomData<&'a ()>,
3179                    }
3180                    let crate::__types::create_fine_tuning_checkpoint_permission::Params {
3181                        fine_tuned_model_checkpoint,
3182                    } = params;
3183                    #[allow(clippy::useless_format)]
3184                    let mut path = format!(
3185                        "/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions"
3186                    );
3187                    let query = serde_urlencoded::to_string(Query {
3188                        _phantom: std::marker::PhantomData,
3189                    })?;
3190                    if !query.is_empty() {
3191                        path.push('?');
3192                        path.push_str(&query);
3193                    }
3194                    path
3195                };
3196                let body = serde_json::to_string(request)?;
3197                Ok(http::Request::builder()
3198                    .method(http::Method::POST)
3199                    .uri(path)
3200                    .header(http::header::CONTENT_LENGTH, body.len())
3201                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
3202                    .body(body)?)
3203            },
3204            (
3205                http::StatusCode::from_u16(200u16).unwrap(),
3206                Some(mime::APPLICATION_JSON),
3207            ),
3208        ),
3209        crate::__combinators::Json::new,
3210    ))
3211}
3212future!(
3213    CreateFineTuningCheckpointPermission,
3214    futures::future::AndThen<
3215        crate::__combinators::Send<Fut, B, E>,
3216        crate::__combinators::Json<
3217            B,
3218            E,
3219            crate::__types::ListFineTuningCheckpointPermissionResponse,
3220        >,
3221        fn(
3222            http::Response<B>,
3223        ) -> crate::__combinators::Json<
3224            B,
3225            E,
3226            crate::__types::ListFineTuningCheckpointPermissionResponse,
3227        >,
3228    >,
3229    crate::__types::ListFineTuningCheckpointPermissionResponse
3230);
3231#[doc = "Delete checkpoint permission"]
3232pub fn delete_fine_tuning_checkpoint_permission<C, Fut, B, E>(
3233    client: C,
3234    params: &crate::__types::delete_fine_tuning_checkpoint_permission::Params,
3235) -> DeleteFineTuningCheckpointPermission<Fut, B, E>
3236where
3237    C: FnOnce(http::Request<String>) -> Fut,
3238    Fut: Future<Output = Result<http::Response<B>, E>>,
3239    B: http_body::Body,
3240{
3241    DeleteFineTuningCheckpointPermission(futures::TryFutureExt::and_then(
3242        crate::__combinators::Send::new(
3243            client,
3244            || {
3245                let path = {
3246                    #[serde_with::serde_as]
3247                    #[derive(serde :: Serialize)]
3248                    struct Query<'a> {
3249                        #[serde(skip_serializing)]
3250                        _phantom: std::marker::PhantomData<&'a ()>,
3251                    }
3252                    let crate::__types::delete_fine_tuning_checkpoint_permission::Params {
3253                        fine_tuned_model_checkpoint,
3254                        permission_id,
3255                    } = params;
3256                    #[allow(clippy::useless_format)]
3257                    let mut path = format!(
3258                        "/fine_tuning/checkpoints/{fine_tuned_model_checkpoint}/permissions/{permission_id}"
3259                    );
3260                    let query = serde_urlencoded::to_string(Query {
3261                        _phantom: std::marker::PhantomData,
3262                    })?;
3263                    if !query.is_empty() {
3264                        path.push('?');
3265                        path.push_str(&query);
3266                    }
3267                    path
3268                };
3269                let body = String::new();
3270                Ok(http::Request::builder()
3271                    .method(http::Method::DELETE)
3272                    .uri(path)
3273                    .header(http::header::CONTENT_LENGTH, body.len())
3274                    .body(body)?)
3275            },
3276            (
3277                http::StatusCode::from_u16(200u16).unwrap(),
3278                Some(mime::APPLICATION_JSON),
3279            ),
3280        ),
3281        crate::__combinators::Json::new,
3282    ))
3283}
3284future!(
3285    DeleteFineTuningCheckpointPermission,
3286    futures::future::AndThen<
3287        crate::__combinators::Send<Fut, B, E>,
3288        crate::__combinators::Json<
3289            B,
3290            E,
3291            crate::__types::DeleteFineTuningCheckpointPermissionResponse,
3292        >,
3293        fn(
3294            http::Response<B>,
3295        ) -> crate::__combinators::Json<
3296            B,
3297            E,
3298            crate::__types::DeleteFineTuningCheckpointPermissionResponse,
3299        >,
3300    >,
3301    crate::__types::DeleteFineTuningCheckpointPermissionResponse
3302);
3303#[doc = "Create fine-tuning job"]
3304pub fn create_fine_tuning_job<C, Fut, B, E>(
3305    client: C,
3306    request: &crate::__types::CreateFineTuningJobRequest,
3307) -> CreateFineTuningJob<Fut, B, E>
3308where
3309    C: FnOnce(http::Request<String>) -> Fut,
3310    Fut: Future<Output = Result<http::Response<B>, E>>,
3311    B: http_body::Body,
3312{
3313    CreateFineTuningJob(futures::TryFutureExt::and_then(
3314        crate::__combinators::Send::new(
3315            client,
3316            || {
3317                let path = "/fine_tuning/jobs";
3318                let body = serde_json::to_string(request)?;
3319                Ok(http::Request::builder()
3320                    .method(http::Method::POST)
3321                    .uri(path)
3322                    .header(http::header::CONTENT_LENGTH, body.len())
3323                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
3324                    .body(body)?)
3325            },
3326            (
3327                http::StatusCode::from_u16(200u16).unwrap(),
3328                Some(mime::APPLICATION_JSON),
3329            ),
3330        ),
3331        crate::__combinators::Json::new,
3332    ))
3333}
3334future!(
3335    CreateFineTuningJob,
3336    futures::future::AndThen<
3337        crate::__combinators::Send<Fut, B, E>,
3338        crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3339        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3340    >,
3341    crate::__types::FineTuningJob
3342);
3343#[doc = "List fine-tuning jobs"]
3344pub fn list_paginated_fine_tuning_jobs<C, Fut, B, E>(
3345    client: C,
3346    params: &crate::__types::list_paginated_fine_tuning_jobs::Params,
3347) -> ListPaginatedFineTuningJobs<Fut, B, E>
3348where
3349    C: FnOnce(http::Request<String>) -> Fut,
3350    Fut: Future<Output = Result<http::Response<B>, E>>,
3351    B: http_body::Body,
3352{
3353    ListPaginatedFineTuningJobs(futures::TryFutureExt::and_then(
3354        crate::__combinators::Send::new(
3355            client,
3356            || {
3357                let path = {
3358                    #[serde_with::serde_as]
3359                    #[derive(serde :: Serialize)]
3360                    struct Query<'a> {
3361                        #[serde(rename = "after")]
3362                        #[serde(skip_serializing_if = "Option::is_none")]
3363                        after: &'a Option<String>,
3364                        #[serde(rename = "limit")]
3365                        #[serde(skip_serializing_if = "Option::is_none")]
3366                        limit: &'a Option<i64>,
3367                        #[serde(rename = "metadata")]
3368                        #[serde(skip_serializing_if = "Option::is_none")]
3369                        metadata: &'a Option<indexmap::IndexMap<String, String>>,
3370                        #[serde(skip_serializing)]
3371                        _phantom: std::marker::PhantomData<&'a ()>,
3372                    }
3373                    let crate::__types::list_paginated_fine_tuning_jobs::Params {
3374                        after,
3375                        limit,
3376                        metadata,
3377                    } = params;
3378                    #[allow(clippy::useless_format)]
3379                    let mut path = format!("/fine_tuning/jobs");
3380                    let query = serde_urlencoded::to_string(Query {
3381                        after,
3382                        limit,
3383                        metadata,
3384                        _phantom: std::marker::PhantomData,
3385                    })?;
3386                    if !query.is_empty() {
3387                        path.push('?');
3388                        path.push_str(&query);
3389                    }
3390                    path
3391                };
3392                let body = String::new();
3393                Ok(http::Request::builder()
3394                    .method(http::Method::GET)
3395                    .uri(path)
3396                    .header(http::header::CONTENT_LENGTH, body.len())
3397                    .body(body)?)
3398            },
3399            (
3400                http::StatusCode::from_u16(200u16).unwrap(),
3401                Some(mime::APPLICATION_JSON),
3402            ),
3403        ),
3404        crate::__combinators::Json::new,
3405    ))
3406}
3407future!(
3408    ListPaginatedFineTuningJobs,
3409    futures::future::AndThen<
3410        crate::__combinators::Send<Fut, B, E>,
3411        crate::__combinators::Json<B, E, crate::__types::ListPaginatedFineTuningJobsResponse>,
3412        fn(
3413            http::Response<B>,
3414        )
3415            -> crate::__combinators::Json<B, E, crate::__types::ListPaginatedFineTuningJobsResponse>,
3416    >,
3417    crate::__types::ListPaginatedFineTuningJobsResponse
3418);
3419#[doc = "Retrieve fine-tuning job"]
3420pub fn retrieve_fine_tuning_job<C, Fut, B, E>(
3421    client: C,
3422    params: &crate::__types::retrieve_fine_tuning_job::Params,
3423) -> RetrieveFineTuningJob<Fut, B, E>
3424where
3425    C: FnOnce(http::Request<String>) -> Fut,
3426    Fut: Future<Output = Result<http::Response<B>, E>>,
3427    B: http_body::Body,
3428{
3429    RetrieveFineTuningJob(futures::TryFutureExt::and_then(
3430        crate::__combinators::Send::new(
3431            client,
3432            || {
3433                let path = {
3434                    #[serde_with::serde_as]
3435                    #[derive(serde :: Serialize)]
3436                    struct Query<'a> {
3437                        #[serde(skip_serializing)]
3438                        _phantom: std::marker::PhantomData<&'a ()>,
3439                    }
3440                    let crate::__types::retrieve_fine_tuning_job::Params { fine_tuning_job_id } =
3441                        params;
3442                    #[allow(clippy::useless_format)]
3443                    let mut path = format!("/fine_tuning/jobs/{fine_tuning_job_id}");
3444                    let query = serde_urlencoded::to_string(Query {
3445                        _phantom: std::marker::PhantomData,
3446                    })?;
3447                    if !query.is_empty() {
3448                        path.push('?');
3449                        path.push_str(&query);
3450                    }
3451                    path
3452                };
3453                let body = String::new();
3454                Ok(http::Request::builder()
3455                    .method(http::Method::GET)
3456                    .uri(path)
3457                    .header(http::header::CONTENT_LENGTH, body.len())
3458                    .body(body)?)
3459            },
3460            (
3461                http::StatusCode::from_u16(200u16).unwrap(),
3462                Some(mime::APPLICATION_JSON),
3463            ),
3464        ),
3465        crate::__combinators::Json::new,
3466    ))
3467}
3468future!(
3469    RetrieveFineTuningJob,
3470    futures::future::AndThen<
3471        crate::__combinators::Send<Fut, B, E>,
3472        crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3473        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3474    >,
3475    crate::__types::FineTuningJob
3476);
3477#[doc = "Cancel fine-tuning"]
3478pub fn cancel_fine_tuning_job<C, Fut, B, E>(
3479    client: C,
3480    params: &crate::__types::cancel_fine_tuning_job::Params,
3481) -> CancelFineTuningJob<Fut, B, E>
3482where
3483    C: FnOnce(http::Request<String>) -> Fut,
3484    Fut: Future<Output = Result<http::Response<B>, E>>,
3485    B: http_body::Body,
3486{
3487    CancelFineTuningJob(futures::TryFutureExt::and_then(
3488        crate::__combinators::Send::new(
3489            client,
3490            || {
3491                let path = {
3492                    #[serde_with::serde_as]
3493                    #[derive(serde :: Serialize)]
3494                    struct Query<'a> {
3495                        #[serde(skip_serializing)]
3496                        _phantom: std::marker::PhantomData<&'a ()>,
3497                    }
3498                    let crate::__types::cancel_fine_tuning_job::Params { fine_tuning_job_id } =
3499                        params;
3500                    #[allow(clippy::useless_format)]
3501                    let mut path = format!("/fine_tuning/jobs/{fine_tuning_job_id}/cancel");
3502                    let query = serde_urlencoded::to_string(Query {
3503                        _phantom: std::marker::PhantomData,
3504                    })?;
3505                    if !query.is_empty() {
3506                        path.push('?');
3507                        path.push_str(&query);
3508                    }
3509                    path
3510                };
3511                let body = String::new();
3512                Ok(http::Request::builder()
3513                    .method(http::Method::POST)
3514                    .uri(path)
3515                    .header(http::header::CONTENT_LENGTH, body.len())
3516                    .body(body)?)
3517            },
3518            (
3519                http::StatusCode::from_u16(200u16).unwrap(),
3520                Some(mime::APPLICATION_JSON),
3521            ),
3522        ),
3523        crate::__combinators::Json::new,
3524    ))
3525}
3526future!(
3527    CancelFineTuningJob,
3528    futures::future::AndThen<
3529        crate::__combinators::Send<Fut, B, E>,
3530        crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3531        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3532    >,
3533    crate::__types::FineTuningJob
3534);
3535#[doc = "List fine-tuning checkpoints"]
3536pub fn list_fine_tuning_job_checkpoints<C, Fut, B, E>(
3537    client: C,
3538    params: &crate::__types::list_fine_tuning_job_checkpoints::Params,
3539) -> ListFineTuningJobCheckpoints<Fut, B, E>
3540where
3541    C: FnOnce(http::Request<String>) -> Fut,
3542    Fut: Future<Output = Result<http::Response<B>, E>>,
3543    B: http_body::Body,
3544{
3545    ListFineTuningJobCheckpoints(futures::TryFutureExt::and_then(
3546        crate::__combinators::Send::new(
3547            client,
3548            || {
3549                let path = {
3550                    #[serde_with::serde_as]
3551                    #[derive(serde :: Serialize)]
3552                    struct Query<'a> {
3553                        #[serde(rename = "after")]
3554                        #[serde(skip_serializing_if = "Option::is_none")]
3555                        after: &'a Option<String>,
3556                        #[serde(rename = "limit")]
3557                        #[serde(skip_serializing_if = "Option::is_none")]
3558                        limit: &'a Option<i64>,
3559                        #[serde(skip_serializing)]
3560                        _phantom: std::marker::PhantomData<&'a ()>,
3561                    }
3562                    let crate::__types::list_fine_tuning_job_checkpoints::Params {
3563                        fine_tuning_job_id,
3564                        after,
3565                        limit,
3566                    } = params;
3567                    #[allow(clippy::useless_format)]
3568                    let mut path = format!("/fine_tuning/jobs/{fine_tuning_job_id}/checkpoints");
3569                    let query = serde_urlencoded::to_string(Query {
3570                        after,
3571                        limit,
3572                        _phantom: std::marker::PhantomData,
3573                    })?;
3574                    if !query.is_empty() {
3575                        path.push('?');
3576                        path.push_str(&query);
3577                    }
3578                    path
3579                };
3580                let body = String::new();
3581                Ok(http::Request::builder()
3582                    .method(http::Method::GET)
3583                    .uri(path)
3584                    .header(http::header::CONTENT_LENGTH, body.len())
3585                    .body(body)?)
3586            },
3587            (
3588                http::StatusCode::from_u16(200u16).unwrap(),
3589                Some(mime::APPLICATION_JSON),
3590            ),
3591        ),
3592        crate::__combinators::Json::new,
3593    ))
3594}
3595future!(
3596    ListFineTuningJobCheckpoints,
3597    futures::future::AndThen<
3598        crate::__combinators::Send<Fut, B, E>,
3599        crate::__combinators::Json<B, E, crate::__types::ListFineTuningJobCheckpointsResponse>,
3600        fn(
3601            http::Response<B>,
3602        ) -> crate::__combinators::Json<
3603            B,
3604            E,
3605            crate::__types::ListFineTuningJobCheckpointsResponse,
3606        >,
3607    >,
3608    crate::__types::ListFineTuningJobCheckpointsResponse
3609);
3610#[doc = "List fine-tuning events"]
3611pub fn list_fine_tuning_events<C, Fut, B, E>(
3612    client: C,
3613    params: &crate::__types::list_fine_tuning_events::Params,
3614) -> ListFineTuningEvents<Fut, B, E>
3615where
3616    C: FnOnce(http::Request<String>) -> Fut,
3617    Fut: Future<Output = Result<http::Response<B>, E>>,
3618    B: http_body::Body,
3619{
3620    ListFineTuningEvents(futures::TryFutureExt::and_then(
3621        crate::__combinators::Send::new(
3622            client,
3623            || {
3624                let path = {
3625                    #[serde_with::serde_as]
3626                    #[derive(serde :: Serialize)]
3627                    struct Query<'a> {
3628                        #[serde(rename = "after")]
3629                        #[serde(skip_serializing_if = "Option::is_none")]
3630                        after: &'a Option<String>,
3631                        #[serde(rename = "limit")]
3632                        #[serde(skip_serializing_if = "Option::is_none")]
3633                        limit: &'a Option<i64>,
3634                        #[serde(skip_serializing)]
3635                        _phantom: std::marker::PhantomData<&'a ()>,
3636                    }
3637                    let crate::__types::list_fine_tuning_events::Params {
3638                        fine_tuning_job_id,
3639                        after,
3640                        limit,
3641                    } = params;
3642                    #[allow(clippy::useless_format)]
3643                    let mut path = format!("/fine_tuning/jobs/{fine_tuning_job_id}/events");
3644                    let query = serde_urlencoded::to_string(Query {
3645                        after,
3646                        limit,
3647                        _phantom: std::marker::PhantomData,
3648                    })?;
3649                    if !query.is_empty() {
3650                        path.push('?');
3651                        path.push_str(&query);
3652                    }
3653                    path
3654                };
3655                let body = String::new();
3656                Ok(http::Request::builder()
3657                    .method(http::Method::GET)
3658                    .uri(path)
3659                    .header(http::header::CONTENT_LENGTH, body.len())
3660                    .body(body)?)
3661            },
3662            (
3663                http::StatusCode::from_u16(200u16).unwrap(),
3664                Some(mime::APPLICATION_JSON),
3665            ),
3666        ),
3667        crate::__combinators::Json::new,
3668    ))
3669}
3670future!(
3671    ListFineTuningEvents,
3672    futures::future::AndThen<
3673        crate::__combinators::Send<Fut, B, E>,
3674        crate::__combinators::Json<B, E, crate::__types::ListFineTuningJobEventsResponse>,
3675        fn(
3676            http::Response<B>,
3677        )
3678            -> crate::__combinators::Json<B, E, crate::__types::ListFineTuningJobEventsResponse>,
3679    >,
3680    crate::__types::ListFineTuningJobEventsResponse
3681);
3682#[doc = "Pause fine-tuning"]
3683pub fn pause_fine_tuning_job<C, Fut, B, E>(
3684    client: C,
3685    params: &crate::__types::pause_fine_tuning_job::Params,
3686) -> PauseFineTuningJob<Fut, B, E>
3687where
3688    C: FnOnce(http::Request<String>) -> Fut,
3689    Fut: Future<Output = Result<http::Response<B>, E>>,
3690    B: http_body::Body,
3691{
3692    PauseFineTuningJob(futures::TryFutureExt::and_then(
3693        crate::__combinators::Send::new(
3694            client,
3695            || {
3696                let path = {
3697                    #[serde_with::serde_as]
3698                    #[derive(serde :: Serialize)]
3699                    struct Query<'a> {
3700                        #[serde(skip_serializing)]
3701                        _phantom: std::marker::PhantomData<&'a ()>,
3702                    }
3703                    let crate::__types::pause_fine_tuning_job::Params { fine_tuning_job_id } =
3704                        params;
3705                    #[allow(clippy::useless_format)]
3706                    let mut path = format!("/fine_tuning/jobs/{fine_tuning_job_id}/pause");
3707                    let query = serde_urlencoded::to_string(Query {
3708                        _phantom: std::marker::PhantomData,
3709                    })?;
3710                    if !query.is_empty() {
3711                        path.push('?');
3712                        path.push_str(&query);
3713                    }
3714                    path
3715                };
3716                let body = String::new();
3717                Ok(http::Request::builder()
3718                    .method(http::Method::POST)
3719                    .uri(path)
3720                    .header(http::header::CONTENT_LENGTH, body.len())
3721                    .body(body)?)
3722            },
3723            (
3724                http::StatusCode::from_u16(200u16).unwrap(),
3725                Some(mime::APPLICATION_JSON),
3726            ),
3727        ),
3728        crate::__combinators::Json::new,
3729    ))
3730}
3731future!(
3732    PauseFineTuningJob,
3733    futures::future::AndThen<
3734        crate::__combinators::Send<Fut, B, E>,
3735        crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3736        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3737    >,
3738    crate::__types::FineTuningJob
3739);
3740#[doc = "Resume fine-tuning"]
3741pub fn resume_fine_tuning_job<C, Fut, B, E>(
3742    client: C,
3743    params: &crate::__types::resume_fine_tuning_job::Params,
3744) -> ResumeFineTuningJob<Fut, B, E>
3745where
3746    C: FnOnce(http::Request<String>) -> Fut,
3747    Fut: Future<Output = Result<http::Response<B>, E>>,
3748    B: http_body::Body,
3749{
3750    ResumeFineTuningJob(futures::TryFutureExt::and_then(
3751        crate::__combinators::Send::new(
3752            client,
3753            || {
3754                let path = {
3755                    #[serde_with::serde_as]
3756                    #[derive(serde :: Serialize)]
3757                    struct Query<'a> {
3758                        #[serde(skip_serializing)]
3759                        _phantom: std::marker::PhantomData<&'a ()>,
3760                    }
3761                    let crate::__types::resume_fine_tuning_job::Params { fine_tuning_job_id } =
3762                        params;
3763                    #[allow(clippy::useless_format)]
3764                    let mut path = format!("/fine_tuning/jobs/{fine_tuning_job_id}/resume");
3765                    let query = serde_urlencoded::to_string(Query {
3766                        _phantom: std::marker::PhantomData,
3767                    })?;
3768                    if !query.is_empty() {
3769                        path.push('?');
3770                        path.push_str(&query);
3771                    }
3772                    path
3773                };
3774                let body = String::new();
3775                Ok(http::Request::builder()
3776                    .method(http::Method::POST)
3777                    .uri(path)
3778                    .header(http::header::CONTENT_LENGTH, body.len())
3779                    .body(body)?)
3780            },
3781            (
3782                http::StatusCode::from_u16(200u16).unwrap(),
3783                Some(mime::APPLICATION_JSON),
3784            ),
3785        ),
3786        crate::__combinators::Json::new,
3787    ))
3788}
3789future!(
3790    ResumeFineTuningJob,
3791    futures::future::AndThen<
3792        crate::__combinators::Send<Fut, B, E>,
3793        crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3794        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::FineTuningJob>,
3795    >,
3796    crate::__types::FineTuningJob
3797);
3798#[doc = "Create image"]
3799pub fn create_image<C, Fut, B, E>(
3800    client: C,
3801    request: &crate::__types::CreateImageRequest,
3802) -> CreateImage<Fut, B, E>
3803where
3804    C: FnOnce(http::Request<String>) -> Fut,
3805    Fut: Future<Output = Result<http::Response<B>, E>>,
3806    B: http_body::Body,
3807{
3808    CreateImage(futures::TryFutureExt::and_then(
3809        crate::__combinators::Send::new(
3810            client,
3811            || {
3812                let path = "/images/generations";
3813                let body = serde_json::to_string(request)?;
3814                Ok(http::Request::builder()
3815                    .method(http::Method::POST)
3816                    .uri(path)
3817                    .header(http::header::CONTENT_LENGTH, body.len())
3818                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
3819                    .body(body)?)
3820            },
3821            (
3822                http::StatusCode::from_u16(200u16).unwrap(),
3823                Some(mime::APPLICATION_JSON),
3824            ),
3825        ),
3826        crate::__combinators::Json::new,
3827    ))
3828}
3829future!(
3830    CreateImage,
3831    futures::future::AndThen<
3832        crate::__combinators::Send<Fut, B, E>,
3833        crate::__combinators::Json<B, E, crate::__types::ImagesResponse>,
3834        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ImagesResponse>,
3835    >,
3836    crate::__types::ImagesResponse
3837);
3838#[doc = "Create image"]
3839pub fn create_image_stream<C, Fut, B, E>(
3840    client: C,
3841    request: &crate::__types::CreateImageRequest,
3842) -> CreateImageStream<Fut, B, E>
3843where
3844    C: FnOnce(http::Request<String>) -> Fut,
3845    Fut: Future<Output = Result<http::Response<B>, E>>,
3846    B: http_body::Body,
3847{
3848    CreateImageStream(futures::TryFutureExt::map_ok(
3849        crate::__combinators::Send::new(
3850            client,
3851            || {
3852                let path = "/images/generations";
3853                let body = serde_json::to_string(request)?;
3854                Ok(http::Request::builder()
3855                    .method(http::Method::POST)
3856                    .uri(path)
3857                    .header(http::header::CONTENT_LENGTH, body.len())
3858                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
3859                    .body(body)?)
3860            },
3861            (
3862                http::StatusCode::from_u16(200u16).unwrap(),
3863                Some(mime::TEXT_EVENT_STREAM),
3864            ),
3865        ),
3866        crate::__combinators::EventStream::new,
3867    ))
3868}
3869future ! (CreateImageStream , futures :: future :: MapOk < crate :: __combinators :: Send < Fut , B , E > , fn (http :: Response < B >) -> crate :: __combinators :: EventStream < B , crate :: __types :: ImageGenStreamEvent > , > , crate :: __combinators :: EventStream < B , crate :: __types :: ImageGenStreamEvent >);
3870#[doc = "List models"]
3871pub fn list_models<C, Fut, B, E>(client: C) -> ListModels<Fut, B, E>
3872where
3873    C: FnOnce(http::Request<String>) -> Fut,
3874    Fut: Future<Output = Result<http::Response<B>, E>>,
3875    B: http_body::Body,
3876{
3877    ListModels(futures::TryFutureExt::and_then(
3878        crate::__combinators::Send::new(
3879            client,
3880            || {
3881                let path = "/models";
3882                let body = String::new();
3883                Ok(http::Request::builder()
3884                    .method(http::Method::GET)
3885                    .uri(path)
3886                    .header(http::header::CONTENT_LENGTH, body.len())
3887                    .body(body)?)
3888            },
3889            (
3890                http::StatusCode::from_u16(200u16).unwrap(),
3891                Some(mime::APPLICATION_JSON),
3892            ),
3893        ),
3894        crate::__combinators::Json::new,
3895    ))
3896}
3897future!(
3898    ListModels,
3899    futures::future::AndThen<
3900        crate::__combinators::Send<Fut, B, E>,
3901        crate::__combinators::Json<B, E, crate::__types::ListModelsResponse>,
3902        fn(
3903            http::Response<B>,
3904        ) -> crate::__combinators::Json<B, E, crate::__types::ListModelsResponse>,
3905    >,
3906    crate::__types::ListModelsResponse
3907);
3908#[doc = "Retrieve model"]
3909pub fn retrieve_model<C, Fut, B, E>(
3910    client: C,
3911    params: &crate::__types::retrieve_model::Params,
3912) -> RetrieveModel<Fut, B, E>
3913where
3914    C: FnOnce(http::Request<String>) -> Fut,
3915    Fut: Future<Output = Result<http::Response<B>, E>>,
3916    B: http_body::Body,
3917{
3918    RetrieveModel(futures::TryFutureExt::and_then(
3919        crate::__combinators::Send::new(
3920            client,
3921            || {
3922                let path = {
3923                    #[serde_with::serde_as]
3924                    #[derive(serde :: Serialize)]
3925                    struct Query<'a> {
3926                        #[serde(skip_serializing)]
3927                        _phantom: std::marker::PhantomData<&'a ()>,
3928                    }
3929                    let crate::__types::retrieve_model::Params { model } = params;
3930                    #[allow(clippy::useless_format)]
3931                    let mut path = format!("/models/{model}");
3932                    let query = serde_urlencoded::to_string(Query {
3933                        _phantom: std::marker::PhantomData,
3934                    })?;
3935                    if !query.is_empty() {
3936                        path.push('?');
3937                        path.push_str(&query);
3938                    }
3939                    path
3940                };
3941                let body = String::new();
3942                Ok(http::Request::builder()
3943                    .method(http::Method::GET)
3944                    .uri(path)
3945                    .header(http::header::CONTENT_LENGTH, body.len())
3946                    .body(body)?)
3947            },
3948            (
3949                http::StatusCode::from_u16(200u16).unwrap(),
3950                Some(mime::APPLICATION_JSON),
3951            ),
3952        ),
3953        crate::__combinators::Json::new,
3954    ))
3955}
3956future!(
3957    RetrieveModel,
3958    futures::future::AndThen<
3959        crate::__combinators::Send<Fut, B, E>,
3960        crate::__combinators::Json<B, E, crate::__types::Model>,
3961        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Model>,
3962    >,
3963    crate::__types::Model
3964);
3965#[doc = "Delete a fine-tuned model"]
3966pub fn delete_model<C, Fut, B, E>(
3967    client: C,
3968    params: &crate::__types::delete_model::Params,
3969) -> DeleteModel<Fut, B, E>
3970where
3971    C: FnOnce(http::Request<String>) -> Fut,
3972    Fut: Future<Output = Result<http::Response<B>, E>>,
3973    B: http_body::Body,
3974{
3975    DeleteModel(futures::TryFutureExt::and_then(
3976        crate::__combinators::Send::new(
3977            client,
3978            || {
3979                let path = {
3980                    #[serde_with::serde_as]
3981                    #[derive(serde :: Serialize)]
3982                    struct Query<'a> {
3983                        #[serde(skip_serializing)]
3984                        _phantom: std::marker::PhantomData<&'a ()>,
3985                    }
3986                    let crate::__types::delete_model::Params { model } = params;
3987                    #[allow(clippy::useless_format)]
3988                    let mut path = format!("/models/{model}");
3989                    let query = serde_urlencoded::to_string(Query {
3990                        _phantom: std::marker::PhantomData,
3991                    })?;
3992                    if !query.is_empty() {
3993                        path.push('?');
3994                        path.push_str(&query);
3995                    }
3996                    path
3997                };
3998                let body = String::new();
3999                Ok(http::Request::builder()
4000                    .method(http::Method::DELETE)
4001                    .uri(path)
4002                    .header(http::header::CONTENT_LENGTH, body.len())
4003                    .body(body)?)
4004            },
4005            (
4006                http::StatusCode::from_u16(200u16).unwrap(),
4007                Some(mime::APPLICATION_JSON),
4008            ),
4009        ),
4010        crate::__combinators::Json::new,
4011    ))
4012}
4013future!(
4014    DeleteModel,
4015    futures::future::AndThen<
4016        crate::__combinators::Send<Fut, B, E>,
4017        crate::__combinators::Json<B, E, crate::__types::DeleteModelResponse>,
4018        fn(
4019            http::Response<B>,
4020        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteModelResponse>,
4021    >,
4022    crate::__types::DeleteModelResponse
4023);
4024#[doc = "Create moderation"]
4025pub fn create_moderation<C, Fut, B, E>(
4026    client: C,
4027    request: &crate::__types::CreateModerationRequest,
4028) -> CreateModeration<Fut, B, E>
4029where
4030    C: FnOnce(http::Request<String>) -> Fut,
4031    Fut: Future<Output = Result<http::Response<B>, E>>,
4032    B: http_body::Body,
4033{
4034    CreateModeration(futures::TryFutureExt::and_then(
4035        crate::__combinators::Send::new(
4036            client,
4037            || {
4038                let path = "/moderations";
4039                let body = serde_json::to_string(request)?;
4040                Ok(http::Request::builder()
4041                    .method(http::Method::POST)
4042                    .uri(path)
4043                    .header(http::header::CONTENT_LENGTH, body.len())
4044                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4045                    .body(body)?)
4046            },
4047            (
4048                http::StatusCode::from_u16(200u16).unwrap(),
4049                Some(mime::APPLICATION_JSON),
4050            ),
4051        ),
4052        crate::__combinators::Json::new,
4053    ))
4054}
4055future!(
4056    CreateModeration,
4057    futures::future::AndThen<
4058        crate::__combinators::Send<Fut, B, E>,
4059        crate::__combinators::Json<B, E, crate::__types::CreateModerationResponse>,
4060        fn(
4061            http::Response<B>,
4062        ) -> crate::__combinators::Json<B, E, crate::__types::CreateModerationResponse>,
4063    >,
4064    crate::__types::CreateModerationResponse
4065);
4066#[doc = "List all organization and project API keys."]
4067pub fn admin_api_keys_list<C, Fut, B, E>(
4068    client: C,
4069    params: &crate::__types::admin_api_keys_list::Params,
4070) -> AdminApiKeysList<Fut, B, E>
4071where
4072    C: FnOnce(http::Request<String>) -> Fut,
4073    Fut: Future<Output = Result<http::Response<B>, E>>,
4074    B: http_body::Body,
4075{
4076    AdminApiKeysList(futures::TryFutureExt::and_then(
4077        crate::__combinators::Send::new(
4078            client,
4079            || {
4080                let path = {
4081                    #[serde_with::serde_as]
4082                    #[derive(serde :: Serialize)]
4083                    struct Query<'a> {
4084                        #[serde(rename = "after")]
4085                        #[serde(skip_serializing_if = "Option::is_none")]
4086                        after: &'a Option<String>,
4087                        #[serde(rename = "order")]
4088                        #[serde(skip_serializing_if = "Option::is_none")]
4089                        order: &'a Option<crate::__types::admin_api_keys_list::params::Order>,
4090                        #[serde(rename = "limit")]
4091                        #[serde(skip_serializing_if = "Option::is_none")]
4092                        limit: &'a Option<i64>,
4093                        #[serde(skip_serializing)]
4094                        _phantom: std::marker::PhantomData<&'a ()>,
4095                    }
4096                    let crate::__types::admin_api_keys_list::Params {
4097                        after,
4098                        order,
4099                        limit,
4100                    } = params;
4101                    #[allow(clippy::useless_format)]
4102                    let mut path = format!("/organization/admin_api_keys");
4103                    let query = serde_urlencoded::to_string(Query {
4104                        after,
4105                        order,
4106                        limit,
4107                        _phantom: std::marker::PhantomData,
4108                    })?;
4109                    if !query.is_empty() {
4110                        path.push('?');
4111                        path.push_str(&query);
4112                    }
4113                    path
4114                };
4115                let body = String::new();
4116                Ok(http::Request::builder()
4117                    .method(http::Method::GET)
4118                    .uri(path)
4119                    .header(http::header::CONTENT_LENGTH, body.len())
4120                    .body(body)?)
4121            },
4122            (
4123                http::StatusCode::from_u16(200u16).unwrap(),
4124                Some(mime::APPLICATION_JSON),
4125            ),
4126        ),
4127        crate::__combinators::Json::new,
4128    ))
4129}
4130future!(
4131    AdminApiKeysList,
4132    futures::future::AndThen<
4133        crate::__combinators::Send<Fut, B, E>,
4134        crate::__combinators::Json<B, E, crate::__types::ApiKeyList>,
4135        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ApiKeyList>,
4136    >,
4137    crate::__types::ApiKeyList
4138);
4139#[doc = "Create admin API key"]
4140pub fn admin_api_keys_create<C, Fut, B, E>(
4141    client: C,
4142    request: &crate::__types::admin_api_keys_create::Request,
4143) -> AdminApiKeysCreate<Fut, B, E>
4144where
4145    C: FnOnce(http::Request<String>) -> Fut,
4146    Fut: Future<Output = Result<http::Response<B>, E>>,
4147    B: http_body::Body,
4148{
4149    AdminApiKeysCreate(futures::TryFutureExt::and_then(
4150        crate::__combinators::Send::new(
4151            client,
4152            || {
4153                let path = "/organization/admin_api_keys";
4154                let body = serde_json::to_string(request)?;
4155                Ok(http::Request::builder()
4156                    .method(http::Method::POST)
4157                    .uri(path)
4158                    .header(http::header::CONTENT_LENGTH, body.len())
4159                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4160                    .body(body)?)
4161            },
4162            (
4163                http::StatusCode::from_u16(200u16).unwrap(),
4164                Some(mime::APPLICATION_JSON),
4165            ),
4166        ),
4167        crate::__combinators::Json::new,
4168    ))
4169}
4170future!(
4171    AdminApiKeysCreate,
4172    futures::future::AndThen<
4173        crate::__combinators::Send<Fut, B, E>,
4174        crate::__combinators::Json<B, E, crate::__types::AdminApiKey>,
4175        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::AdminApiKey>,
4176    >,
4177    crate::__types::AdminApiKey
4178);
4179#[doc = "Retrieve admin API key"]
4180pub fn admin_api_keys_get<C, Fut, B, E>(
4181    client: C,
4182    params: &crate::__types::admin_api_keys_get::Params,
4183) -> AdminApiKeysGet<Fut, B, E>
4184where
4185    C: FnOnce(http::Request<String>) -> Fut,
4186    Fut: Future<Output = Result<http::Response<B>, E>>,
4187    B: http_body::Body,
4188{
4189    AdminApiKeysGet(futures::TryFutureExt::and_then(
4190        crate::__combinators::Send::new(
4191            client,
4192            || {
4193                let path = {
4194                    #[serde_with::serde_as]
4195                    #[derive(serde :: Serialize)]
4196                    struct Query<'a> {
4197                        #[serde(skip_serializing)]
4198                        _phantom: std::marker::PhantomData<&'a ()>,
4199                    }
4200                    let crate::__types::admin_api_keys_get::Params { key_id } = params;
4201                    #[allow(clippy::useless_format)]
4202                    let mut path = format!("/organization/admin_api_keys/{key_id}");
4203                    let query = serde_urlencoded::to_string(Query {
4204                        _phantom: std::marker::PhantomData,
4205                    })?;
4206                    if !query.is_empty() {
4207                        path.push('?');
4208                        path.push_str(&query);
4209                    }
4210                    path
4211                };
4212                let body = String::new();
4213                Ok(http::Request::builder()
4214                    .method(http::Method::GET)
4215                    .uri(path)
4216                    .header(http::header::CONTENT_LENGTH, body.len())
4217                    .body(body)?)
4218            },
4219            (
4220                http::StatusCode::from_u16(200u16).unwrap(),
4221                Some(mime::APPLICATION_JSON),
4222            ),
4223        ),
4224        crate::__combinators::Json::new,
4225    ))
4226}
4227future!(
4228    AdminApiKeysGet,
4229    futures::future::AndThen<
4230        crate::__combinators::Send<Fut, B, E>,
4231        crate::__combinators::Json<B, E, crate::__types::AdminApiKey>,
4232        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::AdminApiKey>,
4233    >,
4234    crate::__types::AdminApiKey
4235);
4236#[doc = "Delete admin API key"]
4237pub fn admin_api_keys_delete<C, Fut, B, E>(
4238    client: C,
4239    params: &crate::__types::admin_api_keys_delete::Params,
4240) -> AdminApiKeysDelete<Fut, B, E>
4241where
4242    C: FnOnce(http::Request<String>) -> Fut,
4243    Fut: Future<Output = Result<http::Response<B>, E>>,
4244    B: http_body::Body,
4245{
4246    AdminApiKeysDelete(futures::TryFutureExt::and_then(
4247        crate::__combinators::Send::new(
4248            client,
4249            || {
4250                let path = {
4251                    #[serde_with::serde_as]
4252                    #[derive(serde :: Serialize)]
4253                    struct Query<'a> {
4254                        #[serde(skip_serializing)]
4255                        _phantom: std::marker::PhantomData<&'a ()>,
4256                    }
4257                    let crate::__types::admin_api_keys_delete::Params { key_id } = params;
4258                    #[allow(clippy::useless_format)]
4259                    let mut path = format!("/organization/admin_api_keys/{key_id}");
4260                    let query = serde_urlencoded::to_string(Query {
4261                        _phantom: std::marker::PhantomData,
4262                    })?;
4263                    if !query.is_empty() {
4264                        path.push('?');
4265                        path.push_str(&query);
4266                    }
4267                    path
4268                };
4269                let body = String::new();
4270                Ok(http::Request::builder()
4271                    .method(http::Method::DELETE)
4272                    .uri(path)
4273                    .header(http::header::CONTENT_LENGTH, body.len())
4274                    .body(body)?)
4275            },
4276            (
4277                http::StatusCode::from_u16(200u16).unwrap(),
4278                Some(mime::APPLICATION_JSON),
4279            ),
4280        ),
4281        crate::__combinators::Json::new,
4282    ))
4283}
4284future!(
4285    AdminApiKeysDelete,
4286    futures::future::AndThen<
4287        crate::__combinators::Send<Fut, B, E>,
4288        crate::__combinators::Json<B, E, crate::__types::admin_api_keys_delete::Response>,
4289        fn(
4290            http::Response<B>,
4291        )
4292            -> crate::__combinators::Json<B, E, crate::__types::admin_api_keys_delete::Response>,
4293    >,
4294    crate::__types::admin_api_keys_delete::Response
4295);
4296#[doc = "List audit logs"]
4297pub fn list_audit_logs<C, Fut, B, E>(
4298    client: C,
4299    params: &crate::__types::list_audit_logs::Params,
4300) -> ListAuditLogs<Fut, B, E>
4301where
4302    C: FnOnce(http::Request<String>) -> Fut,
4303    Fut: Future<Output = Result<http::Response<B>, E>>,
4304    B: http_body::Body,
4305{
4306    ListAuditLogs(futures::TryFutureExt::and_then(
4307        crate::__combinators::Send::new(
4308            client,
4309            || {
4310                let path = {
4311                    #[serde_with::serde_as]
4312                    #[derive(serde :: Serialize)]
4313                    struct Query<'a> {
4314                        #[serde(rename = "effective_at")]
4315                        #[serde(skip_serializing_if = "Option::is_none")]
4316                        effective_at:
4317                            &'a Option<crate::__types::list_audit_logs::params::EffectiveAt>,
4318                        #[serde(rename = "project_ids[]")]
4319                        #[serde(skip_serializing_if = "Option::is_none")]
4320                        project_ids: &'a Option<Vec<String>>,
4321                        #[serde(rename = "event_types[]")]
4322                        #[serde(skip_serializing_if = "Option::is_none")]
4323                        event_types: &'a Option<Vec<crate::__types::AuditLogEventType>>,
4324                        #[serde(rename = "actor_ids[]")]
4325                        #[serde(skip_serializing_if = "Option::is_none")]
4326                        actor_ids: &'a Option<Vec<String>>,
4327                        #[serde(rename = "actor_emails[]")]
4328                        #[serde(skip_serializing_if = "Option::is_none")]
4329                        actor_emails: &'a Option<Vec<String>>,
4330                        #[serde(rename = "resource_ids[]")]
4331                        #[serde(skip_serializing_if = "Option::is_none")]
4332                        resource_ids: &'a Option<Vec<String>>,
4333                        #[serde(rename = "limit")]
4334                        #[serde(skip_serializing_if = "Option::is_none")]
4335                        limit: &'a Option<i64>,
4336                        #[serde(rename = "after")]
4337                        #[serde(skip_serializing_if = "Option::is_none")]
4338                        after: &'a Option<String>,
4339                        #[serde(rename = "before")]
4340                        #[serde(skip_serializing_if = "Option::is_none")]
4341                        before: &'a Option<String>,
4342                        #[serde(skip_serializing)]
4343                        _phantom: std::marker::PhantomData<&'a ()>,
4344                    }
4345                    let crate::__types::list_audit_logs::Params {
4346                        effective_at,
4347                        project_ids,
4348                        event_types,
4349                        actor_ids,
4350                        actor_emails,
4351                        resource_ids,
4352                        limit,
4353                        after,
4354                        before,
4355                    } = params;
4356                    #[allow(clippy::useless_format)]
4357                    let mut path = format!("/organization/audit_logs");
4358                    let query = serde_urlencoded::to_string(Query {
4359                        effective_at,
4360                        project_ids,
4361                        event_types,
4362                        actor_ids,
4363                        actor_emails,
4364                        resource_ids,
4365                        limit,
4366                        after,
4367                        before,
4368                        _phantom: std::marker::PhantomData,
4369                    })?;
4370                    if !query.is_empty() {
4371                        path.push('?');
4372                        path.push_str(&query);
4373                    }
4374                    path
4375                };
4376                let body = String::new();
4377                Ok(http::Request::builder()
4378                    .method(http::Method::GET)
4379                    .uri(path)
4380                    .header(http::header::CONTENT_LENGTH, body.len())
4381                    .body(body)?)
4382            },
4383            (
4384                http::StatusCode::from_u16(200u16).unwrap(),
4385                Some(mime::APPLICATION_JSON),
4386            ),
4387        ),
4388        crate::__combinators::Json::new,
4389    ))
4390}
4391future!(
4392    ListAuditLogs,
4393    futures::future::AndThen<
4394        crate::__combinators::Send<Fut, B, E>,
4395        crate::__combinators::Json<B, E, crate::__types::ListAuditLogsResponse>,
4396        fn(
4397            http::Response<B>,
4398        ) -> crate::__combinators::Json<B, E, crate::__types::ListAuditLogsResponse>,
4399    >,
4400    crate::__types::ListAuditLogsResponse
4401);
4402#[doc = "List organization certificates"]
4403pub fn list_organization_certificates<C, Fut, B, E>(
4404    client: C,
4405    params: &crate::__types::list_organization_certificates::Params,
4406) -> ListOrganizationCertificates<Fut, B, E>
4407where
4408    C: FnOnce(http::Request<String>) -> Fut,
4409    Fut: Future<Output = Result<http::Response<B>, E>>,
4410    B: http_body::Body,
4411{
4412    ListOrganizationCertificates(futures::TryFutureExt::and_then(
4413        crate::__combinators::Send::new(
4414            client,
4415            || {
4416                let path = {
4417                    #[serde_with::serde_as]
4418                    #[derive(serde :: Serialize)]
4419                    struct Query<'a> {
4420                        #[serde(rename = "limit")]
4421                        #[serde(skip_serializing_if = "Option::is_none")]
4422                        limit: &'a Option<i64>,
4423                        #[serde(rename = "after")]
4424                        #[serde(skip_serializing_if = "Option::is_none")]
4425                        after: &'a Option<String>,
4426                        #[serde(rename = "order")]
4427                        #[serde(skip_serializing_if = "Option::is_none")]
4428                        order: &'a Option<
4429                            crate::__types::list_organization_certificates::params::Order,
4430                        >,
4431                        #[serde(skip_serializing)]
4432                        _phantom: std::marker::PhantomData<&'a ()>,
4433                    }
4434                    let crate::__types::list_organization_certificates::Params {
4435                        limit,
4436                        after,
4437                        order,
4438                    } = params;
4439                    #[allow(clippy::useless_format)]
4440                    let mut path = format!("/organization/certificates");
4441                    let query = serde_urlencoded::to_string(Query {
4442                        limit,
4443                        after,
4444                        order,
4445                        _phantom: std::marker::PhantomData,
4446                    })?;
4447                    if !query.is_empty() {
4448                        path.push('?');
4449                        path.push_str(&query);
4450                    }
4451                    path
4452                };
4453                let body = String::new();
4454                Ok(http::Request::builder()
4455                    .method(http::Method::GET)
4456                    .uri(path)
4457                    .header(http::header::CONTENT_LENGTH, body.len())
4458                    .body(body)?)
4459            },
4460            (
4461                http::StatusCode::from_u16(200u16).unwrap(),
4462                Some(mime::APPLICATION_JSON),
4463            ),
4464        ),
4465        crate::__combinators::Json::new,
4466    ))
4467}
4468future!(
4469    ListOrganizationCertificates,
4470    futures::future::AndThen<
4471        crate::__combinators::Send<Fut, B, E>,
4472        crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
4473        fn(
4474            http::Response<B>,
4475        ) -> crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
4476    >,
4477    crate::__types::ListCertificatesResponse
4478);
4479#[doc = "Upload certificate"]
4480pub fn upload_certificate<C, Fut, B, E>(
4481    client: C,
4482    request: &crate::__types::UploadCertificateRequest,
4483) -> UploadCertificate<Fut, B, E>
4484where
4485    C: FnOnce(http::Request<String>) -> Fut,
4486    Fut: Future<Output = Result<http::Response<B>, E>>,
4487    B: http_body::Body,
4488{
4489    UploadCertificate(futures::TryFutureExt::and_then(
4490        crate::__combinators::Send::new(
4491            client,
4492            || {
4493                let path = "/organization/certificates";
4494                let body = serde_json::to_string(request)?;
4495                Ok(http::Request::builder()
4496                    .method(http::Method::POST)
4497                    .uri(path)
4498                    .header(http::header::CONTENT_LENGTH, body.len())
4499                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4500                    .body(body)?)
4501            },
4502            (
4503                http::StatusCode::from_u16(200u16).unwrap(),
4504                Some(mime::APPLICATION_JSON),
4505            ),
4506        ),
4507        crate::__combinators::Json::new,
4508    ))
4509}
4510future!(
4511    UploadCertificate,
4512    futures::future::AndThen<
4513        crate::__combinators::Send<Fut, B, E>,
4514        crate::__combinators::Json<B, E, crate::__types::Certificate>,
4515        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Certificate>,
4516    >,
4517    crate::__types::Certificate
4518);
4519#[doc = "Activate certificates for organization"]
4520pub fn activate_organization_certificates<C, Fut, B, E>(
4521    client: C,
4522    request: &crate::__types::ToggleCertificatesRequest,
4523) -> ActivateOrganizationCertificates<Fut, B, E>
4524where
4525    C: FnOnce(http::Request<String>) -> Fut,
4526    Fut: Future<Output = Result<http::Response<B>, E>>,
4527    B: http_body::Body,
4528{
4529    ActivateOrganizationCertificates(futures::TryFutureExt::and_then(
4530        crate::__combinators::Send::new(
4531            client,
4532            || {
4533                let path = "/organization/certificates/activate";
4534                let body = serde_json::to_string(request)?;
4535                Ok(http::Request::builder()
4536                    .method(http::Method::POST)
4537                    .uri(path)
4538                    .header(http::header::CONTENT_LENGTH, body.len())
4539                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4540                    .body(body)?)
4541            },
4542            (
4543                http::StatusCode::from_u16(200u16).unwrap(),
4544                Some(mime::APPLICATION_JSON),
4545            ),
4546        ),
4547        crate::__combinators::Json::new,
4548    ))
4549}
4550future!(
4551    ActivateOrganizationCertificates,
4552    futures::future::AndThen<
4553        crate::__combinators::Send<Fut, B, E>,
4554        crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
4555        fn(
4556            http::Response<B>,
4557        ) -> crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
4558    >,
4559    crate::__types::ListCertificatesResponse
4560);
4561#[doc = "Deactivate certificates for organization"]
4562pub fn deactivate_organization_certificates<C, Fut, B, E>(
4563    client: C,
4564    request: &crate::__types::ToggleCertificatesRequest,
4565) -> DeactivateOrganizationCertificates<Fut, B, E>
4566where
4567    C: FnOnce(http::Request<String>) -> Fut,
4568    Fut: Future<Output = Result<http::Response<B>, E>>,
4569    B: http_body::Body,
4570{
4571    DeactivateOrganizationCertificates(futures::TryFutureExt::and_then(
4572        crate::__combinators::Send::new(
4573            client,
4574            || {
4575                let path = "/organization/certificates/deactivate";
4576                let body = serde_json::to_string(request)?;
4577                Ok(http::Request::builder()
4578                    .method(http::Method::POST)
4579                    .uri(path)
4580                    .header(http::header::CONTENT_LENGTH, body.len())
4581                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4582                    .body(body)?)
4583            },
4584            (
4585                http::StatusCode::from_u16(200u16).unwrap(),
4586                Some(mime::APPLICATION_JSON),
4587            ),
4588        ),
4589        crate::__combinators::Json::new,
4590    ))
4591}
4592future!(
4593    DeactivateOrganizationCertificates,
4594    futures::future::AndThen<
4595        crate::__combinators::Send<Fut, B, E>,
4596        crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
4597        fn(
4598            http::Response<B>,
4599        ) -> crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
4600    >,
4601    crate::__types::ListCertificatesResponse
4602);
4603#[doc = "Get certificate"]
4604pub fn get_certificate<C, Fut, B, E>(
4605    client: C,
4606    params: &crate::__types::get_certificate::Params,
4607) -> GetCertificate<Fut, B, E>
4608where
4609    C: FnOnce(http::Request<String>) -> Fut,
4610    Fut: Future<Output = Result<http::Response<B>, E>>,
4611    B: http_body::Body,
4612{
4613    GetCertificate(futures::TryFutureExt::and_then(
4614        crate::__combinators::Send::new(
4615            client,
4616            || {
4617                let path = {
4618                    #[serde_with::serde_as]
4619                    #[derive(serde :: Serialize)]
4620                    struct Query<'a> {
4621                        #[serde(rename = "include")]
4622                        #[serde(skip_serializing_if = "Option::is_none")]
4623                        include:
4624                            &'a Option<Vec<crate::__types::get_certificate::params::include::Item>>,
4625                        #[serde(skip_serializing)]
4626                        _phantom: std::marker::PhantomData<&'a ()>,
4627                    }
4628                    let crate::__types::get_certificate::Params {
4629                        certificate_id,
4630                        include,
4631                    } = params;
4632                    #[allow(clippy::useless_format)]
4633                    let mut path = format!("/organization/certificates/{certificate_id}");
4634                    let query = serde_urlencoded::to_string(Query {
4635                        include,
4636                        _phantom: std::marker::PhantomData,
4637                    })?;
4638                    if !query.is_empty() {
4639                        path.push('?');
4640                        path.push_str(&query);
4641                    }
4642                    path
4643                };
4644                let body = String::new();
4645                Ok(http::Request::builder()
4646                    .method(http::Method::GET)
4647                    .uri(path)
4648                    .header(http::header::CONTENT_LENGTH, body.len())
4649                    .body(body)?)
4650            },
4651            (
4652                http::StatusCode::from_u16(200u16).unwrap(),
4653                Some(mime::APPLICATION_JSON),
4654            ),
4655        ),
4656        crate::__combinators::Json::new,
4657    ))
4658}
4659future!(
4660    GetCertificate,
4661    futures::future::AndThen<
4662        crate::__combinators::Send<Fut, B, E>,
4663        crate::__combinators::Json<B, E, crate::__types::Certificate>,
4664        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Certificate>,
4665    >,
4666    crate::__types::Certificate
4667);
4668#[doc = "Modify certificate"]
4669pub fn modify_certificate<C, Fut, B, E>(
4670    client: C,
4671    request: &crate::__types::ModifyCertificateRequest,
4672) -> ModifyCertificate<Fut, B, E>
4673where
4674    C: FnOnce(http::Request<String>) -> Fut,
4675    Fut: Future<Output = Result<http::Response<B>, E>>,
4676    B: http_body::Body,
4677{
4678    ModifyCertificate(futures::TryFutureExt::and_then(
4679        crate::__combinators::Send::new(
4680            client,
4681            || {
4682                let path = "/organization/certificates/{certificate_id}";
4683                let body = serde_json::to_string(request)?;
4684                Ok(http::Request::builder()
4685                    .method(http::Method::POST)
4686                    .uri(path)
4687                    .header(http::header::CONTENT_LENGTH, body.len())
4688                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4689                    .body(body)?)
4690            },
4691            (
4692                http::StatusCode::from_u16(200u16).unwrap(),
4693                Some(mime::APPLICATION_JSON),
4694            ),
4695        ),
4696        crate::__combinators::Json::new,
4697    ))
4698}
4699future!(
4700    ModifyCertificate,
4701    futures::future::AndThen<
4702        crate::__combinators::Send<Fut, B, E>,
4703        crate::__combinators::Json<B, E, crate::__types::Certificate>,
4704        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Certificate>,
4705    >,
4706    crate::__types::Certificate
4707);
4708#[doc = "Delete certificate"]
4709pub fn delete_certificate<C, Fut, B, E>(client: C) -> DeleteCertificate<Fut, B, E>
4710where
4711    C: FnOnce(http::Request<String>) -> Fut,
4712    Fut: Future<Output = Result<http::Response<B>, E>>,
4713    B: http_body::Body,
4714{
4715    DeleteCertificate(futures::TryFutureExt::and_then(
4716        crate::__combinators::Send::new(
4717            client,
4718            || {
4719                let path = "/organization/certificates/{certificate_id}";
4720                let body = String::new();
4721                Ok(http::Request::builder()
4722                    .method(http::Method::DELETE)
4723                    .uri(path)
4724                    .header(http::header::CONTENT_LENGTH, body.len())
4725                    .body(body)?)
4726            },
4727            (
4728                http::StatusCode::from_u16(200u16).unwrap(),
4729                Some(mime::APPLICATION_JSON),
4730            ),
4731        ),
4732        crate::__combinators::Json::new,
4733    ))
4734}
4735future!(
4736    DeleteCertificate,
4737    futures::future::AndThen<
4738        crate::__combinators::Send<Fut, B, E>,
4739        crate::__combinators::Json<B, E, crate::__types::DeleteCertificateResponse>,
4740        fn(
4741            http::Response<B>,
4742        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteCertificateResponse>,
4743    >,
4744    crate::__types::DeleteCertificateResponse
4745);
4746#[doc = "Costs"]
4747pub fn usage_costs<C, Fut, B, E>(
4748    client: C,
4749    params: &crate::__types::usage_costs::Params,
4750) -> UsageCosts<Fut, B, E>
4751where
4752    C: FnOnce(http::Request<String>) -> Fut,
4753    Fut: Future<Output = Result<http::Response<B>, E>>,
4754    B: http_body::Body,
4755{
4756    UsageCosts(futures::TryFutureExt::and_then(
4757        crate::__combinators::Send::new(
4758            client,
4759            || {
4760                let path = {
4761                    #[serde_with::serde_as]
4762                    #[derive(serde :: Serialize)]
4763                    struct Query<'a> {
4764                        #[serde(rename = "start_time")]
4765                        start_time: &'a i64,
4766                        #[serde(rename = "end_time")]
4767                        #[serde(skip_serializing_if = "Option::is_none")]
4768                        end_time: &'a Option<i64>,
4769                        #[serde(rename = "bucket_width")]
4770                        #[serde(skip_serializing_if = "Option::is_none")]
4771                        bucket_width: &'a Option<crate::__types::usage_costs::params::BucketWidth>,
4772                        #[serde(rename = "project_ids")]
4773                        #[serde(skip_serializing_if = "Option::is_none")]
4774                        project_ids: &'a Option<Vec<String>>,
4775                        #[serde(rename = "group_by")]
4776                        #[serde(skip_serializing_if = "Option::is_none")]
4777                        group_by:
4778                            &'a Option<Vec<crate::__types::usage_costs::params::group_by::Item>>,
4779                        #[serde(rename = "limit")]
4780                        #[serde(skip_serializing_if = "Option::is_none")]
4781                        limit: &'a Option<i64>,
4782                        #[serde(rename = "page")]
4783                        #[serde(skip_serializing_if = "Option::is_none")]
4784                        page: &'a Option<String>,
4785                        #[serde(skip_serializing)]
4786                        _phantom: std::marker::PhantomData<&'a ()>,
4787                    }
4788                    let crate::__types::usage_costs::Params {
4789                        start_time,
4790                        end_time,
4791                        bucket_width,
4792                        project_ids,
4793                        group_by,
4794                        limit,
4795                        page,
4796                    } = params;
4797                    #[allow(clippy::useless_format)]
4798                    let mut path = format!("/organization/costs");
4799                    let query = serde_urlencoded::to_string(Query {
4800                        start_time,
4801                        end_time,
4802                        bucket_width,
4803                        project_ids,
4804                        group_by,
4805                        limit,
4806                        page,
4807                        _phantom: std::marker::PhantomData,
4808                    })?;
4809                    if !query.is_empty() {
4810                        path.push('?');
4811                        path.push_str(&query);
4812                    }
4813                    path
4814                };
4815                let body = String::new();
4816                Ok(http::Request::builder()
4817                    .method(http::Method::GET)
4818                    .uri(path)
4819                    .header(http::header::CONTENT_LENGTH, body.len())
4820                    .body(body)?)
4821            },
4822            (
4823                http::StatusCode::from_u16(200u16).unwrap(),
4824                Some(mime::APPLICATION_JSON),
4825            ),
4826        ),
4827        crate::__combinators::Json::new,
4828    ))
4829}
4830future!(
4831    UsageCosts,
4832    futures::future::AndThen<
4833        crate::__combinators::Send<Fut, B, E>,
4834        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
4835        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
4836    >,
4837    crate::__types::UsageResponse
4838);
4839#[doc = "List invites"]
4840pub fn list_invites<C, Fut, B, E>(
4841    client: C,
4842    params: &crate::__types::list_invites::Params,
4843) -> ListInvites<Fut, B, E>
4844where
4845    C: FnOnce(http::Request<String>) -> Fut,
4846    Fut: Future<Output = Result<http::Response<B>, E>>,
4847    B: http_body::Body,
4848{
4849    ListInvites(futures::TryFutureExt::and_then(
4850        crate::__combinators::Send::new(
4851            client,
4852            || {
4853                let path = {
4854                    #[serde_with::serde_as]
4855                    #[derive(serde :: Serialize)]
4856                    struct Query<'a> {
4857                        #[serde(rename = "limit")]
4858                        #[serde(skip_serializing_if = "Option::is_none")]
4859                        limit: &'a Option<i64>,
4860                        #[serde(rename = "after")]
4861                        #[serde(skip_serializing_if = "Option::is_none")]
4862                        after: &'a Option<String>,
4863                        #[serde(skip_serializing)]
4864                        _phantom: std::marker::PhantomData<&'a ()>,
4865                    }
4866                    let crate::__types::list_invites::Params { limit, after } = params;
4867                    #[allow(clippy::useless_format)]
4868                    let mut path = format!("/organization/invites");
4869                    let query = serde_urlencoded::to_string(Query {
4870                        limit,
4871                        after,
4872                        _phantom: std::marker::PhantomData,
4873                    })?;
4874                    if !query.is_empty() {
4875                        path.push('?');
4876                        path.push_str(&query);
4877                    }
4878                    path
4879                };
4880                let body = String::new();
4881                Ok(http::Request::builder()
4882                    .method(http::Method::GET)
4883                    .uri(path)
4884                    .header(http::header::CONTENT_LENGTH, body.len())
4885                    .body(body)?)
4886            },
4887            (
4888                http::StatusCode::from_u16(200u16).unwrap(),
4889                Some(mime::APPLICATION_JSON),
4890            ),
4891        ),
4892        crate::__combinators::Json::new,
4893    ))
4894}
4895future!(
4896    ListInvites,
4897    futures::future::AndThen<
4898        crate::__combinators::Send<Fut, B, E>,
4899        crate::__combinators::Json<B, E, crate::__types::InviteListResponse>,
4900        fn(
4901            http::Response<B>,
4902        ) -> crate::__combinators::Json<B, E, crate::__types::InviteListResponse>,
4903    >,
4904    crate::__types::InviteListResponse
4905);
4906#[doc = "Create invite"]
4907pub fn invite_user<C, Fut, B, E>(
4908    client: C,
4909    request: &crate::__types::InviteRequest,
4910) -> InviteUser<Fut, B, E>
4911where
4912    C: FnOnce(http::Request<String>) -> Fut,
4913    Fut: Future<Output = Result<http::Response<B>, E>>,
4914    B: http_body::Body,
4915{
4916    InviteUser(futures::TryFutureExt::and_then(
4917        crate::__combinators::Send::new(
4918            client,
4919            || {
4920                let path = "/organization/invites";
4921                let body = serde_json::to_string(request)?;
4922                Ok(http::Request::builder()
4923                    .method(http::Method::POST)
4924                    .uri(path)
4925                    .header(http::header::CONTENT_LENGTH, body.len())
4926                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
4927                    .body(body)?)
4928            },
4929            (
4930                http::StatusCode::from_u16(200u16).unwrap(),
4931                Some(mime::APPLICATION_JSON),
4932            ),
4933        ),
4934        crate::__combinators::Json::new,
4935    ))
4936}
4937future!(
4938    InviteUser,
4939    futures::future::AndThen<
4940        crate::__combinators::Send<Fut, B, E>,
4941        crate::__combinators::Json<B, E, crate::__types::Invite>,
4942        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Invite>,
4943    >,
4944    crate::__types::Invite
4945);
4946#[doc = "Retrieve invite"]
4947pub fn retrieve_invite<C, Fut, B, E>(
4948    client: C,
4949    params: &crate::__types::retrieve_invite::Params,
4950) -> RetrieveInvite<Fut, B, E>
4951where
4952    C: FnOnce(http::Request<String>) -> Fut,
4953    Fut: Future<Output = Result<http::Response<B>, E>>,
4954    B: http_body::Body,
4955{
4956    RetrieveInvite(futures::TryFutureExt::and_then(
4957        crate::__combinators::Send::new(
4958            client,
4959            || {
4960                let path = {
4961                    #[serde_with::serde_as]
4962                    #[derive(serde :: Serialize)]
4963                    struct Query<'a> {
4964                        #[serde(skip_serializing)]
4965                        _phantom: std::marker::PhantomData<&'a ()>,
4966                    }
4967                    let crate::__types::retrieve_invite::Params { invite_id } = params;
4968                    #[allow(clippy::useless_format)]
4969                    let mut path = format!("/organization/invites/{invite_id}");
4970                    let query = serde_urlencoded::to_string(Query {
4971                        _phantom: std::marker::PhantomData,
4972                    })?;
4973                    if !query.is_empty() {
4974                        path.push('?');
4975                        path.push_str(&query);
4976                    }
4977                    path
4978                };
4979                let body = String::new();
4980                Ok(http::Request::builder()
4981                    .method(http::Method::GET)
4982                    .uri(path)
4983                    .header(http::header::CONTENT_LENGTH, body.len())
4984                    .body(body)?)
4985            },
4986            (
4987                http::StatusCode::from_u16(200u16).unwrap(),
4988                Some(mime::APPLICATION_JSON),
4989            ),
4990        ),
4991        crate::__combinators::Json::new,
4992    ))
4993}
4994future!(
4995    RetrieveInvite,
4996    futures::future::AndThen<
4997        crate::__combinators::Send<Fut, B, E>,
4998        crate::__combinators::Json<B, E, crate::__types::Invite>,
4999        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Invite>,
5000    >,
5001    crate::__types::Invite
5002);
5003#[doc = "Delete invite"]
5004pub fn delete_invite<C, Fut, B, E>(
5005    client: C,
5006    params: &crate::__types::delete_invite::Params,
5007) -> DeleteInvite<Fut, B, E>
5008where
5009    C: FnOnce(http::Request<String>) -> Fut,
5010    Fut: Future<Output = Result<http::Response<B>, E>>,
5011    B: http_body::Body,
5012{
5013    DeleteInvite(futures::TryFutureExt::and_then(
5014        crate::__combinators::Send::new(
5015            client,
5016            || {
5017                let path = {
5018                    #[serde_with::serde_as]
5019                    #[derive(serde :: Serialize)]
5020                    struct Query<'a> {
5021                        #[serde(skip_serializing)]
5022                        _phantom: std::marker::PhantomData<&'a ()>,
5023                    }
5024                    let crate::__types::delete_invite::Params { invite_id } = params;
5025                    #[allow(clippy::useless_format)]
5026                    let mut path = format!("/organization/invites/{invite_id}");
5027                    let query = serde_urlencoded::to_string(Query {
5028                        _phantom: std::marker::PhantomData,
5029                    })?;
5030                    if !query.is_empty() {
5031                        path.push('?');
5032                        path.push_str(&query);
5033                    }
5034                    path
5035                };
5036                let body = String::new();
5037                Ok(http::Request::builder()
5038                    .method(http::Method::DELETE)
5039                    .uri(path)
5040                    .header(http::header::CONTENT_LENGTH, body.len())
5041                    .body(body)?)
5042            },
5043            (
5044                http::StatusCode::from_u16(200u16).unwrap(),
5045                Some(mime::APPLICATION_JSON),
5046            ),
5047        ),
5048        crate::__combinators::Json::new,
5049    ))
5050}
5051future!(
5052    DeleteInvite,
5053    futures::future::AndThen<
5054        crate::__combinators::Send<Fut, B, E>,
5055        crate::__combinators::Json<B, E, crate::__types::InviteDeleteResponse>,
5056        fn(
5057            http::Response<B>,
5058        ) -> crate::__combinators::Json<B, E, crate::__types::InviteDeleteResponse>,
5059    >,
5060    crate::__types::InviteDeleteResponse
5061);
5062#[doc = "List projects"]
5063pub fn list_projects<C, Fut, B, E>(
5064    client: C,
5065    params: &crate::__types::list_projects::Params,
5066) -> ListProjects<Fut, B, E>
5067where
5068    C: FnOnce(http::Request<String>) -> Fut,
5069    Fut: Future<Output = Result<http::Response<B>, E>>,
5070    B: http_body::Body,
5071{
5072    ListProjects(futures::TryFutureExt::and_then(
5073        crate::__combinators::Send::new(
5074            client,
5075            || {
5076                let path = {
5077                    #[serde_with::serde_as]
5078                    #[derive(serde :: Serialize)]
5079                    struct Query<'a> {
5080                        #[serde(rename = "limit")]
5081                        #[serde(skip_serializing_if = "Option::is_none")]
5082                        limit: &'a Option<i64>,
5083                        #[serde(rename = "after")]
5084                        #[serde(skip_serializing_if = "Option::is_none")]
5085                        after: &'a Option<String>,
5086                        #[serde(rename = "include_archived")]
5087                        #[serde(skip_serializing_if = "Option::is_none")]
5088                        include_archived: &'a Option<bool>,
5089                        #[serde(skip_serializing)]
5090                        _phantom: std::marker::PhantomData<&'a ()>,
5091                    }
5092                    let crate::__types::list_projects::Params {
5093                        limit,
5094                        after,
5095                        include_archived,
5096                    } = params;
5097                    #[allow(clippy::useless_format)]
5098                    let mut path = format!("/organization/projects");
5099                    let query = serde_urlencoded::to_string(Query {
5100                        limit,
5101                        after,
5102                        include_archived,
5103                        _phantom: std::marker::PhantomData,
5104                    })?;
5105                    if !query.is_empty() {
5106                        path.push('?');
5107                        path.push_str(&query);
5108                    }
5109                    path
5110                };
5111                let body = String::new();
5112                Ok(http::Request::builder()
5113                    .method(http::Method::GET)
5114                    .uri(path)
5115                    .header(http::header::CONTENT_LENGTH, body.len())
5116                    .body(body)?)
5117            },
5118            (
5119                http::StatusCode::from_u16(200u16).unwrap(),
5120                Some(mime::APPLICATION_JSON),
5121            ),
5122        ),
5123        crate::__combinators::Json::new,
5124    ))
5125}
5126future!(
5127    ListProjects,
5128    futures::future::AndThen<
5129        crate::__combinators::Send<Fut, B, E>,
5130        crate::__combinators::Json<B, E, crate::__types::ProjectListResponse>,
5131        fn(
5132            http::Response<B>,
5133        ) -> crate::__combinators::Json<B, E, crate::__types::ProjectListResponse>,
5134    >,
5135    crate::__types::ProjectListResponse
5136);
5137#[doc = "Create project"]
5138pub fn create_project<C, Fut, B, E>(
5139    client: C,
5140    request: &crate::__types::ProjectCreateRequest,
5141) -> CreateProject<Fut, B, E>
5142where
5143    C: FnOnce(http::Request<String>) -> Fut,
5144    Fut: Future<Output = Result<http::Response<B>, E>>,
5145    B: http_body::Body,
5146{
5147    CreateProject(futures::TryFutureExt::and_then(
5148        crate::__combinators::Send::new(
5149            client,
5150            || {
5151                let path = "/organization/projects";
5152                let body = serde_json::to_string(request)?;
5153                Ok(http::Request::builder()
5154                    .method(http::Method::POST)
5155                    .uri(path)
5156                    .header(http::header::CONTENT_LENGTH, body.len())
5157                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
5158                    .body(body)?)
5159            },
5160            (
5161                http::StatusCode::from_u16(200u16).unwrap(),
5162                Some(mime::APPLICATION_JSON),
5163            ),
5164        ),
5165        crate::__combinators::Json::new,
5166    ))
5167}
5168future!(
5169    CreateProject,
5170    futures::future::AndThen<
5171        crate::__combinators::Send<Fut, B, E>,
5172        crate::__combinators::Json<B, E, crate::__types::Project>,
5173        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Project>,
5174    >,
5175    crate::__types::Project
5176);
5177#[doc = "Retrieve project"]
5178pub fn retrieve_project<C, Fut, B, E>(
5179    client: C,
5180    params: &crate::__types::retrieve_project::Params,
5181) -> RetrieveProject<Fut, B, E>
5182where
5183    C: FnOnce(http::Request<String>) -> Fut,
5184    Fut: Future<Output = Result<http::Response<B>, E>>,
5185    B: http_body::Body,
5186{
5187    RetrieveProject(futures::TryFutureExt::and_then(
5188        crate::__combinators::Send::new(
5189            client,
5190            || {
5191                let path = {
5192                    #[serde_with::serde_as]
5193                    #[derive(serde :: Serialize)]
5194                    struct Query<'a> {
5195                        #[serde(skip_serializing)]
5196                        _phantom: std::marker::PhantomData<&'a ()>,
5197                    }
5198                    let crate::__types::retrieve_project::Params { project_id } = params;
5199                    #[allow(clippy::useless_format)]
5200                    let mut path = format!("/organization/projects/{project_id}");
5201                    let query = serde_urlencoded::to_string(Query {
5202                        _phantom: std::marker::PhantomData,
5203                    })?;
5204                    if !query.is_empty() {
5205                        path.push('?');
5206                        path.push_str(&query);
5207                    }
5208                    path
5209                };
5210                let body = String::new();
5211                Ok(http::Request::builder()
5212                    .method(http::Method::GET)
5213                    .uri(path)
5214                    .header(http::header::CONTENT_LENGTH, body.len())
5215                    .body(body)?)
5216            },
5217            (
5218                http::StatusCode::from_u16(200u16).unwrap(),
5219                Some(mime::APPLICATION_JSON),
5220            ),
5221        ),
5222        crate::__combinators::Json::new,
5223    ))
5224}
5225future!(
5226    RetrieveProject,
5227    futures::future::AndThen<
5228        crate::__combinators::Send<Fut, B, E>,
5229        crate::__combinators::Json<B, E, crate::__types::Project>,
5230        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Project>,
5231    >,
5232    crate::__types::Project
5233);
5234#[doc = "Modify project"]
5235pub fn modify_project<C, Fut, B, E>(
5236    client: C,
5237    params: &crate::__types::modify_project::Params,
5238    request: &crate::__types::ProjectUpdateRequest,
5239) -> ModifyProject<Fut, B, E>
5240where
5241    C: FnOnce(http::Request<String>) -> Fut,
5242    Fut: Future<Output = Result<http::Response<B>, E>>,
5243    B: http_body::Body,
5244{
5245    ModifyProject(futures::TryFutureExt::and_then(
5246        crate::__combinators::Send::new(
5247            client,
5248            || {
5249                let path = {
5250                    #[serde_with::serde_as]
5251                    #[derive(serde :: Serialize)]
5252                    struct Query<'a> {
5253                        #[serde(skip_serializing)]
5254                        _phantom: std::marker::PhantomData<&'a ()>,
5255                    }
5256                    let crate::__types::modify_project::Params { project_id } = params;
5257                    #[allow(clippy::useless_format)]
5258                    let mut path = format!("/organization/projects/{project_id}");
5259                    let query = serde_urlencoded::to_string(Query {
5260                        _phantom: std::marker::PhantomData,
5261                    })?;
5262                    if !query.is_empty() {
5263                        path.push('?');
5264                        path.push_str(&query);
5265                    }
5266                    path
5267                };
5268                let body = serde_json::to_string(request)?;
5269                Ok(http::Request::builder()
5270                    .method(http::Method::POST)
5271                    .uri(path)
5272                    .header(http::header::CONTENT_LENGTH, body.len())
5273                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
5274                    .body(body)?)
5275            },
5276            (
5277                http::StatusCode::from_u16(200u16).unwrap(),
5278                Some(mime::APPLICATION_JSON),
5279            ),
5280        ),
5281        crate::__combinators::Json::new,
5282    ))
5283}
5284future!(
5285    ModifyProject,
5286    futures::future::AndThen<
5287        crate::__combinators::Send<Fut, B, E>,
5288        crate::__combinators::Json<B, E, crate::__types::Project>,
5289        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Project>,
5290    >,
5291    crate::__types::Project
5292);
5293#[doc = "List project API keys"]
5294pub fn list_project_api_keys<C, Fut, B, E>(
5295    client: C,
5296    params: &crate::__types::list_project_api_keys::Params,
5297) -> ListProjectApiKeys<Fut, B, E>
5298where
5299    C: FnOnce(http::Request<String>) -> Fut,
5300    Fut: Future<Output = Result<http::Response<B>, E>>,
5301    B: http_body::Body,
5302{
5303    ListProjectApiKeys(futures::TryFutureExt::and_then(
5304        crate::__combinators::Send::new(
5305            client,
5306            || {
5307                let path = {
5308                    #[serde_with::serde_as]
5309                    #[derive(serde :: Serialize)]
5310                    struct Query<'a> {
5311                        #[serde(rename = "limit")]
5312                        #[serde(skip_serializing_if = "Option::is_none")]
5313                        limit: &'a Option<i64>,
5314                        #[serde(rename = "after")]
5315                        #[serde(skip_serializing_if = "Option::is_none")]
5316                        after: &'a Option<String>,
5317                        #[serde(skip_serializing)]
5318                        _phantom: std::marker::PhantomData<&'a ()>,
5319                    }
5320                    let crate::__types::list_project_api_keys::Params {
5321                        project_id,
5322                        limit,
5323                        after,
5324                    } = params;
5325                    #[allow(clippy::useless_format)]
5326                    let mut path = format!("/organization/projects/{project_id}/api_keys");
5327                    let query = serde_urlencoded::to_string(Query {
5328                        limit,
5329                        after,
5330                        _phantom: std::marker::PhantomData,
5331                    })?;
5332                    if !query.is_empty() {
5333                        path.push('?');
5334                        path.push_str(&query);
5335                    }
5336                    path
5337                };
5338                let body = String::new();
5339                Ok(http::Request::builder()
5340                    .method(http::Method::GET)
5341                    .uri(path)
5342                    .header(http::header::CONTENT_LENGTH, body.len())
5343                    .body(body)?)
5344            },
5345            (
5346                http::StatusCode::from_u16(200u16).unwrap(),
5347                Some(mime::APPLICATION_JSON),
5348            ),
5349        ),
5350        crate::__combinators::Json::new,
5351    ))
5352}
5353future!(
5354    ListProjectApiKeys,
5355    futures::future::AndThen<
5356        crate::__combinators::Send<Fut, B, E>,
5357        crate::__combinators::Json<B, E, crate::__types::ProjectApiKeyListResponse>,
5358        fn(
5359            http::Response<B>,
5360        ) -> crate::__combinators::Json<B, E, crate::__types::ProjectApiKeyListResponse>,
5361    >,
5362    crate::__types::ProjectApiKeyListResponse
5363);
5364#[doc = "Retrieve project API key"]
5365pub fn retrieve_project_api_key<C, Fut, B, E>(
5366    client: C,
5367    params: &crate::__types::retrieve_project_api_key::Params,
5368) -> RetrieveProjectApiKey<Fut, B, E>
5369where
5370    C: FnOnce(http::Request<String>) -> Fut,
5371    Fut: Future<Output = Result<http::Response<B>, E>>,
5372    B: http_body::Body,
5373{
5374    RetrieveProjectApiKey(futures::TryFutureExt::and_then(
5375        crate::__combinators::Send::new(
5376            client,
5377            || {
5378                let path = {
5379                    #[serde_with::serde_as]
5380                    #[derive(serde :: Serialize)]
5381                    struct Query<'a> {
5382                        #[serde(skip_serializing)]
5383                        _phantom: std::marker::PhantomData<&'a ()>,
5384                    }
5385                    let crate::__types::retrieve_project_api_key::Params { project_id, key_id } =
5386                        params;
5387                    #[allow(clippy::useless_format)]
5388                    let mut path = format!("/organization/projects/{project_id}/api_keys/{key_id}");
5389                    let query = serde_urlencoded::to_string(Query {
5390                        _phantom: std::marker::PhantomData,
5391                    })?;
5392                    if !query.is_empty() {
5393                        path.push('?');
5394                        path.push_str(&query);
5395                    }
5396                    path
5397                };
5398                let body = String::new();
5399                Ok(http::Request::builder()
5400                    .method(http::Method::GET)
5401                    .uri(path)
5402                    .header(http::header::CONTENT_LENGTH, body.len())
5403                    .body(body)?)
5404            },
5405            (
5406                http::StatusCode::from_u16(200u16).unwrap(),
5407                Some(mime::APPLICATION_JSON),
5408            ),
5409        ),
5410        crate::__combinators::Json::new,
5411    ))
5412}
5413future!(
5414    RetrieveProjectApiKey,
5415    futures::future::AndThen<
5416        crate::__combinators::Send<Fut, B, E>,
5417        crate::__combinators::Json<B, E, crate::__types::ProjectApiKey>,
5418        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ProjectApiKey>,
5419    >,
5420    crate::__types::ProjectApiKey
5421);
5422#[doc = "Delete project API key"]
5423pub fn delete_project_api_key<C, Fut, B, E>(
5424    client: C,
5425    params: &crate::__types::delete_project_api_key::Params,
5426) -> DeleteProjectApiKey<Fut, B, E>
5427where
5428    C: FnOnce(http::Request<String>) -> Fut,
5429    Fut: Future<Output = Result<http::Response<B>, E>>,
5430    B: http_body::Body,
5431{
5432    DeleteProjectApiKey(futures::TryFutureExt::and_then(
5433        crate::__combinators::Send::new(
5434            client,
5435            || {
5436                let path = {
5437                    #[serde_with::serde_as]
5438                    #[derive(serde :: Serialize)]
5439                    struct Query<'a> {
5440                        #[serde(skip_serializing)]
5441                        _phantom: std::marker::PhantomData<&'a ()>,
5442                    }
5443                    let crate::__types::delete_project_api_key::Params { project_id, key_id } =
5444                        params;
5445                    #[allow(clippy::useless_format)]
5446                    let mut path = format!("/organization/projects/{project_id}/api_keys/{key_id}");
5447                    let query = serde_urlencoded::to_string(Query {
5448                        _phantom: std::marker::PhantomData,
5449                    })?;
5450                    if !query.is_empty() {
5451                        path.push('?');
5452                        path.push_str(&query);
5453                    }
5454                    path
5455                };
5456                let body = String::new();
5457                Ok(http::Request::builder()
5458                    .method(http::Method::DELETE)
5459                    .uri(path)
5460                    .header(http::header::CONTENT_LENGTH, body.len())
5461                    .body(body)?)
5462            },
5463            (
5464                http::StatusCode::from_u16(200u16).unwrap(),
5465                Some(mime::APPLICATION_JSON),
5466            ),
5467        ),
5468        crate::__combinators::Json::new,
5469    ))
5470}
5471future!(
5472    DeleteProjectApiKey,
5473    futures::future::AndThen<
5474        crate::__combinators::Send<Fut, B, E>,
5475        crate::__combinators::Json<B, E, crate::__types::ProjectApiKeyDeleteResponse>,
5476        fn(
5477            http::Response<B>,
5478        )
5479            -> crate::__combinators::Json<B, E, crate::__types::ProjectApiKeyDeleteResponse>,
5480    >,
5481    crate::__types::ProjectApiKeyDeleteResponse
5482);
5483#[doc = "Archive project"]
5484pub fn archive_project<C, Fut, B, E>(
5485    client: C,
5486    params: &crate::__types::archive_project::Params,
5487) -> ArchiveProject<Fut, B, E>
5488where
5489    C: FnOnce(http::Request<String>) -> Fut,
5490    Fut: Future<Output = Result<http::Response<B>, E>>,
5491    B: http_body::Body,
5492{
5493    ArchiveProject(futures::TryFutureExt::and_then(
5494        crate::__combinators::Send::new(
5495            client,
5496            || {
5497                let path = {
5498                    #[serde_with::serde_as]
5499                    #[derive(serde :: Serialize)]
5500                    struct Query<'a> {
5501                        #[serde(skip_serializing)]
5502                        _phantom: std::marker::PhantomData<&'a ()>,
5503                    }
5504                    let crate::__types::archive_project::Params { project_id } = params;
5505                    #[allow(clippy::useless_format)]
5506                    let mut path = format!("/organization/projects/{project_id}/archive");
5507                    let query = serde_urlencoded::to_string(Query {
5508                        _phantom: std::marker::PhantomData,
5509                    })?;
5510                    if !query.is_empty() {
5511                        path.push('?');
5512                        path.push_str(&query);
5513                    }
5514                    path
5515                };
5516                let body = String::new();
5517                Ok(http::Request::builder()
5518                    .method(http::Method::POST)
5519                    .uri(path)
5520                    .header(http::header::CONTENT_LENGTH, body.len())
5521                    .body(body)?)
5522            },
5523            (
5524                http::StatusCode::from_u16(200u16).unwrap(),
5525                Some(mime::APPLICATION_JSON),
5526            ),
5527        ),
5528        crate::__combinators::Json::new,
5529    ))
5530}
5531future!(
5532    ArchiveProject,
5533    futures::future::AndThen<
5534        crate::__combinators::Send<Fut, B, E>,
5535        crate::__combinators::Json<B, E, crate::__types::Project>,
5536        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Project>,
5537    >,
5538    crate::__types::Project
5539);
5540#[doc = "List project certificates"]
5541pub fn list_project_certificates<C, Fut, B, E>(
5542    client: C,
5543    params: &crate::__types::list_project_certificates::Params,
5544) -> ListProjectCertificates<Fut, B, E>
5545where
5546    C: FnOnce(http::Request<String>) -> Fut,
5547    Fut: Future<Output = Result<http::Response<B>, E>>,
5548    B: http_body::Body,
5549{
5550    ListProjectCertificates(futures::TryFutureExt::and_then(
5551        crate::__combinators::Send::new(
5552            client,
5553            || {
5554                let path = {
5555                    #[serde_with::serde_as]
5556                    #[derive(serde :: Serialize)]
5557                    struct Query<'a> {
5558                        #[serde(rename = "limit")]
5559                        #[serde(skip_serializing_if = "Option::is_none")]
5560                        limit: &'a Option<i64>,
5561                        #[serde(rename = "after")]
5562                        #[serde(skip_serializing_if = "Option::is_none")]
5563                        after: &'a Option<String>,
5564                        #[serde(rename = "order")]
5565                        #[serde(skip_serializing_if = "Option::is_none")]
5566                        order: &'a Option<crate::__types::list_project_certificates::params::Order>,
5567                        #[serde(skip_serializing)]
5568                        _phantom: std::marker::PhantomData<&'a ()>,
5569                    }
5570                    let crate::__types::list_project_certificates::Params {
5571                        project_id,
5572                        limit,
5573                        after,
5574                        order,
5575                    } = params;
5576                    #[allow(clippy::useless_format)]
5577                    let mut path = format!("/organization/projects/{project_id}/certificates");
5578                    let query = serde_urlencoded::to_string(Query {
5579                        limit,
5580                        after,
5581                        order,
5582                        _phantom: std::marker::PhantomData,
5583                    })?;
5584                    if !query.is_empty() {
5585                        path.push('?');
5586                        path.push_str(&query);
5587                    }
5588                    path
5589                };
5590                let body = String::new();
5591                Ok(http::Request::builder()
5592                    .method(http::Method::GET)
5593                    .uri(path)
5594                    .header(http::header::CONTENT_LENGTH, body.len())
5595                    .body(body)?)
5596            },
5597            (
5598                http::StatusCode::from_u16(200u16).unwrap(),
5599                Some(mime::APPLICATION_JSON),
5600            ),
5601        ),
5602        crate::__combinators::Json::new,
5603    ))
5604}
5605future!(
5606    ListProjectCertificates,
5607    futures::future::AndThen<
5608        crate::__combinators::Send<Fut, B, E>,
5609        crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
5610        fn(
5611            http::Response<B>,
5612        ) -> crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
5613    >,
5614    crate::__types::ListCertificatesResponse
5615);
5616#[doc = "Activate certificates for project"]
5617pub fn activate_project_certificates<C, Fut, B, E>(
5618    client: C,
5619    params: &crate::__types::activate_project_certificates::Params,
5620    request: &crate::__types::ToggleCertificatesRequest,
5621) -> ActivateProjectCertificates<Fut, B, E>
5622where
5623    C: FnOnce(http::Request<String>) -> Fut,
5624    Fut: Future<Output = Result<http::Response<B>, E>>,
5625    B: http_body::Body,
5626{
5627    ActivateProjectCertificates(futures::TryFutureExt::and_then(
5628        crate::__combinators::Send::new(
5629            client,
5630            || {
5631                let path = {
5632                    #[serde_with::serde_as]
5633                    #[derive(serde :: Serialize)]
5634                    struct Query<'a> {
5635                        #[serde(skip_serializing)]
5636                        _phantom: std::marker::PhantomData<&'a ()>,
5637                    }
5638                    let crate::__types::activate_project_certificates::Params { project_id } =
5639                        params;
5640                    #[allow(clippy::useless_format)]
5641                    let mut path =
5642                        format!("/organization/projects/{project_id}/certificates/activate");
5643                    let query = serde_urlencoded::to_string(Query {
5644                        _phantom: std::marker::PhantomData,
5645                    })?;
5646                    if !query.is_empty() {
5647                        path.push('?');
5648                        path.push_str(&query);
5649                    }
5650                    path
5651                };
5652                let body = serde_json::to_string(request)?;
5653                Ok(http::Request::builder()
5654                    .method(http::Method::POST)
5655                    .uri(path)
5656                    .header(http::header::CONTENT_LENGTH, body.len())
5657                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
5658                    .body(body)?)
5659            },
5660            (
5661                http::StatusCode::from_u16(200u16).unwrap(),
5662                Some(mime::APPLICATION_JSON),
5663            ),
5664        ),
5665        crate::__combinators::Json::new,
5666    ))
5667}
5668future!(
5669    ActivateProjectCertificates,
5670    futures::future::AndThen<
5671        crate::__combinators::Send<Fut, B, E>,
5672        crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
5673        fn(
5674            http::Response<B>,
5675        ) -> crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
5676    >,
5677    crate::__types::ListCertificatesResponse
5678);
5679#[doc = "Deactivate certificates for project"]
5680pub fn deactivate_project_certificates<C, Fut, B, E>(
5681    client: C,
5682    params: &crate::__types::deactivate_project_certificates::Params,
5683    request: &crate::__types::ToggleCertificatesRequest,
5684) -> DeactivateProjectCertificates<Fut, B, E>
5685where
5686    C: FnOnce(http::Request<String>) -> Fut,
5687    Fut: Future<Output = Result<http::Response<B>, E>>,
5688    B: http_body::Body,
5689{
5690    DeactivateProjectCertificates(futures::TryFutureExt::and_then(
5691        crate::__combinators::Send::new(
5692            client,
5693            || {
5694                let path = {
5695                    #[serde_with::serde_as]
5696                    #[derive(serde :: Serialize)]
5697                    struct Query<'a> {
5698                        #[serde(skip_serializing)]
5699                        _phantom: std::marker::PhantomData<&'a ()>,
5700                    }
5701                    let crate::__types::deactivate_project_certificates::Params { project_id } =
5702                        params;
5703                    #[allow(clippy::useless_format)]
5704                    let mut path =
5705                        format!("/organization/projects/{project_id}/certificates/deactivate");
5706                    let query = serde_urlencoded::to_string(Query {
5707                        _phantom: std::marker::PhantomData,
5708                    })?;
5709                    if !query.is_empty() {
5710                        path.push('?');
5711                        path.push_str(&query);
5712                    }
5713                    path
5714                };
5715                let body = serde_json::to_string(request)?;
5716                Ok(http::Request::builder()
5717                    .method(http::Method::POST)
5718                    .uri(path)
5719                    .header(http::header::CONTENT_LENGTH, body.len())
5720                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
5721                    .body(body)?)
5722            },
5723            (
5724                http::StatusCode::from_u16(200u16).unwrap(),
5725                Some(mime::APPLICATION_JSON),
5726            ),
5727        ),
5728        crate::__combinators::Json::new,
5729    ))
5730}
5731future!(
5732    DeactivateProjectCertificates,
5733    futures::future::AndThen<
5734        crate::__combinators::Send<Fut, B, E>,
5735        crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
5736        fn(
5737            http::Response<B>,
5738        ) -> crate::__combinators::Json<B, E, crate::__types::ListCertificatesResponse>,
5739    >,
5740    crate::__types::ListCertificatesResponse
5741);
5742#[doc = "List project rate limits"]
5743pub fn list_project_rate_limits<C, Fut, B, E>(
5744    client: C,
5745    params: &crate::__types::list_project_rate_limits::Params,
5746) -> ListProjectRateLimits<Fut, B, E>
5747where
5748    C: FnOnce(http::Request<String>) -> Fut,
5749    Fut: Future<Output = Result<http::Response<B>, E>>,
5750    B: http_body::Body,
5751{
5752    ListProjectRateLimits(futures::TryFutureExt::and_then(
5753        crate::__combinators::Send::new(
5754            client,
5755            || {
5756                let path = {
5757                    #[serde_with::serde_as]
5758                    #[derive(serde :: Serialize)]
5759                    struct Query<'a> {
5760                        #[serde(rename = "limit")]
5761                        #[serde(skip_serializing_if = "Option::is_none")]
5762                        limit: &'a Option<i64>,
5763                        #[serde(rename = "after")]
5764                        #[serde(skip_serializing_if = "Option::is_none")]
5765                        after: &'a Option<String>,
5766                        #[serde(rename = "before")]
5767                        #[serde(skip_serializing_if = "Option::is_none")]
5768                        before: &'a Option<String>,
5769                        #[serde(skip_serializing)]
5770                        _phantom: std::marker::PhantomData<&'a ()>,
5771                    }
5772                    let crate::__types::list_project_rate_limits::Params {
5773                        project_id,
5774                        limit,
5775                        after,
5776                        before,
5777                    } = params;
5778                    #[allow(clippy::useless_format)]
5779                    let mut path = format!("/organization/projects/{project_id}/rate_limits");
5780                    let query = serde_urlencoded::to_string(Query {
5781                        limit,
5782                        after,
5783                        before,
5784                        _phantom: std::marker::PhantomData,
5785                    })?;
5786                    if !query.is_empty() {
5787                        path.push('?');
5788                        path.push_str(&query);
5789                    }
5790                    path
5791                };
5792                let body = String::new();
5793                Ok(http::Request::builder()
5794                    .method(http::Method::GET)
5795                    .uri(path)
5796                    .header(http::header::CONTENT_LENGTH, body.len())
5797                    .body(body)?)
5798            },
5799            (
5800                http::StatusCode::from_u16(200u16).unwrap(),
5801                Some(mime::APPLICATION_JSON),
5802            ),
5803        ),
5804        crate::__combinators::Json::new,
5805    ))
5806}
5807future!(
5808    ListProjectRateLimits,
5809    futures::future::AndThen<
5810        crate::__combinators::Send<Fut, B, E>,
5811        crate::__combinators::Json<B, E, crate::__types::ProjectRateLimitListResponse>,
5812        fn(
5813            http::Response<B>,
5814        )
5815            -> crate::__combinators::Json<B, E, crate::__types::ProjectRateLimitListResponse>,
5816    >,
5817    crate::__types::ProjectRateLimitListResponse
5818);
5819#[doc = "Modify project rate limit"]
5820pub fn update_project_rate_limits<C, Fut, B, E>(
5821    client: C,
5822    params: &crate::__types::update_project_rate_limits::Params,
5823    request: &crate::__types::ProjectRateLimitUpdateRequest,
5824) -> UpdateProjectRateLimits<Fut, B, E>
5825where
5826    C: FnOnce(http::Request<String>) -> Fut,
5827    Fut: Future<Output = Result<http::Response<B>, E>>,
5828    B: http_body::Body,
5829{
5830    UpdateProjectRateLimits(futures::TryFutureExt::and_then(
5831        crate::__combinators::Send::new(
5832            client,
5833            || {
5834                let path = {
5835                    #[serde_with::serde_as]
5836                    #[derive(serde :: Serialize)]
5837                    struct Query<'a> {
5838                        #[serde(skip_serializing)]
5839                        _phantom: std::marker::PhantomData<&'a ()>,
5840                    }
5841                    let crate::__types::update_project_rate_limits::Params {
5842                        project_id,
5843                        rate_limit_id,
5844                    } = params;
5845                    #[allow(clippy::useless_format)]
5846                    let mut path =
5847                        format!("/organization/projects/{project_id}/rate_limits/{rate_limit_id}");
5848                    let query = serde_urlencoded::to_string(Query {
5849                        _phantom: std::marker::PhantomData,
5850                    })?;
5851                    if !query.is_empty() {
5852                        path.push('?');
5853                        path.push_str(&query);
5854                    }
5855                    path
5856                };
5857                let body = serde_json::to_string(request)?;
5858                Ok(http::Request::builder()
5859                    .method(http::Method::POST)
5860                    .uri(path)
5861                    .header(http::header::CONTENT_LENGTH, body.len())
5862                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
5863                    .body(body)?)
5864            },
5865            (
5866                http::StatusCode::from_u16(200u16).unwrap(),
5867                Some(mime::APPLICATION_JSON),
5868            ),
5869        ),
5870        crate::__combinators::Json::new,
5871    ))
5872}
5873future!(
5874    UpdateProjectRateLimits,
5875    futures::future::AndThen<
5876        crate::__combinators::Send<Fut, B, E>,
5877        crate::__combinators::Json<B, E, crate::__types::ProjectRateLimit>,
5878        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ProjectRateLimit>,
5879    >,
5880    crate::__types::ProjectRateLimit
5881);
5882#[doc = "List project service accounts"]
5883pub fn list_project_service_accounts<C, Fut, B, E>(
5884    client: C,
5885    params: &crate::__types::list_project_service_accounts::Params,
5886) -> ListProjectServiceAccounts<Fut, B, E>
5887where
5888    C: FnOnce(http::Request<String>) -> Fut,
5889    Fut: Future<Output = Result<http::Response<B>, E>>,
5890    B: http_body::Body,
5891{
5892    ListProjectServiceAccounts(futures::TryFutureExt::and_then(
5893        crate::__combinators::Send::new(
5894            client,
5895            || {
5896                let path = {
5897                    #[serde_with::serde_as]
5898                    #[derive(serde :: Serialize)]
5899                    struct Query<'a> {
5900                        #[serde(rename = "limit")]
5901                        #[serde(skip_serializing_if = "Option::is_none")]
5902                        limit: &'a Option<i64>,
5903                        #[serde(rename = "after")]
5904                        #[serde(skip_serializing_if = "Option::is_none")]
5905                        after: &'a Option<String>,
5906                        #[serde(skip_serializing)]
5907                        _phantom: std::marker::PhantomData<&'a ()>,
5908                    }
5909                    let crate::__types::list_project_service_accounts::Params {
5910                        project_id,
5911                        limit,
5912                        after,
5913                    } = params;
5914                    #[allow(clippy::useless_format)]
5915                    let mut path = format!("/organization/projects/{project_id}/service_accounts");
5916                    let query = serde_urlencoded::to_string(Query {
5917                        limit,
5918                        after,
5919                        _phantom: std::marker::PhantomData,
5920                    })?;
5921                    if !query.is_empty() {
5922                        path.push('?');
5923                        path.push_str(&query);
5924                    }
5925                    path
5926                };
5927                let body = String::new();
5928                Ok(http::Request::builder()
5929                    .method(http::Method::GET)
5930                    .uri(path)
5931                    .header(http::header::CONTENT_LENGTH, body.len())
5932                    .body(body)?)
5933            },
5934            (
5935                http::StatusCode::from_u16(200u16).unwrap(),
5936                Some(mime::APPLICATION_JSON),
5937            ),
5938        ),
5939        crate::__combinators::Json::new,
5940    ))
5941}
5942future!(
5943    ListProjectServiceAccounts,
5944    futures::future::AndThen<
5945        crate::__combinators::Send<Fut, B, E>,
5946        crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccountListResponse>,
5947        fn(
5948            http::Response<B>,
5949        )
5950            -> crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccountListResponse>,
5951    >,
5952    crate::__types::ProjectServiceAccountListResponse
5953);
5954#[doc = "Create project service account"]
5955pub fn create_project_service_account<C, Fut, B, E>(
5956    client: C,
5957    params: &crate::__types::create_project_service_account::Params,
5958    request: &crate::__types::ProjectServiceAccountCreateRequest,
5959) -> CreateProjectServiceAccount<Fut, B, E>
5960where
5961    C: FnOnce(http::Request<String>) -> Fut,
5962    Fut: Future<Output = Result<http::Response<B>, E>>,
5963    B: http_body::Body,
5964{
5965    CreateProjectServiceAccount(futures::TryFutureExt::and_then(
5966        crate::__combinators::Send::new(
5967            client,
5968            || {
5969                let path = {
5970                    #[serde_with::serde_as]
5971                    #[derive(serde :: Serialize)]
5972                    struct Query<'a> {
5973                        #[serde(skip_serializing)]
5974                        _phantom: std::marker::PhantomData<&'a ()>,
5975                    }
5976                    let crate::__types::create_project_service_account::Params { project_id } =
5977                        params;
5978                    #[allow(clippy::useless_format)]
5979                    let mut path = format!("/organization/projects/{project_id}/service_accounts");
5980                    let query = serde_urlencoded::to_string(Query {
5981                        _phantom: std::marker::PhantomData,
5982                    })?;
5983                    if !query.is_empty() {
5984                        path.push('?');
5985                        path.push_str(&query);
5986                    }
5987                    path
5988                };
5989                let body = serde_json::to_string(request)?;
5990                Ok(http::Request::builder()
5991                    .method(http::Method::POST)
5992                    .uri(path)
5993                    .header(http::header::CONTENT_LENGTH, body.len())
5994                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
5995                    .body(body)?)
5996            },
5997            (
5998                http::StatusCode::from_u16(200u16).unwrap(),
5999                Some(mime::APPLICATION_JSON),
6000            ),
6001        ),
6002        crate::__combinators::Json::new,
6003    ))
6004}
6005future!(
6006    CreateProjectServiceAccount,
6007    futures::future::AndThen<
6008        crate::__combinators::Send<Fut, B, E>,
6009        crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccountCreateResponse>,
6010        fn(
6011            http::Response<B>,
6012        )
6013            -> crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccountCreateResponse>,
6014    >,
6015    crate::__types::ProjectServiceAccountCreateResponse
6016);
6017#[doc = "Retrieve project service account"]
6018pub fn retrieve_project_service_account<C, Fut, B, E>(
6019    client: C,
6020    params: &crate::__types::retrieve_project_service_account::Params,
6021) -> RetrieveProjectServiceAccount<Fut, B, E>
6022where
6023    C: FnOnce(http::Request<String>) -> Fut,
6024    Fut: Future<Output = Result<http::Response<B>, E>>,
6025    B: http_body::Body,
6026{
6027    RetrieveProjectServiceAccount(futures::TryFutureExt::and_then(
6028        crate::__combinators::Send::new(
6029            client,
6030            || {
6031                let path = {
6032                    #[serde_with::serde_as]
6033                    #[derive(serde :: Serialize)]
6034                    struct Query<'a> {
6035                        #[serde(skip_serializing)]
6036                        _phantom: std::marker::PhantomData<&'a ()>,
6037                    }
6038                    let crate::__types::retrieve_project_service_account::Params {
6039                        project_id,
6040                        service_account_id,
6041                    } = params;
6042                    #[allow(clippy::useless_format)]
6043                    let mut path = format!(
6044                        "/organization/projects/{project_id}/service_accounts/{service_account_id}"
6045                    );
6046                    let query = serde_urlencoded::to_string(Query {
6047                        _phantom: std::marker::PhantomData,
6048                    })?;
6049                    if !query.is_empty() {
6050                        path.push('?');
6051                        path.push_str(&query);
6052                    }
6053                    path
6054                };
6055                let body = String::new();
6056                Ok(http::Request::builder()
6057                    .method(http::Method::GET)
6058                    .uri(path)
6059                    .header(http::header::CONTENT_LENGTH, body.len())
6060                    .body(body)?)
6061            },
6062            (
6063                http::StatusCode::from_u16(200u16).unwrap(),
6064                Some(mime::APPLICATION_JSON),
6065            ),
6066        ),
6067        crate::__combinators::Json::new,
6068    ))
6069}
6070future!(
6071    RetrieveProjectServiceAccount,
6072    futures::future::AndThen<
6073        crate::__combinators::Send<Fut, B, E>,
6074        crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccount>,
6075        fn(
6076            http::Response<B>,
6077        ) -> crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccount>,
6078    >,
6079    crate::__types::ProjectServiceAccount
6080);
6081#[doc = "Delete project service account"]
6082pub fn delete_project_service_account<C, Fut, B, E>(
6083    client: C,
6084    params: &crate::__types::delete_project_service_account::Params,
6085) -> DeleteProjectServiceAccount<Fut, B, E>
6086where
6087    C: FnOnce(http::Request<String>) -> Fut,
6088    Fut: Future<Output = Result<http::Response<B>, E>>,
6089    B: http_body::Body,
6090{
6091    DeleteProjectServiceAccount(futures::TryFutureExt::and_then(
6092        crate::__combinators::Send::new(
6093            client,
6094            || {
6095                let path = {
6096                    #[serde_with::serde_as]
6097                    #[derive(serde :: Serialize)]
6098                    struct Query<'a> {
6099                        #[serde(skip_serializing)]
6100                        _phantom: std::marker::PhantomData<&'a ()>,
6101                    }
6102                    let crate::__types::delete_project_service_account::Params {
6103                        project_id,
6104                        service_account_id,
6105                    } = params;
6106                    #[allow(clippy::useless_format)]
6107                    let mut path = format!(
6108                        "/organization/projects/{project_id}/service_accounts/{service_account_id}"
6109                    );
6110                    let query = serde_urlencoded::to_string(Query {
6111                        _phantom: std::marker::PhantomData,
6112                    })?;
6113                    if !query.is_empty() {
6114                        path.push('?');
6115                        path.push_str(&query);
6116                    }
6117                    path
6118                };
6119                let body = String::new();
6120                Ok(http::Request::builder()
6121                    .method(http::Method::DELETE)
6122                    .uri(path)
6123                    .header(http::header::CONTENT_LENGTH, body.len())
6124                    .body(body)?)
6125            },
6126            (
6127                http::StatusCode::from_u16(200u16).unwrap(),
6128                Some(mime::APPLICATION_JSON),
6129            ),
6130        ),
6131        crate::__combinators::Json::new,
6132    ))
6133}
6134future!(
6135    DeleteProjectServiceAccount,
6136    futures::future::AndThen<
6137        crate::__combinators::Send<Fut, B, E>,
6138        crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccountDeleteResponse>,
6139        fn(
6140            http::Response<B>,
6141        )
6142            -> crate::__combinators::Json<B, E, crate::__types::ProjectServiceAccountDeleteResponse>,
6143    >,
6144    crate::__types::ProjectServiceAccountDeleteResponse
6145);
6146#[doc = "List project users"]
6147pub fn list_project_users<C, Fut, B, E>(
6148    client: C,
6149    params: &crate::__types::list_project_users::Params,
6150) -> ListProjectUsers<Fut, B, E>
6151where
6152    C: FnOnce(http::Request<String>) -> Fut,
6153    Fut: Future<Output = Result<http::Response<B>, E>>,
6154    B: http_body::Body,
6155{
6156    ListProjectUsers(futures::TryFutureExt::and_then(
6157        crate::__combinators::Send::new(
6158            client,
6159            || {
6160                let path = {
6161                    #[serde_with::serde_as]
6162                    #[derive(serde :: Serialize)]
6163                    struct Query<'a> {
6164                        #[serde(rename = "limit")]
6165                        #[serde(skip_serializing_if = "Option::is_none")]
6166                        limit: &'a Option<i64>,
6167                        #[serde(rename = "after")]
6168                        #[serde(skip_serializing_if = "Option::is_none")]
6169                        after: &'a Option<String>,
6170                        #[serde(skip_serializing)]
6171                        _phantom: std::marker::PhantomData<&'a ()>,
6172                    }
6173                    let crate::__types::list_project_users::Params {
6174                        project_id,
6175                        limit,
6176                        after,
6177                    } = params;
6178                    #[allow(clippy::useless_format)]
6179                    let mut path = format!("/organization/projects/{project_id}/users");
6180                    let query = serde_urlencoded::to_string(Query {
6181                        limit,
6182                        after,
6183                        _phantom: std::marker::PhantomData,
6184                    })?;
6185                    if !query.is_empty() {
6186                        path.push('?');
6187                        path.push_str(&query);
6188                    }
6189                    path
6190                };
6191                let body = String::new();
6192                Ok(http::Request::builder()
6193                    .method(http::Method::GET)
6194                    .uri(path)
6195                    .header(http::header::CONTENT_LENGTH, body.len())
6196                    .body(body)?)
6197            },
6198            (
6199                http::StatusCode::from_u16(200u16).unwrap(),
6200                Some(mime::APPLICATION_JSON),
6201            ),
6202        ),
6203        crate::__combinators::Json::new,
6204    ))
6205}
6206future!(
6207    ListProjectUsers,
6208    futures::future::AndThen<
6209        crate::__combinators::Send<Fut, B, E>,
6210        crate::__combinators::Json<B, E, crate::__types::ProjectUserListResponse>,
6211        fn(
6212            http::Response<B>,
6213        ) -> crate::__combinators::Json<B, E, crate::__types::ProjectUserListResponse>,
6214    >,
6215    crate::__types::ProjectUserListResponse
6216);
6217#[doc = "Create project user"]
6218pub fn create_project_user<C, Fut, B, E>(
6219    client: C,
6220    params: &crate::__types::create_project_user::Params,
6221    request: &crate::__types::ProjectUserCreateRequest,
6222) -> CreateProjectUser<Fut, B, E>
6223where
6224    C: FnOnce(http::Request<String>) -> Fut,
6225    Fut: Future<Output = Result<http::Response<B>, E>>,
6226    B: http_body::Body,
6227{
6228    CreateProjectUser(futures::TryFutureExt::and_then(
6229        crate::__combinators::Send::new(
6230            client,
6231            || {
6232                let path = {
6233                    #[serde_with::serde_as]
6234                    #[derive(serde :: Serialize)]
6235                    struct Query<'a> {
6236                        #[serde(skip_serializing)]
6237                        _phantom: std::marker::PhantomData<&'a ()>,
6238                    }
6239                    let crate::__types::create_project_user::Params { project_id } = params;
6240                    #[allow(clippy::useless_format)]
6241                    let mut path = format!("/organization/projects/{project_id}/users");
6242                    let query = serde_urlencoded::to_string(Query {
6243                        _phantom: std::marker::PhantomData,
6244                    })?;
6245                    if !query.is_empty() {
6246                        path.push('?');
6247                        path.push_str(&query);
6248                    }
6249                    path
6250                };
6251                let body = serde_json::to_string(request)?;
6252                Ok(http::Request::builder()
6253                    .method(http::Method::POST)
6254                    .uri(path)
6255                    .header(http::header::CONTENT_LENGTH, body.len())
6256                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
6257                    .body(body)?)
6258            },
6259            (
6260                http::StatusCode::from_u16(200u16).unwrap(),
6261                Some(mime::APPLICATION_JSON),
6262            ),
6263        ),
6264        crate::__combinators::Json::new,
6265    ))
6266}
6267future!(
6268    CreateProjectUser,
6269    futures::future::AndThen<
6270        crate::__combinators::Send<Fut, B, E>,
6271        crate::__combinators::Json<B, E, crate::__types::ProjectUser>,
6272        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ProjectUser>,
6273    >,
6274    crate::__types::ProjectUser
6275);
6276#[doc = "Retrieve project user"]
6277pub fn retrieve_project_user<C, Fut, B, E>(
6278    client: C,
6279    params: &crate::__types::retrieve_project_user::Params,
6280) -> RetrieveProjectUser<Fut, B, E>
6281where
6282    C: FnOnce(http::Request<String>) -> Fut,
6283    Fut: Future<Output = Result<http::Response<B>, E>>,
6284    B: http_body::Body,
6285{
6286    RetrieveProjectUser(futures::TryFutureExt::and_then(
6287        crate::__combinators::Send::new(
6288            client,
6289            || {
6290                let path = {
6291                    #[serde_with::serde_as]
6292                    #[derive(serde :: Serialize)]
6293                    struct Query<'a> {
6294                        #[serde(skip_serializing)]
6295                        _phantom: std::marker::PhantomData<&'a ()>,
6296                    }
6297                    let crate::__types::retrieve_project_user::Params {
6298                        project_id,
6299                        user_id,
6300                    } = params;
6301                    #[allow(clippy::useless_format)]
6302                    let mut path = format!("/organization/projects/{project_id}/users/{user_id}");
6303                    let query = serde_urlencoded::to_string(Query {
6304                        _phantom: std::marker::PhantomData,
6305                    })?;
6306                    if !query.is_empty() {
6307                        path.push('?');
6308                        path.push_str(&query);
6309                    }
6310                    path
6311                };
6312                let body = String::new();
6313                Ok(http::Request::builder()
6314                    .method(http::Method::GET)
6315                    .uri(path)
6316                    .header(http::header::CONTENT_LENGTH, body.len())
6317                    .body(body)?)
6318            },
6319            (
6320                http::StatusCode::from_u16(200u16).unwrap(),
6321                Some(mime::APPLICATION_JSON),
6322            ),
6323        ),
6324        crate::__combinators::Json::new,
6325    ))
6326}
6327future!(
6328    RetrieveProjectUser,
6329    futures::future::AndThen<
6330        crate::__combinators::Send<Fut, B, E>,
6331        crate::__combinators::Json<B, E, crate::__types::ProjectUser>,
6332        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ProjectUser>,
6333    >,
6334    crate::__types::ProjectUser
6335);
6336#[doc = "Modify project user"]
6337pub fn modify_project_user<C, Fut, B, E>(
6338    client: C,
6339    params: &crate::__types::modify_project_user::Params,
6340    request: &crate::__types::ProjectUserUpdateRequest,
6341) -> ModifyProjectUser<Fut, B, E>
6342where
6343    C: FnOnce(http::Request<String>) -> Fut,
6344    Fut: Future<Output = Result<http::Response<B>, E>>,
6345    B: http_body::Body,
6346{
6347    ModifyProjectUser(futures::TryFutureExt::and_then(
6348        crate::__combinators::Send::new(
6349            client,
6350            || {
6351                let path = {
6352                    #[serde_with::serde_as]
6353                    #[derive(serde :: Serialize)]
6354                    struct Query<'a> {
6355                        #[serde(skip_serializing)]
6356                        _phantom: std::marker::PhantomData<&'a ()>,
6357                    }
6358                    let crate::__types::modify_project_user::Params {
6359                        project_id,
6360                        user_id,
6361                    } = params;
6362                    #[allow(clippy::useless_format)]
6363                    let mut path = format!("/organization/projects/{project_id}/users/{user_id}");
6364                    let query = serde_urlencoded::to_string(Query {
6365                        _phantom: std::marker::PhantomData,
6366                    })?;
6367                    if !query.is_empty() {
6368                        path.push('?');
6369                        path.push_str(&query);
6370                    }
6371                    path
6372                };
6373                let body = serde_json::to_string(request)?;
6374                Ok(http::Request::builder()
6375                    .method(http::Method::POST)
6376                    .uri(path)
6377                    .header(http::header::CONTENT_LENGTH, body.len())
6378                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
6379                    .body(body)?)
6380            },
6381            (
6382                http::StatusCode::from_u16(200u16).unwrap(),
6383                Some(mime::APPLICATION_JSON),
6384            ),
6385        ),
6386        crate::__combinators::Json::new,
6387    ))
6388}
6389future!(
6390    ModifyProjectUser,
6391    futures::future::AndThen<
6392        crate::__combinators::Send<Fut, B, E>,
6393        crate::__combinators::Json<B, E, crate::__types::ProjectUser>,
6394        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ProjectUser>,
6395    >,
6396    crate::__types::ProjectUser
6397);
6398#[doc = "Delete project user"]
6399pub fn delete_project_user<C, Fut, B, E>(
6400    client: C,
6401    params: &crate::__types::delete_project_user::Params,
6402) -> DeleteProjectUser<Fut, B, E>
6403where
6404    C: FnOnce(http::Request<String>) -> Fut,
6405    Fut: Future<Output = Result<http::Response<B>, E>>,
6406    B: http_body::Body,
6407{
6408    DeleteProjectUser(futures::TryFutureExt::and_then(
6409        crate::__combinators::Send::new(
6410            client,
6411            || {
6412                let path = {
6413                    #[serde_with::serde_as]
6414                    #[derive(serde :: Serialize)]
6415                    struct Query<'a> {
6416                        #[serde(skip_serializing)]
6417                        _phantom: std::marker::PhantomData<&'a ()>,
6418                    }
6419                    let crate::__types::delete_project_user::Params {
6420                        project_id,
6421                        user_id,
6422                    } = params;
6423                    #[allow(clippy::useless_format)]
6424                    let mut path = format!("/organization/projects/{project_id}/users/{user_id}");
6425                    let query = serde_urlencoded::to_string(Query {
6426                        _phantom: std::marker::PhantomData,
6427                    })?;
6428                    if !query.is_empty() {
6429                        path.push('?');
6430                        path.push_str(&query);
6431                    }
6432                    path
6433                };
6434                let body = String::new();
6435                Ok(http::Request::builder()
6436                    .method(http::Method::DELETE)
6437                    .uri(path)
6438                    .header(http::header::CONTENT_LENGTH, body.len())
6439                    .body(body)?)
6440            },
6441            (
6442                http::StatusCode::from_u16(200u16).unwrap(),
6443                Some(mime::APPLICATION_JSON),
6444            ),
6445        ),
6446        crate::__combinators::Json::new,
6447    ))
6448}
6449future!(
6450    DeleteProjectUser,
6451    futures::future::AndThen<
6452        crate::__combinators::Send<Fut, B, E>,
6453        crate::__combinators::Json<B, E, crate::__types::ProjectUserDeleteResponse>,
6454        fn(
6455            http::Response<B>,
6456        ) -> crate::__combinators::Json<B, E, crate::__types::ProjectUserDeleteResponse>,
6457    >,
6458    crate::__types::ProjectUserDeleteResponse
6459);
6460#[doc = "Audio speeches"]
6461pub fn usage_audio_speeches<C, Fut, B, E>(
6462    client: C,
6463    params: &crate::__types::usage_audio_speeches::Params,
6464) -> UsageAudioSpeeches<Fut, B, E>
6465where
6466    C: FnOnce(http::Request<String>) -> Fut,
6467    Fut: Future<Output = Result<http::Response<B>, E>>,
6468    B: http_body::Body,
6469{
6470    UsageAudioSpeeches(futures::TryFutureExt::and_then(
6471        crate::__combinators::Send::new(
6472            client,
6473            || {
6474                let path = {
6475                    #[serde_with::serde_as]
6476                    #[derive(serde :: Serialize)]
6477                    struct Query<'a> {
6478                        #[serde(rename = "start_time")]
6479                        start_time: &'a i64,
6480                        #[serde(rename = "end_time")]
6481                        #[serde(skip_serializing_if = "Option::is_none")]
6482                        end_time: &'a Option<i64>,
6483                        #[serde(rename = "bucket_width")]
6484                        #[serde(skip_serializing_if = "Option::is_none")]
6485                        bucket_width:
6486                            &'a Option<crate::__types::usage_audio_speeches::params::BucketWidth>,
6487                        #[serde(rename = "project_ids")]
6488                        #[serde(skip_serializing_if = "Option::is_none")]
6489                        project_ids: &'a Option<Vec<String>>,
6490                        #[serde(rename = "user_ids")]
6491                        #[serde(skip_serializing_if = "Option::is_none")]
6492                        user_ids: &'a Option<Vec<String>>,
6493                        #[serde(rename = "api_key_ids")]
6494                        #[serde(skip_serializing_if = "Option::is_none")]
6495                        api_key_ids: &'a Option<Vec<String>>,
6496                        #[serde(rename = "models")]
6497                        #[serde(skip_serializing_if = "Option::is_none")]
6498                        models: &'a Option<Vec<String>>,
6499                        #[serde(rename = "group_by")]
6500                        #[serde(skip_serializing_if = "Option::is_none")]
6501                        group_by: &'a Option<
6502                            Vec<crate::__types::usage_audio_speeches::params::group_by::Item>,
6503                        >,
6504                        #[serde(rename = "limit")]
6505                        #[serde(skip_serializing_if = "Option::is_none")]
6506                        limit: &'a Option<i64>,
6507                        #[serde(rename = "page")]
6508                        #[serde(skip_serializing_if = "Option::is_none")]
6509                        page: &'a Option<String>,
6510                        #[serde(skip_serializing)]
6511                        _phantom: std::marker::PhantomData<&'a ()>,
6512                    }
6513                    let crate::__types::usage_audio_speeches::Params {
6514                        start_time,
6515                        end_time,
6516                        bucket_width,
6517                        project_ids,
6518                        user_ids,
6519                        api_key_ids,
6520                        models,
6521                        group_by,
6522                        limit,
6523                        page,
6524                    } = params;
6525                    #[allow(clippy::useless_format)]
6526                    let mut path = format!("/organization/usage/audio_speeches");
6527                    let query = serde_urlencoded::to_string(Query {
6528                        start_time,
6529                        end_time,
6530                        bucket_width,
6531                        project_ids,
6532                        user_ids,
6533                        api_key_ids,
6534                        models,
6535                        group_by,
6536                        limit,
6537                        page,
6538                        _phantom: std::marker::PhantomData,
6539                    })?;
6540                    if !query.is_empty() {
6541                        path.push('?');
6542                        path.push_str(&query);
6543                    }
6544                    path
6545                };
6546                let body = String::new();
6547                Ok(http::Request::builder()
6548                    .method(http::Method::GET)
6549                    .uri(path)
6550                    .header(http::header::CONTENT_LENGTH, body.len())
6551                    .body(body)?)
6552            },
6553            (
6554                http::StatusCode::from_u16(200u16).unwrap(),
6555                Some(mime::APPLICATION_JSON),
6556            ),
6557        ),
6558        crate::__combinators::Json::new,
6559    ))
6560}
6561future!(
6562    UsageAudioSpeeches,
6563    futures::future::AndThen<
6564        crate::__combinators::Send<Fut, B, E>,
6565        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6566        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6567    >,
6568    crate::__types::UsageResponse
6569);
6570#[doc = "Audio transcriptions"]
6571pub fn usage_audio_transcriptions<C, Fut, B, E>(
6572    client: C,
6573    params: &crate::__types::usage_audio_transcriptions::Params,
6574) -> UsageAudioTranscriptions<Fut, B, E>
6575where
6576    C: FnOnce(http::Request<String>) -> Fut,
6577    Fut: Future<Output = Result<http::Response<B>, E>>,
6578    B: http_body::Body,
6579{
6580    UsageAudioTranscriptions(futures::TryFutureExt::and_then(
6581        crate::__combinators::Send::new(
6582            client,
6583            || {
6584                let path = {
6585                    #[serde_with::serde_as]
6586                    #[derive(serde :: Serialize)]
6587                    struct Query<'a> {
6588                        #[serde(rename = "start_time")]
6589                        start_time: &'a i64,
6590                        #[serde(rename = "end_time")]
6591                        #[serde(skip_serializing_if = "Option::is_none")]
6592                        end_time: &'a Option<i64>,
6593                        #[serde(rename = "bucket_width")]
6594                        #[serde(skip_serializing_if = "Option::is_none")]
6595                        bucket_width: &'a Option<
6596                            crate::__types::usage_audio_transcriptions::params::BucketWidth,
6597                        >,
6598                        #[serde(rename = "project_ids")]
6599                        #[serde(skip_serializing_if = "Option::is_none")]
6600                        project_ids: &'a Option<Vec<String>>,
6601                        #[serde(rename = "user_ids")]
6602                        #[serde(skip_serializing_if = "Option::is_none")]
6603                        user_ids: &'a Option<Vec<String>>,
6604                        #[serde(rename = "api_key_ids")]
6605                        #[serde(skip_serializing_if = "Option::is_none")]
6606                        api_key_ids: &'a Option<Vec<String>>,
6607                        #[serde(rename = "models")]
6608                        #[serde(skip_serializing_if = "Option::is_none")]
6609                        models: &'a Option<Vec<String>>,
6610                        #[serde(rename = "group_by")]
6611                        #[serde(skip_serializing_if = "Option::is_none")]
6612                        group_by: &'a Option<
6613                            Vec<crate::__types::usage_audio_transcriptions::params::group_by::Item>,
6614                        >,
6615                        #[serde(rename = "limit")]
6616                        #[serde(skip_serializing_if = "Option::is_none")]
6617                        limit: &'a Option<i64>,
6618                        #[serde(rename = "page")]
6619                        #[serde(skip_serializing_if = "Option::is_none")]
6620                        page: &'a Option<String>,
6621                        #[serde(skip_serializing)]
6622                        _phantom: std::marker::PhantomData<&'a ()>,
6623                    }
6624                    let crate::__types::usage_audio_transcriptions::Params {
6625                        start_time,
6626                        end_time,
6627                        bucket_width,
6628                        project_ids,
6629                        user_ids,
6630                        api_key_ids,
6631                        models,
6632                        group_by,
6633                        limit,
6634                        page,
6635                    } = params;
6636                    #[allow(clippy::useless_format)]
6637                    let mut path = format!("/organization/usage/audio_transcriptions");
6638                    let query = serde_urlencoded::to_string(Query {
6639                        start_time,
6640                        end_time,
6641                        bucket_width,
6642                        project_ids,
6643                        user_ids,
6644                        api_key_ids,
6645                        models,
6646                        group_by,
6647                        limit,
6648                        page,
6649                        _phantom: std::marker::PhantomData,
6650                    })?;
6651                    if !query.is_empty() {
6652                        path.push('?');
6653                        path.push_str(&query);
6654                    }
6655                    path
6656                };
6657                let body = String::new();
6658                Ok(http::Request::builder()
6659                    .method(http::Method::GET)
6660                    .uri(path)
6661                    .header(http::header::CONTENT_LENGTH, body.len())
6662                    .body(body)?)
6663            },
6664            (
6665                http::StatusCode::from_u16(200u16).unwrap(),
6666                Some(mime::APPLICATION_JSON),
6667            ),
6668        ),
6669        crate::__combinators::Json::new,
6670    ))
6671}
6672future!(
6673    UsageAudioTranscriptions,
6674    futures::future::AndThen<
6675        crate::__combinators::Send<Fut, B, E>,
6676        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6677        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6678    >,
6679    crate::__types::UsageResponse
6680);
6681#[doc = "Code interpreter sessions"]
6682pub fn usage_code_interpreter_sessions<C, Fut, B, E>(
6683    client: C,
6684    params: &crate::__types::usage_code_interpreter_sessions::Params,
6685) -> UsageCodeInterpreterSessions<Fut, B, E>
6686where
6687    C: FnOnce(http::Request<String>) -> Fut,
6688    Fut: Future<Output = Result<http::Response<B>, E>>,
6689    B: http_body::Body,
6690{
6691    UsageCodeInterpreterSessions(futures::TryFutureExt::and_then(
6692        crate::__combinators::Send::new(
6693            client,
6694            || {
6695                let path = {
6696                    #[serde_with::serde_as]
6697                    #[derive(serde :: Serialize)]
6698                    struct Query < 'a > { # [serde (rename = "start_time")] start_time : & 'a i64 , # [serde (rename = "end_time")] # [serde (skip_serializing_if = "Option::is_none")] end_time : & 'a Option < i64 > , # [serde (rename = "bucket_width")] # [serde (skip_serializing_if = "Option::is_none")] bucket_width : & 'a Option < crate :: __types :: usage_code_interpreter_sessions :: params :: BucketWidth > , # [serde (rename = "project_ids")] # [serde (skip_serializing_if = "Option::is_none")] project_ids : & 'a Option < Vec < String > > , # [serde (rename = "group_by")] # [serde (skip_serializing_if = "Option::is_none")] group_by : & 'a Option < Vec < crate :: __types :: usage_code_interpreter_sessions :: params :: group_by :: Item > > , # [serde (rename = "limit")] # [serde (skip_serializing_if = "Option::is_none")] limit : & 'a Option < i64 > , # [serde (rename = "page")] # [serde (skip_serializing_if = "Option::is_none")] page : & 'a Option < String > , # [serde (skip_serializing)] _phantom : std :: marker :: PhantomData < & 'a () > , }
6699                    let crate::__types::usage_code_interpreter_sessions::Params {
6700                        start_time,
6701                        end_time,
6702                        bucket_width,
6703                        project_ids,
6704                        group_by,
6705                        limit,
6706                        page,
6707                    } = params;
6708                    #[allow(clippy::useless_format)]
6709                    let mut path = format!("/organization/usage/code_interpreter_sessions");
6710                    let query = serde_urlencoded::to_string(Query {
6711                        start_time,
6712                        end_time,
6713                        bucket_width,
6714                        project_ids,
6715                        group_by,
6716                        limit,
6717                        page,
6718                        _phantom: std::marker::PhantomData,
6719                    })?;
6720                    if !query.is_empty() {
6721                        path.push('?');
6722                        path.push_str(&query);
6723                    }
6724                    path
6725                };
6726                let body = String::new();
6727                Ok(http::Request::builder()
6728                    .method(http::Method::GET)
6729                    .uri(path)
6730                    .header(http::header::CONTENT_LENGTH, body.len())
6731                    .body(body)?)
6732            },
6733            (
6734                http::StatusCode::from_u16(200u16).unwrap(),
6735                Some(mime::APPLICATION_JSON),
6736            ),
6737        ),
6738        crate::__combinators::Json::new,
6739    ))
6740}
6741future!(
6742    UsageCodeInterpreterSessions,
6743    futures::future::AndThen<
6744        crate::__combinators::Send<Fut, B, E>,
6745        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6746        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6747    >,
6748    crate::__types::UsageResponse
6749);
6750#[doc = "Completions"]
6751pub fn usage_completions<C, Fut, B, E>(
6752    client: C,
6753    params: &crate::__types::usage_completions::Params,
6754) -> UsageCompletions<Fut, B, E>
6755where
6756    C: FnOnce(http::Request<String>) -> Fut,
6757    Fut: Future<Output = Result<http::Response<B>, E>>,
6758    B: http_body::Body,
6759{
6760    UsageCompletions(futures::TryFutureExt::and_then(
6761        crate::__combinators::Send::new(
6762            client,
6763            || {
6764                let path = {
6765                    #[serde_with::serde_as]
6766                    #[derive(serde :: Serialize)]
6767                    struct Query<'a> {
6768                        #[serde(rename = "start_time")]
6769                        start_time: &'a i64,
6770                        #[serde(rename = "end_time")]
6771                        #[serde(skip_serializing_if = "Option::is_none")]
6772                        end_time: &'a Option<i64>,
6773                        #[serde(rename = "bucket_width")]
6774                        #[serde(skip_serializing_if = "Option::is_none")]
6775                        bucket_width:
6776                            &'a Option<crate::__types::usage_completions::params::BucketWidth>,
6777                        #[serde(rename = "project_ids")]
6778                        #[serde(skip_serializing_if = "Option::is_none")]
6779                        project_ids: &'a Option<Vec<String>>,
6780                        #[serde(rename = "user_ids")]
6781                        #[serde(skip_serializing_if = "Option::is_none")]
6782                        user_ids: &'a Option<Vec<String>>,
6783                        #[serde(rename = "api_key_ids")]
6784                        #[serde(skip_serializing_if = "Option::is_none")]
6785                        api_key_ids: &'a Option<Vec<String>>,
6786                        #[serde(rename = "models")]
6787                        #[serde(skip_serializing_if = "Option::is_none")]
6788                        models: &'a Option<Vec<String>>,
6789                        #[serde(rename = "batch")]
6790                        #[serde(skip_serializing_if = "Option::is_none")]
6791                        batch: &'a Option<bool>,
6792                        #[serde(rename = "group_by")]
6793                        #[serde(skip_serializing_if = "Option::is_none")]
6794                        group_by: &'a Option<
6795                            Vec<crate::__types::usage_completions::params::group_by::Item>,
6796                        >,
6797                        #[serde(rename = "limit")]
6798                        #[serde(skip_serializing_if = "Option::is_none")]
6799                        limit: &'a Option<i64>,
6800                        #[serde(rename = "page")]
6801                        #[serde(skip_serializing_if = "Option::is_none")]
6802                        page: &'a Option<String>,
6803                        #[serde(skip_serializing)]
6804                        _phantom: std::marker::PhantomData<&'a ()>,
6805                    }
6806                    let crate::__types::usage_completions::Params {
6807                        start_time,
6808                        end_time,
6809                        bucket_width,
6810                        project_ids,
6811                        user_ids,
6812                        api_key_ids,
6813                        models,
6814                        batch,
6815                        group_by,
6816                        limit,
6817                        page,
6818                    } = params;
6819                    #[allow(clippy::useless_format)]
6820                    let mut path = format!("/organization/usage/completions");
6821                    let query = serde_urlencoded::to_string(Query {
6822                        start_time,
6823                        end_time,
6824                        bucket_width,
6825                        project_ids,
6826                        user_ids,
6827                        api_key_ids,
6828                        models,
6829                        batch,
6830                        group_by,
6831                        limit,
6832                        page,
6833                        _phantom: std::marker::PhantomData,
6834                    })?;
6835                    if !query.is_empty() {
6836                        path.push('?');
6837                        path.push_str(&query);
6838                    }
6839                    path
6840                };
6841                let body = String::new();
6842                Ok(http::Request::builder()
6843                    .method(http::Method::GET)
6844                    .uri(path)
6845                    .header(http::header::CONTENT_LENGTH, body.len())
6846                    .body(body)?)
6847            },
6848            (
6849                http::StatusCode::from_u16(200u16).unwrap(),
6850                Some(mime::APPLICATION_JSON),
6851            ),
6852        ),
6853        crate::__combinators::Json::new,
6854    ))
6855}
6856future!(
6857    UsageCompletions,
6858    futures::future::AndThen<
6859        crate::__combinators::Send<Fut, B, E>,
6860        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6861        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6862    >,
6863    crate::__types::UsageResponse
6864);
6865#[doc = "Embeddings"]
6866pub fn usage_embeddings<C, Fut, B, E>(
6867    client: C,
6868    params: &crate::__types::usage_embeddings::Params,
6869) -> UsageEmbeddings<Fut, B, E>
6870where
6871    C: FnOnce(http::Request<String>) -> Fut,
6872    Fut: Future<Output = Result<http::Response<B>, E>>,
6873    B: http_body::Body,
6874{
6875    UsageEmbeddings(futures::TryFutureExt::and_then(
6876        crate::__combinators::Send::new(
6877            client,
6878            || {
6879                let path = {
6880                    #[serde_with::serde_as]
6881                    #[derive(serde :: Serialize)]
6882                    struct Query<'a> {
6883                        #[serde(rename = "start_time")]
6884                        start_time: &'a i64,
6885                        #[serde(rename = "end_time")]
6886                        #[serde(skip_serializing_if = "Option::is_none")]
6887                        end_time: &'a Option<i64>,
6888                        #[serde(rename = "bucket_width")]
6889                        #[serde(skip_serializing_if = "Option::is_none")]
6890                        bucket_width:
6891                            &'a Option<crate::__types::usage_embeddings::params::BucketWidth>,
6892                        #[serde(rename = "project_ids")]
6893                        #[serde(skip_serializing_if = "Option::is_none")]
6894                        project_ids: &'a Option<Vec<String>>,
6895                        #[serde(rename = "user_ids")]
6896                        #[serde(skip_serializing_if = "Option::is_none")]
6897                        user_ids: &'a Option<Vec<String>>,
6898                        #[serde(rename = "api_key_ids")]
6899                        #[serde(skip_serializing_if = "Option::is_none")]
6900                        api_key_ids: &'a Option<Vec<String>>,
6901                        #[serde(rename = "models")]
6902                        #[serde(skip_serializing_if = "Option::is_none")]
6903                        models: &'a Option<Vec<String>>,
6904                        #[serde(rename = "group_by")]
6905                        #[serde(skip_serializing_if = "Option::is_none")]
6906                        group_by: &'a Option<
6907                            Vec<crate::__types::usage_embeddings::params::group_by::Item>,
6908                        >,
6909                        #[serde(rename = "limit")]
6910                        #[serde(skip_serializing_if = "Option::is_none")]
6911                        limit: &'a Option<i64>,
6912                        #[serde(rename = "page")]
6913                        #[serde(skip_serializing_if = "Option::is_none")]
6914                        page: &'a Option<String>,
6915                        #[serde(skip_serializing)]
6916                        _phantom: std::marker::PhantomData<&'a ()>,
6917                    }
6918                    let crate::__types::usage_embeddings::Params {
6919                        start_time,
6920                        end_time,
6921                        bucket_width,
6922                        project_ids,
6923                        user_ids,
6924                        api_key_ids,
6925                        models,
6926                        group_by,
6927                        limit,
6928                        page,
6929                    } = params;
6930                    #[allow(clippy::useless_format)]
6931                    let mut path = format!("/organization/usage/embeddings");
6932                    let query = serde_urlencoded::to_string(Query {
6933                        start_time,
6934                        end_time,
6935                        bucket_width,
6936                        project_ids,
6937                        user_ids,
6938                        api_key_ids,
6939                        models,
6940                        group_by,
6941                        limit,
6942                        page,
6943                        _phantom: std::marker::PhantomData,
6944                    })?;
6945                    if !query.is_empty() {
6946                        path.push('?');
6947                        path.push_str(&query);
6948                    }
6949                    path
6950                };
6951                let body = String::new();
6952                Ok(http::Request::builder()
6953                    .method(http::Method::GET)
6954                    .uri(path)
6955                    .header(http::header::CONTENT_LENGTH, body.len())
6956                    .body(body)?)
6957            },
6958            (
6959                http::StatusCode::from_u16(200u16).unwrap(),
6960                Some(mime::APPLICATION_JSON),
6961            ),
6962        ),
6963        crate::__combinators::Json::new,
6964    ))
6965}
6966future!(
6967    UsageEmbeddings,
6968    futures::future::AndThen<
6969        crate::__combinators::Send<Fut, B, E>,
6970        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6971        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
6972    >,
6973    crate::__types::UsageResponse
6974);
6975#[doc = "Images"]
6976pub fn usage_images<C, Fut, B, E>(
6977    client: C,
6978    params: &crate::__types::usage_images::Params,
6979) -> UsageImages<Fut, B, E>
6980where
6981    C: FnOnce(http::Request<String>) -> Fut,
6982    Fut: Future<Output = Result<http::Response<B>, E>>,
6983    B: http_body::Body,
6984{
6985    UsageImages(futures::TryFutureExt::and_then(
6986        crate::__combinators::Send::new(
6987            client,
6988            || {
6989                let path = {
6990                    #[serde_with::serde_as]
6991                    #[derive(serde :: Serialize)]
6992                    struct Query<'a> {
6993                        #[serde(rename = "start_time")]
6994                        start_time: &'a i64,
6995                        #[serde(rename = "end_time")]
6996                        #[serde(skip_serializing_if = "Option::is_none")]
6997                        end_time: &'a Option<i64>,
6998                        #[serde(rename = "bucket_width")]
6999                        #[serde(skip_serializing_if = "Option::is_none")]
7000                        bucket_width: &'a Option<crate::__types::usage_images::params::BucketWidth>,
7001                        #[serde(rename = "sources")]
7002                        #[serde(skip_serializing_if = "Option::is_none")]
7003                        sources:
7004                            &'a Option<Vec<crate::__types::usage_images::params::sources::Item>>,
7005                        #[serde(rename = "sizes")]
7006                        #[serde(skip_serializing_if = "Option::is_none")]
7007                        sizes: &'a Option<Vec<crate::__types::usage_images::params::sizes::Item>>,
7008                        #[serde(rename = "project_ids")]
7009                        #[serde(skip_serializing_if = "Option::is_none")]
7010                        project_ids: &'a Option<Vec<String>>,
7011                        #[serde(rename = "user_ids")]
7012                        #[serde(skip_serializing_if = "Option::is_none")]
7013                        user_ids: &'a Option<Vec<String>>,
7014                        #[serde(rename = "api_key_ids")]
7015                        #[serde(skip_serializing_if = "Option::is_none")]
7016                        api_key_ids: &'a Option<Vec<String>>,
7017                        #[serde(rename = "models")]
7018                        #[serde(skip_serializing_if = "Option::is_none")]
7019                        models: &'a Option<Vec<String>>,
7020                        #[serde(rename = "group_by")]
7021                        #[serde(skip_serializing_if = "Option::is_none")]
7022                        group_by:
7023                            &'a Option<Vec<crate::__types::usage_images::params::group_by::Item>>,
7024                        #[serde(rename = "limit")]
7025                        #[serde(skip_serializing_if = "Option::is_none")]
7026                        limit: &'a Option<i64>,
7027                        #[serde(rename = "page")]
7028                        #[serde(skip_serializing_if = "Option::is_none")]
7029                        page: &'a Option<String>,
7030                        #[serde(skip_serializing)]
7031                        _phantom: std::marker::PhantomData<&'a ()>,
7032                    }
7033                    let crate::__types::usage_images::Params {
7034                        start_time,
7035                        end_time,
7036                        bucket_width,
7037                        sources,
7038                        sizes,
7039                        project_ids,
7040                        user_ids,
7041                        api_key_ids,
7042                        models,
7043                        group_by,
7044                        limit,
7045                        page,
7046                    } = params;
7047                    #[allow(clippy::useless_format)]
7048                    let mut path = format!("/organization/usage/images");
7049                    let query = serde_urlencoded::to_string(Query {
7050                        start_time,
7051                        end_time,
7052                        bucket_width,
7053                        sources,
7054                        sizes,
7055                        project_ids,
7056                        user_ids,
7057                        api_key_ids,
7058                        models,
7059                        group_by,
7060                        limit,
7061                        page,
7062                        _phantom: std::marker::PhantomData,
7063                    })?;
7064                    if !query.is_empty() {
7065                        path.push('?');
7066                        path.push_str(&query);
7067                    }
7068                    path
7069                };
7070                let body = String::new();
7071                Ok(http::Request::builder()
7072                    .method(http::Method::GET)
7073                    .uri(path)
7074                    .header(http::header::CONTENT_LENGTH, body.len())
7075                    .body(body)?)
7076            },
7077            (
7078                http::StatusCode::from_u16(200u16).unwrap(),
7079                Some(mime::APPLICATION_JSON),
7080            ),
7081        ),
7082        crate::__combinators::Json::new,
7083    ))
7084}
7085future!(
7086    UsageImages,
7087    futures::future::AndThen<
7088        crate::__combinators::Send<Fut, B, E>,
7089        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
7090        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
7091    >,
7092    crate::__types::UsageResponse
7093);
7094#[doc = "Moderations"]
7095pub fn usage_moderations<C, Fut, B, E>(
7096    client: C,
7097    params: &crate::__types::usage_moderations::Params,
7098) -> UsageModerations<Fut, B, E>
7099where
7100    C: FnOnce(http::Request<String>) -> Fut,
7101    Fut: Future<Output = Result<http::Response<B>, E>>,
7102    B: http_body::Body,
7103{
7104    UsageModerations(futures::TryFutureExt::and_then(
7105        crate::__combinators::Send::new(
7106            client,
7107            || {
7108                let path = {
7109                    #[serde_with::serde_as]
7110                    #[derive(serde :: Serialize)]
7111                    struct Query<'a> {
7112                        #[serde(rename = "start_time")]
7113                        start_time: &'a i64,
7114                        #[serde(rename = "end_time")]
7115                        #[serde(skip_serializing_if = "Option::is_none")]
7116                        end_time: &'a Option<i64>,
7117                        #[serde(rename = "bucket_width")]
7118                        #[serde(skip_serializing_if = "Option::is_none")]
7119                        bucket_width:
7120                            &'a Option<crate::__types::usage_moderations::params::BucketWidth>,
7121                        #[serde(rename = "project_ids")]
7122                        #[serde(skip_serializing_if = "Option::is_none")]
7123                        project_ids: &'a Option<Vec<String>>,
7124                        #[serde(rename = "user_ids")]
7125                        #[serde(skip_serializing_if = "Option::is_none")]
7126                        user_ids: &'a Option<Vec<String>>,
7127                        #[serde(rename = "api_key_ids")]
7128                        #[serde(skip_serializing_if = "Option::is_none")]
7129                        api_key_ids: &'a Option<Vec<String>>,
7130                        #[serde(rename = "models")]
7131                        #[serde(skip_serializing_if = "Option::is_none")]
7132                        models: &'a Option<Vec<String>>,
7133                        #[serde(rename = "group_by")]
7134                        #[serde(skip_serializing_if = "Option::is_none")]
7135                        group_by: &'a Option<
7136                            Vec<crate::__types::usage_moderations::params::group_by::Item>,
7137                        >,
7138                        #[serde(rename = "limit")]
7139                        #[serde(skip_serializing_if = "Option::is_none")]
7140                        limit: &'a Option<i64>,
7141                        #[serde(rename = "page")]
7142                        #[serde(skip_serializing_if = "Option::is_none")]
7143                        page: &'a Option<String>,
7144                        #[serde(skip_serializing)]
7145                        _phantom: std::marker::PhantomData<&'a ()>,
7146                    }
7147                    let crate::__types::usage_moderations::Params {
7148                        start_time,
7149                        end_time,
7150                        bucket_width,
7151                        project_ids,
7152                        user_ids,
7153                        api_key_ids,
7154                        models,
7155                        group_by,
7156                        limit,
7157                        page,
7158                    } = params;
7159                    #[allow(clippy::useless_format)]
7160                    let mut path = format!("/organization/usage/moderations");
7161                    let query = serde_urlencoded::to_string(Query {
7162                        start_time,
7163                        end_time,
7164                        bucket_width,
7165                        project_ids,
7166                        user_ids,
7167                        api_key_ids,
7168                        models,
7169                        group_by,
7170                        limit,
7171                        page,
7172                        _phantom: std::marker::PhantomData,
7173                    })?;
7174                    if !query.is_empty() {
7175                        path.push('?');
7176                        path.push_str(&query);
7177                    }
7178                    path
7179                };
7180                let body = String::new();
7181                Ok(http::Request::builder()
7182                    .method(http::Method::GET)
7183                    .uri(path)
7184                    .header(http::header::CONTENT_LENGTH, body.len())
7185                    .body(body)?)
7186            },
7187            (
7188                http::StatusCode::from_u16(200u16).unwrap(),
7189                Some(mime::APPLICATION_JSON),
7190            ),
7191        ),
7192        crate::__combinators::Json::new,
7193    ))
7194}
7195future!(
7196    UsageModerations,
7197    futures::future::AndThen<
7198        crate::__combinators::Send<Fut, B, E>,
7199        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
7200        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
7201    >,
7202    crate::__types::UsageResponse
7203);
7204#[doc = "Vector stores"]
7205pub fn usage_vector_stores<C, Fut, B, E>(
7206    client: C,
7207    params: &crate::__types::usage_vector_stores::Params,
7208) -> UsageVectorStores<Fut, B, E>
7209where
7210    C: FnOnce(http::Request<String>) -> Fut,
7211    Fut: Future<Output = Result<http::Response<B>, E>>,
7212    B: http_body::Body,
7213{
7214    UsageVectorStores(futures::TryFutureExt::and_then(
7215        crate::__combinators::Send::new(
7216            client,
7217            || {
7218                let path = {
7219                    #[serde_with::serde_as]
7220                    #[derive(serde :: Serialize)]
7221                    struct Query<'a> {
7222                        #[serde(rename = "start_time")]
7223                        start_time: &'a i64,
7224                        #[serde(rename = "end_time")]
7225                        #[serde(skip_serializing_if = "Option::is_none")]
7226                        end_time: &'a Option<i64>,
7227                        #[serde(rename = "bucket_width")]
7228                        #[serde(skip_serializing_if = "Option::is_none")]
7229                        bucket_width:
7230                            &'a Option<crate::__types::usage_vector_stores::params::BucketWidth>,
7231                        #[serde(rename = "project_ids")]
7232                        #[serde(skip_serializing_if = "Option::is_none")]
7233                        project_ids: &'a Option<Vec<String>>,
7234                        #[serde(rename = "group_by")]
7235                        #[serde(skip_serializing_if = "Option::is_none")]
7236                        group_by: &'a Option<
7237                            Vec<crate::__types::usage_vector_stores::params::group_by::Item>,
7238                        >,
7239                        #[serde(rename = "limit")]
7240                        #[serde(skip_serializing_if = "Option::is_none")]
7241                        limit: &'a Option<i64>,
7242                        #[serde(rename = "page")]
7243                        #[serde(skip_serializing_if = "Option::is_none")]
7244                        page: &'a Option<String>,
7245                        #[serde(skip_serializing)]
7246                        _phantom: std::marker::PhantomData<&'a ()>,
7247                    }
7248                    let crate::__types::usage_vector_stores::Params {
7249                        start_time,
7250                        end_time,
7251                        bucket_width,
7252                        project_ids,
7253                        group_by,
7254                        limit,
7255                        page,
7256                    } = params;
7257                    #[allow(clippy::useless_format)]
7258                    let mut path = format!("/organization/usage/vector_stores");
7259                    let query = serde_urlencoded::to_string(Query {
7260                        start_time,
7261                        end_time,
7262                        bucket_width,
7263                        project_ids,
7264                        group_by,
7265                        limit,
7266                        page,
7267                        _phantom: std::marker::PhantomData,
7268                    })?;
7269                    if !query.is_empty() {
7270                        path.push('?');
7271                        path.push_str(&query);
7272                    }
7273                    path
7274                };
7275                let body = String::new();
7276                Ok(http::Request::builder()
7277                    .method(http::Method::GET)
7278                    .uri(path)
7279                    .header(http::header::CONTENT_LENGTH, body.len())
7280                    .body(body)?)
7281            },
7282            (
7283                http::StatusCode::from_u16(200u16).unwrap(),
7284                Some(mime::APPLICATION_JSON),
7285            ),
7286        ),
7287        crate::__combinators::Json::new,
7288    ))
7289}
7290future!(
7291    UsageVectorStores,
7292    futures::future::AndThen<
7293        crate::__combinators::Send<Fut, B, E>,
7294        crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
7295        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UsageResponse>,
7296    >,
7297    crate::__types::UsageResponse
7298);
7299#[doc = "List users"]
7300pub fn list_users<C, Fut, B, E>(
7301    client: C,
7302    params: &crate::__types::list_users::Params,
7303) -> ListUsers<Fut, B, E>
7304where
7305    C: FnOnce(http::Request<String>) -> Fut,
7306    Fut: Future<Output = Result<http::Response<B>, E>>,
7307    B: http_body::Body,
7308{
7309    ListUsers(futures::TryFutureExt::and_then(
7310        crate::__combinators::Send::new(
7311            client,
7312            || {
7313                let path = {
7314                    #[serde_with::serde_as]
7315                    #[derive(serde :: Serialize)]
7316                    struct Query<'a> {
7317                        #[serde(rename = "limit")]
7318                        #[serde(skip_serializing_if = "Option::is_none")]
7319                        limit: &'a Option<i64>,
7320                        #[serde(rename = "after")]
7321                        #[serde(skip_serializing_if = "Option::is_none")]
7322                        after: &'a Option<String>,
7323                        #[serde(rename = "emails")]
7324                        #[serde(skip_serializing_if = "Option::is_none")]
7325                        emails: &'a Option<Vec<String>>,
7326                        #[serde(skip_serializing)]
7327                        _phantom: std::marker::PhantomData<&'a ()>,
7328                    }
7329                    let crate::__types::list_users::Params {
7330                        limit,
7331                        after,
7332                        emails,
7333                    } = params;
7334                    #[allow(clippy::useless_format)]
7335                    let mut path = format!("/organization/users");
7336                    let query = serde_urlencoded::to_string(Query {
7337                        limit,
7338                        after,
7339                        emails,
7340                        _phantom: std::marker::PhantomData,
7341                    })?;
7342                    if !query.is_empty() {
7343                        path.push('?');
7344                        path.push_str(&query);
7345                    }
7346                    path
7347                };
7348                let body = String::new();
7349                Ok(http::Request::builder()
7350                    .method(http::Method::GET)
7351                    .uri(path)
7352                    .header(http::header::CONTENT_LENGTH, body.len())
7353                    .body(body)?)
7354            },
7355            (
7356                http::StatusCode::from_u16(200u16).unwrap(),
7357                Some(mime::APPLICATION_JSON),
7358            ),
7359        ),
7360        crate::__combinators::Json::new,
7361    ))
7362}
7363future!(
7364    ListUsers,
7365    futures::future::AndThen<
7366        crate::__combinators::Send<Fut, B, E>,
7367        crate::__combinators::Json<B, E, crate::__types::UserListResponse>,
7368        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::UserListResponse>,
7369    >,
7370    crate::__types::UserListResponse
7371);
7372#[doc = "Retrieve user"]
7373pub fn retrieve_user<C, Fut, B, E>(
7374    client: C,
7375    params: &crate::__types::retrieve_user::Params,
7376) -> RetrieveUser<Fut, B, E>
7377where
7378    C: FnOnce(http::Request<String>) -> Fut,
7379    Fut: Future<Output = Result<http::Response<B>, E>>,
7380    B: http_body::Body,
7381{
7382    RetrieveUser(futures::TryFutureExt::and_then(
7383        crate::__combinators::Send::new(
7384            client,
7385            || {
7386                let path = {
7387                    #[serde_with::serde_as]
7388                    #[derive(serde :: Serialize)]
7389                    struct Query<'a> {
7390                        #[serde(skip_serializing)]
7391                        _phantom: std::marker::PhantomData<&'a ()>,
7392                    }
7393                    let crate::__types::retrieve_user::Params { user_id } = params;
7394                    #[allow(clippy::useless_format)]
7395                    let mut path = format!("/organization/users/{user_id}");
7396                    let query = serde_urlencoded::to_string(Query {
7397                        _phantom: std::marker::PhantomData,
7398                    })?;
7399                    if !query.is_empty() {
7400                        path.push('?');
7401                        path.push_str(&query);
7402                    }
7403                    path
7404                };
7405                let body = String::new();
7406                Ok(http::Request::builder()
7407                    .method(http::Method::GET)
7408                    .uri(path)
7409                    .header(http::header::CONTENT_LENGTH, body.len())
7410                    .body(body)?)
7411            },
7412            (
7413                http::StatusCode::from_u16(200u16).unwrap(),
7414                Some(mime::APPLICATION_JSON),
7415            ),
7416        ),
7417        crate::__combinators::Json::new,
7418    ))
7419}
7420future!(
7421    RetrieveUser,
7422    futures::future::AndThen<
7423        crate::__combinators::Send<Fut, B, E>,
7424        crate::__combinators::Json<B, E, crate::__types::User>,
7425        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::User>,
7426    >,
7427    crate::__types::User
7428);
7429#[doc = "Modify user"]
7430pub fn modify_user<C, Fut, B, E>(
7431    client: C,
7432    params: &crate::__types::modify_user::Params,
7433    request: &crate::__types::UserRoleUpdateRequest,
7434) -> ModifyUser<Fut, B, E>
7435where
7436    C: FnOnce(http::Request<String>) -> Fut,
7437    Fut: Future<Output = Result<http::Response<B>, E>>,
7438    B: http_body::Body,
7439{
7440    ModifyUser(futures::TryFutureExt::and_then(
7441        crate::__combinators::Send::new(
7442            client,
7443            || {
7444                let path = {
7445                    #[serde_with::serde_as]
7446                    #[derive(serde :: Serialize)]
7447                    struct Query<'a> {
7448                        #[serde(skip_serializing)]
7449                        _phantom: std::marker::PhantomData<&'a ()>,
7450                    }
7451                    let crate::__types::modify_user::Params { user_id } = params;
7452                    #[allow(clippy::useless_format)]
7453                    let mut path = format!("/organization/users/{user_id}");
7454                    let query = serde_urlencoded::to_string(Query {
7455                        _phantom: std::marker::PhantomData,
7456                    })?;
7457                    if !query.is_empty() {
7458                        path.push('?');
7459                        path.push_str(&query);
7460                    }
7461                    path
7462                };
7463                let body = serde_json::to_string(request)?;
7464                Ok(http::Request::builder()
7465                    .method(http::Method::POST)
7466                    .uri(path)
7467                    .header(http::header::CONTENT_LENGTH, body.len())
7468                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
7469                    .body(body)?)
7470            },
7471            (
7472                http::StatusCode::from_u16(200u16).unwrap(),
7473                Some(mime::APPLICATION_JSON),
7474            ),
7475        ),
7476        crate::__combinators::Json::new,
7477    ))
7478}
7479future!(
7480    ModifyUser,
7481    futures::future::AndThen<
7482        crate::__combinators::Send<Fut, B, E>,
7483        crate::__combinators::Json<B, E, crate::__types::User>,
7484        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::User>,
7485    >,
7486    crate::__types::User
7487);
7488#[doc = "Delete user"]
7489pub fn delete_user<C, Fut, B, E>(
7490    client: C,
7491    params: &crate::__types::delete_user::Params,
7492) -> DeleteUser<Fut, B, E>
7493where
7494    C: FnOnce(http::Request<String>) -> Fut,
7495    Fut: Future<Output = Result<http::Response<B>, E>>,
7496    B: http_body::Body,
7497{
7498    DeleteUser(futures::TryFutureExt::and_then(
7499        crate::__combinators::Send::new(
7500            client,
7501            || {
7502                let path = {
7503                    #[serde_with::serde_as]
7504                    #[derive(serde :: Serialize)]
7505                    struct Query<'a> {
7506                        #[serde(skip_serializing)]
7507                        _phantom: std::marker::PhantomData<&'a ()>,
7508                    }
7509                    let crate::__types::delete_user::Params { user_id } = params;
7510                    #[allow(clippy::useless_format)]
7511                    let mut path = format!("/organization/users/{user_id}");
7512                    let query = serde_urlencoded::to_string(Query {
7513                        _phantom: std::marker::PhantomData,
7514                    })?;
7515                    if !query.is_empty() {
7516                        path.push('?');
7517                        path.push_str(&query);
7518                    }
7519                    path
7520                };
7521                let body = String::new();
7522                Ok(http::Request::builder()
7523                    .method(http::Method::DELETE)
7524                    .uri(path)
7525                    .header(http::header::CONTENT_LENGTH, body.len())
7526                    .body(body)?)
7527            },
7528            (
7529                http::StatusCode::from_u16(200u16).unwrap(),
7530                Some(mime::APPLICATION_JSON),
7531            ),
7532        ),
7533        crate::__combinators::Json::new,
7534    ))
7535}
7536future!(
7537    DeleteUser,
7538    futures::future::AndThen<
7539        crate::__combinators::Send<Fut, B, E>,
7540        crate::__combinators::Json<B, E, crate::__types::UserDeleteResponse>,
7541        fn(
7542            http::Response<B>,
7543        ) -> crate::__combinators::Json<B, E, crate::__types::UserDeleteResponse>,
7544    >,
7545    crate::__types::UserDeleteResponse
7546);
7547#[doc = "Create session"]
7548pub fn create_realtime_session<C, Fut, B, E>(
7549    client: C,
7550    request: &crate::__types::RealtimeSessionCreateRequest,
7551) -> CreateRealtimeSession<Fut, B, E>
7552where
7553    C: FnOnce(http::Request<String>) -> Fut,
7554    Fut: Future<Output = Result<http::Response<B>, E>>,
7555    B: http_body::Body,
7556{
7557    CreateRealtimeSession(futures::TryFutureExt::and_then(
7558        crate::__combinators::Send::new(
7559            client,
7560            || {
7561                let path = "/realtime/sessions";
7562                let body = serde_json::to_string(request)?;
7563                Ok(http::Request::builder()
7564                    .method(http::Method::POST)
7565                    .uri(path)
7566                    .header(http::header::CONTENT_LENGTH, body.len())
7567                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
7568                    .body(body)?)
7569            },
7570            (
7571                http::StatusCode::from_u16(200u16).unwrap(),
7572                Some(mime::APPLICATION_JSON),
7573            ),
7574        ),
7575        crate::__combinators::Json::new,
7576    ))
7577}
7578future!(
7579    CreateRealtimeSession,
7580    futures::future::AndThen<
7581        crate::__combinators::Send<Fut, B, E>,
7582        crate::__combinators::Json<B, E, crate::__types::RealtimeSessionCreateResponse>,
7583        fn(
7584            http::Response<B>,
7585        )
7586            -> crate::__combinators::Json<B, E, crate::__types::RealtimeSessionCreateResponse>,
7587    >,
7588    crate::__types::RealtimeSessionCreateResponse
7589);
7590#[doc = "Create transcription session"]
7591pub fn create_realtime_transcription_session<C, Fut, B, E>(
7592    client: C,
7593    request: &crate::__types::RealtimeTranscriptionSessionCreateRequest,
7594) -> CreateRealtimeTranscriptionSession<Fut, B, E>
7595where
7596    C: FnOnce(http::Request<String>) -> Fut,
7597    Fut: Future<Output = Result<http::Response<B>, E>>,
7598    B: http_body::Body,
7599{
7600    CreateRealtimeTranscriptionSession(futures::TryFutureExt::and_then(
7601        crate::__combinators::Send::new(
7602            client,
7603            || {
7604                let path = "/realtime/transcription_sessions";
7605                let body = serde_json::to_string(request)?;
7606                Ok(http::Request::builder()
7607                    .method(http::Method::POST)
7608                    .uri(path)
7609                    .header(http::header::CONTENT_LENGTH, body.len())
7610                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
7611                    .body(body)?)
7612            },
7613            (
7614                http::StatusCode::from_u16(200u16).unwrap(),
7615                Some(mime::APPLICATION_JSON),
7616            ),
7617        ),
7618        crate::__combinators::Json::new,
7619    ))
7620}
7621future!(
7622    CreateRealtimeTranscriptionSession,
7623    futures::future::AndThen<
7624        crate::__combinators::Send<Fut, B, E>,
7625        crate::__combinators::Json<
7626            B,
7627            E,
7628            crate::__types::RealtimeTranscriptionSessionCreateResponse,
7629        >,
7630        fn(
7631            http::Response<B>,
7632        ) -> crate::__combinators::Json<
7633            B,
7634            E,
7635            crate::__types::RealtimeTranscriptionSessionCreateResponse,
7636        >,
7637    >,
7638    crate::__types::RealtimeTranscriptionSessionCreateResponse
7639);
7640#[doc = "Create a model response"]
7641pub fn create_response<C, Fut, B, E>(
7642    client: C,
7643    request: &crate::__types::CreateResponse,
7644) -> CreateResponse<Fut, B, E>
7645where
7646    C: FnOnce(http::Request<String>) -> Fut,
7647    Fut: Future<Output = Result<http::Response<B>, E>>,
7648    B: http_body::Body,
7649{
7650    CreateResponse(futures::TryFutureExt::and_then(
7651        crate::__combinators::Send::new(
7652            client,
7653            || {
7654                let path = "/responses";
7655                let body = serde_json::to_string(request)?;
7656                Ok(http::Request::builder()
7657                    .method(http::Method::POST)
7658                    .uri(path)
7659                    .header(http::header::CONTENT_LENGTH, body.len())
7660                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
7661                    .body(body)?)
7662            },
7663            (
7664                http::StatusCode::from_u16(200u16).unwrap(),
7665                Some(mime::APPLICATION_JSON),
7666            ),
7667        ),
7668        crate::__combinators::Json::new,
7669    ))
7670}
7671future!(
7672    CreateResponse,
7673    futures::future::AndThen<
7674        crate::__combinators::Send<Fut, B, E>,
7675        crate::__combinators::Json<B, E, crate::__types::Response>,
7676        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Response>,
7677    >,
7678    crate::__types::Response
7679);
7680#[doc = "Create a model response"]
7681pub fn create_response_stream<C, Fut, B, E>(
7682    client: C,
7683    request: &crate::__types::CreateResponse,
7684) -> CreateResponseStream<Fut, B, E>
7685where
7686    C: FnOnce(http::Request<String>) -> Fut,
7687    Fut: Future<Output = Result<http::Response<B>, E>>,
7688    B: http_body::Body,
7689{
7690    CreateResponseStream(futures::TryFutureExt::map_ok(
7691        crate::__combinators::Send::new(
7692            client,
7693            || {
7694                let path = "/responses";
7695                let body = serde_json::to_string(request)?;
7696                Ok(http::Request::builder()
7697                    .method(http::Method::POST)
7698                    .uri(path)
7699                    .header(http::header::CONTENT_LENGTH, body.len())
7700                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
7701                    .body(body)?)
7702            },
7703            (
7704                http::StatusCode::from_u16(200u16).unwrap(),
7705                Some(mime::TEXT_EVENT_STREAM),
7706            ),
7707        ),
7708        crate::__combinators::EventStream::new,
7709    ))
7710}
7711future ! (CreateResponseStream , futures :: future :: MapOk < crate :: __combinators :: Send < Fut , B , E > , fn (http :: Response < B >) -> crate :: __combinators :: EventStream < B , crate :: __types :: ResponseStreamEvent > , > , crate :: __combinators :: EventStream < B , crate :: __types :: ResponseStreamEvent >);
7712#[doc = "Get a model response"]
7713pub fn get_response<C, Fut, B, E>(
7714    client: C,
7715    params: &crate::__types::get_response::Params,
7716) -> GetResponse<Fut, B, E>
7717where
7718    C: FnOnce(http::Request<String>) -> Fut,
7719    Fut: Future<Output = Result<http::Response<B>, E>>,
7720    B: http_body::Body,
7721{
7722    GetResponse(futures::TryFutureExt::and_then(
7723        crate::__combinators::Send::new(
7724            client,
7725            || {
7726                let path = {
7727                    #[serde_with::serde_as]
7728                    #[derive(serde :: Serialize)]
7729                    struct Query<'a> {
7730                        #[serde(rename = "include")]
7731                        #[serde(skip_serializing_if = "Option::is_none")]
7732                        include: &'a Option<Vec<crate::__types::Includable>>,
7733                        #[serde(rename = "stream")]
7734                        #[serde(skip_serializing_if = "Option::is_none")]
7735                        stream: &'a Option<bool>,
7736                        #[serde(rename = "starting_after")]
7737                        #[serde(skip_serializing_if = "Option::is_none")]
7738                        starting_after: &'a Option<i64>,
7739                        #[serde(rename = "include_obfuscation")]
7740                        #[serde(skip_serializing_if = "Option::is_none")]
7741                        include_obfuscation: &'a Option<bool>,
7742                        #[serde(skip_serializing)]
7743                        _phantom: std::marker::PhantomData<&'a ()>,
7744                    }
7745                    let crate::__types::get_response::Params {
7746                        response_id,
7747                        include,
7748                        stream,
7749                        starting_after,
7750                        include_obfuscation,
7751                    } = params;
7752                    #[allow(clippy::useless_format)]
7753                    let mut path = format!("/responses/{response_id}");
7754                    let query = serde_urlencoded::to_string(Query {
7755                        include,
7756                        stream,
7757                        starting_after,
7758                        include_obfuscation,
7759                        _phantom: std::marker::PhantomData,
7760                    })?;
7761                    if !query.is_empty() {
7762                        path.push('?');
7763                        path.push_str(&query);
7764                    }
7765                    path
7766                };
7767                let body = String::new();
7768                Ok(http::Request::builder()
7769                    .method(http::Method::GET)
7770                    .uri(path)
7771                    .header(http::header::CONTENT_LENGTH, body.len())
7772                    .body(body)?)
7773            },
7774            (
7775                http::StatusCode::from_u16(200u16).unwrap(),
7776                Some(mime::APPLICATION_JSON),
7777            ),
7778        ),
7779        crate::__combinators::Json::new,
7780    ))
7781}
7782future!(
7783    GetResponse,
7784    futures::future::AndThen<
7785        crate::__combinators::Send<Fut, B, E>,
7786        crate::__combinators::Json<B, E, crate::__types::Response>,
7787        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Response>,
7788    >,
7789    crate::__types::Response
7790);
7791#[doc = "Delete a model response"]
7792pub fn delete_response<C, Fut, B, E>(
7793    client: C,
7794    params: &crate::__types::delete_response::Params,
7795) -> DeleteResponse<Fut, B, E>
7796where
7797    C: FnOnce(http::Request<String>) -> Fut,
7798    Fut: Future<Output = Result<http::Response<B>, E>>,
7799    B: http_body::Body,
7800{
7801    DeleteResponse(futures::TryFutureExt::map_ok(
7802        crate::__combinators::Send::new(
7803            client,
7804            || {
7805                let path = {
7806                    #[serde_with::serde_as]
7807                    #[derive(serde :: Serialize)]
7808                    struct Query<'a> {
7809                        #[serde(skip_serializing)]
7810                        _phantom: std::marker::PhantomData<&'a ()>,
7811                    }
7812                    let crate::__types::delete_response::Params { response_id } = params;
7813                    #[allow(clippy::useless_format)]
7814                    let mut path = format!("/responses/{response_id}");
7815                    let query = serde_urlencoded::to_string(Query {
7816                        _phantom: std::marker::PhantomData,
7817                    })?;
7818                    if !query.is_empty() {
7819                        path.push('?');
7820                        path.push_str(&query);
7821                    }
7822                    path
7823                };
7824                let body = String::new();
7825                Ok(http::Request::builder()
7826                    .method(http::Method::DELETE)
7827                    .uri(path)
7828                    .header(http::header::CONTENT_LENGTH, body.len())
7829                    .body(body)?)
7830            },
7831            (http::StatusCode::from_u16(200u16).unwrap(), None),
7832        ),
7833        |_| (),
7834    ))
7835}
7836future!(
7837    DeleteResponse,
7838    futures::future::MapOk<crate::__combinators::Send<Fut, B, E>, fn(http::Response<B>) -> ()>,
7839    ()
7840);
7841#[doc = "Cancel a response"]
7842pub fn cancel_response<C, Fut, B, E>(
7843    client: C,
7844    params: &crate::__types::cancel_response::Params,
7845) -> CancelResponse<Fut, B, E>
7846where
7847    C: FnOnce(http::Request<String>) -> Fut,
7848    Fut: Future<Output = Result<http::Response<B>, E>>,
7849    B: http_body::Body,
7850{
7851    CancelResponse(futures::TryFutureExt::and_then(
7852        crate::__combinators::Send::new(
7853            client,
7854            || {
7855                let path = {
7856                    #[serde_with::serde_as]
7857                    #[derive(serde :: Serialize)]
7858                    struct Query<'a> {
7859                        #[serde(skip_serializing)]
7860                        _phantom: std::marker::PhantomData<&'a ()>,
7861                    }
7862                    let crate::__types::cancel_response::Params { response_id } = params;
7863                    #[allow(clippy::useless_format)]
7864                    let mut path = format!("/responses/{response_id}/cancel");
7865                    let query = serde_urlencoded::to_string(Query {
7866                        _phantom: std::marker::PhantomData,
7867                    })?;
7868                    if !query.is_empty() {
7869                        path.push('?');
7870                        path.push_str(&query);
7871                    }
7872                    path
7873                };
7874                let body = String::new();
7875                Ok(http::Request::builder()
7876                    .method(http::Method::POST)
7877                    .uri(path)
7878                    .header(http::header::CONTENT_LENGTH, body.len())
7879                    .body(body)?)
7880            },
7881            (
7882                http::StatusCode::from_u16(200u16).unwrap(),
7883                Some(mime::APPLICATION_JSON),
7884            ),
7885        ),
7886        crate::__combinators::Json::new,
7887    ))
7888}
7889future!(
7890    CancelResponse,
7891    futures::future::AndThen<
7892        crate::__combinators::Send<Fut, B, E>,
7893        crate::__combinators::Json<B, E, crate::__types::Response>,
7894        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Response>,
7895    >,
7896    crate::__types::Response
7897);
7898#[doc = "List input items"]
7899pub fn list_input_items<C, Fut, B, E>(
7900    client: C,
7901    params: &crate::__types::list_input_items::Params,
7902) -> ListInputItems<Fut, B, E>
7903where
7904    C: FnOnce(http::Request<String>) -> Fut,
7905    Fut: Future<Output = Result<http::Response<B>, E>>,
7906    B: http_body::Body,
7907{
7908    ListInputItems(futures::TryFutureExt::and_then(
7909        crate::__combinators::Send::new(
7910            client,
7911            || {
7912                let path = {
7913                    #[serde_with::serde_as]
7914                    #[derive(serde :: Serialize)]
7915                    struct Query<'a> {
7916                        #[serde(rename = "limit")]
7917                        #[serde(skip_serializing_if = "Option::is_none")]
7918                        limit: &'a Option<i64>,
7919                        #[serde(rename = "order")]
7920                        #[serde(skip_serializing_if = "Option::is_none")]
7921                        order: &'a Option<crate::__types::list_input_items::params::Order>,
7922                        #[serde(rename = "after")]
7923                        #[serde(skip_serializing_if = "Option::is_none")]
7924                        after: &'a Option<String>,
7925                        #[serde(rename = "include")]
7926                        #[serde(skip_serializing_if = "Option::is_none")]
7927                        include: &'a Option<Vec<crate::__types::Includable>>,
7928                        #[serde(skip_serializing)]
7929                        _phantom: std::marker::PhantomData<&'a ()>,
7930                    }
7931                    let crate::__types::list_input_items::Params {
7932                        response_id,
7933                        limit,
7934                        order,
7935                        after,
7936                        include,
7937                    } = params;
7938                    #[allow(clippy::useless_format)]
7939                    let mut path = format!("/responses/{response_id}/input_items");
7940                    let query = serde_urlencoded::to_string(Query {
7941                        limit,
7942                        order,
7943                        after,
7944                        include,
7945                        _phantom: std::marker::PhantomData,
7946                    })?;
7947                    if !query.is_empty() {
7948                        path.push('?');
7949                        path.push_str(&query);
7950                    }
7951                    path
7952                };
7953                let body = String::new();
7954                Ok(http::Request::builder()
7955                    .method(http::Method::GET)
7956                    .uri(path)
7957                    .header(http::header::CONTENT_LENGTH, body.len())
7958                    .body(body)?)
7959            },
7960            (
7961                http::StatusCode::from_u16(200u16).unwrap(),
7962                Some(mime::APPLICATION_JSON),
7963            ),
7964        ),
7965        crate::__combinators::Json::new,
7966    ))
7967}
7968future!(
7969    ListInputItems,
7970    futures::future::AndThen<
7971        crate::__combinators::Send<Fut, B, E>,
7972        crate::__combinators::Json<B, E, crate::__types::ResponseItemList>,
7973        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ResponseItemList>,
7974    >,
7975    crate::__types::ResponseItemList
7976);
7977#[doc = "Create thread and run"]
7978pub fn create_thread_and_run<C, Fut, B, E>(
7979    client: C,
7980    request: &crate::__types::CreateThreadAndRunRequest,
7981) -> CreateThreadAndRun<Fut, B, E>
7982where
7983    C: FnOnce(http::Request<String>) -> Fut,
7984    Fut: Future<Output = Result<http::Response<B>, E>>,
7985    B: http_body::Body,
7986{
7987    CreateThreadAndRun(futures::TryFutureExt::and_then(
7988        crate::__combinators::Send::new(
7989            client,
7990            || {
7991                let path = "/threads/runs";
7992                let body = serde_json::to_string(request)?;
7993                Ok(http::Request::builder()
7994                    .method(http::Method::POST)
7995                    .uri(path)
7996                    .header(http::header::CONTENT_LENGTH, body.len())
7997                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
7998                    .body(body)?)
7999            },
8000            (
8001                http::StatusCode::from_u16(200u16).unwrap(),
8002                Some(mime::APPLICATION_JSON),
8003            ),
8004        ),
8005        crate::__combinators::Json::new,
8006    ))
8007}
8008future!(
8009    CreateThreadAndRun,
8010    futures::future::AndThen<
8011        crate::__combinators::Send<Fut, B, E>,
8012        crate::__combinators::Json<B, E, crate::__types::RunObject>,
8013        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunObject>,
8014    >,
8015    crate::__types::RunObject
8016);
8017#[doc = "Retrieve thread"]
8018pub fn get_thread<C, Fut, B, E>(
8019    client: C,
8020    params: &crate::__types::get_thread::Params,
8021) -> GetThread<Fut, B, E>
8022where
8023    C: FnOnce(http::Request<String>) -> Fut,
8024    Fut: Future<Output = Result<http::Response<B>, E>>,
8025    B: http_body::Body,
8026{
8027    GetThread(futures::TryFutureExt::and_then(
8028        crate::__combinators::Send::new(
8029            client,
8030            || {
8031                let path = {
8032                    #[serde_with::serde_as]
8033                    #[derive(serde :: Serialize)]
8034                    struct Query<'a> {
8035                        #[serde(skip_serializing)]
8036                        _phantom: std::marker::PhantomData<&'a ()>,
8037                    }
8038                    let crate::__types::get_thread::Params { thread_id } = params;
8039                    #[allow(clippy::useless_format)]
8040                    let mut path = format!("/threads/{thread_id}");
8041                    let query = serde_urlencoded::to_string(Query {
8042                        _phantom: std::marker::PhantomData,
8043                    })?;
8044                    if !query.is_empty() {
8045                        path.push('?');
8046                        path.push_str(&query);
8047                    }
8048                    path
8049                };
8050                let body = String::new();
8051                Ok(http::Request::builder()
8052                    .method(http::Method::GET)
8053                    .uri(path)
8054                    .header(http::header::CONTENT_LENGTH, body.len())
8055                    .body(body)?)
8056            },
8057            (
8058                http::StatusCode::from_u16(200u16).unwrap(),
8059                Some(mime::APPLICATION_JSON),
8060            ),
8061        ),
8062        crate::__combinators::Json::new,
8063    ))
8064}
8065future!(
8066    GetThread,
8067    futures::future::AndThen<
8068        crate::__combinators::Send<Fut, B, E>,
8069        crate::__combinators::Json<B, E, crate::__types::ThreadObject>,
8070        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ThreadObject>,
8071    >,
8072    crate::__types::ThreadObject
8073);
8074#[doc = "Modify thread"]
8075pub fn modify_thread<C, Fut, B, E>(
8076    client: C,
8077    params: &crate::__types::modify_thread::Params,
8078    request: &crate::__types::ModifyThreadRequest,
8079) -> ModifyThread<Fut, B, E>
8080where
8081    C: FnOnce(http::Request<String>) -> Fut,
8082    Fut: Future<Output = Result<http::Response<B>, E>>,
8083    B: http_body::Body,
8084{
8085    ModifyThread(futures::TryFutureExt::and_then(
8086        crate::__combinators::Send::new(
8087            client,
8088            || {
8089                let path = {
8090                    #[serde_with::serde_as]
8091                    #[derive(serde :: Serialize)]
8092                    struct Query<'a> {
8093                        #[serde(skip_serializing)]
8094                        _phantom: std::marker::PhantomData<&'a ()>,
8095                    }
8096                    let crate::__types::modify_thread::Params { thread_id } = params;
8097                    #[allow(clippy::useless_format)]
8098                    let mut path = format!("/threads/{thread_id}");
8099                    let query = serde_urlencoded::to_string(Query {
8100                        _phantom: std::marker::PhantomData,
8101                    })?;
8102                    if !query.is_empty() {
8103                        path.push('?');
8104                        path.push_str(&query);
8105                    }
8106                    path
8107                };
8108                let body = serde_json::to_string(request)?;
8109                Ok(http::Request::builder()
8110                    .method(http::Method::POST)
8111                    .uri(path)
8112                    .header(http::header::CONTENT_LENGTH, body.len())
8113                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
8114                    .body(body)?)
8115            },
8116            (
8117                http::StatusCode::from_u16(200u16).unwrap(),
8118                Some(mime::APPLICATION_JSON),
8119            ),
8120        ),
8121        crate::__combinators::Json::new,
8122    ))
8123}
8124future!(
8125    ModifyThread,
8126    futures::future::AndThen<
8127        crate::__combinators::Send<Fut, B, E>,
8128        crate::__combinators::Json<B, E, crate::__types::ThreadObject>,
8129        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ThreadObject>,
8130    >,
8131    crate::__types::ThreadObject
8132);
8133#[doc = "Delete thread"]
8134pub fn delete_thread<C, Fut, B, E>(
8135    client: C,
8136    params: &crate::__types::delete_thread::Params,
8137) -> DeleteThread<Fut, B, E>
8138where
8139    C: FnOnce(http::Request<String>) -> Fut,
8140    Fut: Future<Output = Result<http::Response<B>, E>>,
8141    B: http_body::Body,
8142{
8143    DeleteThread(futures::TryFutureExt::and_then(
8144        crate::__combinators::Send::new(
8145            client,
8146            || {
8147                let path = {
8148                    #[serde_with::serde_as]
8149                    #[derive(serde :: Serialize)]
8150                    struct Query<'a> {
8151                        #[serde(skip_serializing)]
8152                        _phantom: std::marker::PhantomData<&'a ()>,
8153                    }
8154                    let crate::__types::delete_thread::Params { thread_id } = params;
8155                    #[allow(clippy::useless_format)]
8156                    let mut path = format!("/threads/{thread_id}");
8157                    let query = serde_urlencoded::to_string(Query {
8158                        _phantom: std::marker::PhantomData,
8159                    })?;
8160                    if !query.is_empty() {
8161                        path.push('?');
8162                        path.push_str(&query);
8163                    }
8164                    path
8165                };
8166                let body = String::new();
8167                Ok(http::Request::builder()
8168                    .method(http::Method::DELETE)
8169                    .uri(path)
8170                    .header(http::header::CONTENT_LENGTH, body.len())
8171                    .body(body)?)
8172            },
8173            (
8174                http::StatusCode::from_u16(200u16).unwrap(),
8175                Some(mime::APPLICATION_JSON),
8176            ),
8177        ),
8178        crate::__combinators::Json::new,
8179    ))
8180}
8181future!(
8182    DeleteThread,
8183    futures::future::AndThen<
8184        crate::__combinators::Send<Fut, B, E>,
8185        crate::__combinators::Json<B, E, crate::__types::DeleteThreadResponse>,
8186        fn(
8187            http::Response<B>,
8188        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteThreadResponse>,
8189    >,
8190    crate::__types::DeleteThreadResponse
8191);
8192#[doc = "List messages"]
8193pub fn list_messages<C, Fut, B, E>(
8194    client: C,
8195    params: &crate::__types::list_messages::Params,
8196) -> ListMessages<Fut, B, E>
8197where
8198    C: FnOnce(http::Request<String>) -> Fut,
8199    Fut: Future<Output = Result<http::Response<B>, E>>,
8200    B: http_body::Body,
8201{
8202    ListMessages(futures::TryFutureExt::and_then(
8203        crate::__combinators::Send::new(
8204            client,
8205            || {
8206                let path = {
8207                    #[serde_with::serde_as]
8208                    #[derive(serde :: Serialize)]
8209                    struct Query<'a> {
8210                        #[serde(rename = "limit")]
8211                        #[serde(skip_serializing_if = "Option::is_none")]
8212                        limit: &'a Option<i64>,
8213                        #[serde(rename = "order")]
8214                        #[serde(skip_serializing_if = "Option::is_none")]
8215                        order: &'a Option<crate::__types::list_messages::params::Order>,
8216                        #[serde(rename = "after")]
8217                        #[serde(skip_serializing_if = "Option::is_none")]
8218                        after: &'a Option<String>,
8219                        #[serde(rename = "before")]
8220                        #[serde(skip_serializing_if = "Option::is_none")]
8221                        before: &'a Option<String>,
8222                        #[serde(rename = "run_id")]
8223                        #[serde(skip_serializing_if = "Option::is_none")]
8224                        run_id: &'a Option<String>,
8225                        #[serde(skip_serializing)]
8226                        _phantom: std::marker::PhantomData<&'a ()>,
8227                    }
8228                    let crate::__types::list_messages::Params {
8229                        thread_id,
8230                        limit,
8231                        order,
8232                        after,
8233                        before,
8234                        run_id,
8235                    } = params;
8236                    #[allow(clippy::useless_format)]
8237                    let mut path = format!("/threads/{thread_id}/messages");
8238                    let query = serde_urlencoded::to_string(Query {
8239                        limit,
8240                        order,
8241                        after,
8242                        before,
8243                        run_id,
8244                        _phantom: std::marker::PhantomData,
8245                    })?;
8246                    if !query.is_empty() {
8247                        path.push('?');
8248                        path.push_str(&query);
8249                    }
8250                    path
8251                };
8252                let body = String::new();
8253                Ok(http::Request::builder()
8254                    .method(http::Method::GET)
8255                    .uri(path)
8256                    .header(http::header::CONTENT_LENGTH, body.len())
8257                    .body(body)?)
8258            },
8259            (
8260                http::StatusCode::from_u16(200u16).unwrap(),
8261                Some(mime::APPLICATION_JSON),
8262            ),
8263        ),
8264        crate::__combinators::Json::new,
8265    ))
8266}
8267future!(
8268    ListMessages,
8269    futures::future::AndThen<
8270        crate::__combinators::Send<Fut, B, E>,
8271        crate::__combinators::Json<B, E, crate::__types::ListMessagesResponse>,
8272        fn(
8273            http::Response<B>,
8274        ) -> crate::__combinators::Json<B, E, crate::__types::ListMessagesResponse>,
8275    >,
8276    crate::__types::ListMessagesResponse
8277);
8278#[doc = "Create message"]
8279pub fn create_message<C, Fut, B, E>(
8280    client: C,
8281    params: &crate::__types::create_message::Params,
8282    request: &crate::__types::CreateMessageRequest,
8283) -> CreateMessage<Fut, B, E>
8284where
8285    C: FnOnce(http::Request<String>) -> Fut,
8286    Fut: Future<Output = Result<http::Response<B>, E>>,
8287    B: http_body::Body,
8288{
8289    CreateMessage(futures::TryFutureExt::and_then(
8290        crate::__combinators::Send::new(
8291            client,
8292            || {
8293                let path = {
8294                    #[serde_with::serde_as]
8295                    #[derive(serde :: Serialize)]
8296                    struct Query<'a> {
8297                        #[serde(skip_serializing)]
8298                        _phantom: std::marker::PhantomData<&'a ()>,
8299                    }
8300                    let crate::__types::create_message::Params { thread_id } = params;
8301                    #[allow(clippy::useless_format)]
8302                    let mut path = format!("/threads/{thread_id}/messages");
8303                    let query = serde_urlencoded::to_string(Query {
8304                        _phantom: std::marker::PhantomData,
8305                    })?;
8306                    if !query.is_empty() {
8307                        path.push('?');
8308                        path.push_str(&query);
8309                    }
8310                    path
8311                };
8312                let body = serde_json::to_string(request)?;
8313                Ok(http::Request::builder()
8314                    .method(http::Method::POST)
8315                    .uri(path)
8316                    .header(http::header::CONTENT_LENGTH, body.len())
8317                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
8318                    .body(body)?)
8319            },
8320            (
8321                http::StatusCode::from_u16(200u16).unwrap(),
8322                Some(mime::APPLICATION_JSON),
8323            ),
8324        ),
8325        crate::__combinators::Json::new,
8326    ))
8327}
8328future!(
8329    CreateMessage,
8330    futures::future::AndThen<
8331        crate::__combinators::Send<Fut, B, E>,
8332        crate::__combinators::Json<B, E, crate::__types::MessageObject>,
8333        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::MessageObject>,
8334    >,
8335    crate::__types::MessageObject
8336);
8337#[doc = "Retrieve message"]
8338pub fn get_message<C, Fut, B, E>(
8339    client: C,
8340    params: &crate::__types::get_message::Params,
8341) -> GetMessage<Fut, B, E>
8342where
8343    C: FnOnce(http::Request<String>) -> Fut,
8344    Fut: Future<Output = Result<http::Response<B>, E>>,
8345    B: http_body::Body,
8346{
8347    GetMessage(futures::TryFutureExt::and_then(
8348        crate::__combinators::Send::new(
8349            client,
8350            || {
8351                let path = {
8352                    #[serde_with::serde_as]
8353                    #[derive(serde :: Serialize)]
8354                    struct Query<'a> {
8355                        #[serde(skip_serializing)]
8356                        _phantom: std::marker::PhantomData<&'a ()>,
8357                    }
8358                    let crate::__types::get_message::Params {
8359                        thread_id,
8360                        message_id,
8361                    } = params;
8362                    #[allow(clippy::useless_format)]
8363                    let mut path = format!("/threads/{thread_id}/messages/{message_id}");
8364                    let query = serde_urlencoded::to_string(Query {
8365                        _phantom: std::marker::PhantomData,
8366                    })?;
8367                    if !query.is_empty() {
8368                        path.push('?');
8369                        path.push_str(&query);
8370                    }
8371                    path
8372                };
8373                let body = String::new();
8374                Ok(http::Request::builder()
8375                    .method(http::Method::GET)
8376                    .uri(path)
8377                    .header(http::header::CONTENT_LENGTH, body.len())
8378                    .body(body)?)
8379            },
8380            (
8381                http::StatusCode::from_u16(200u16).unwrap(),
8382                Some(mime::APPLICATION_JSON),
8383            ),
8384        ),
8385        crate::__combinators::Json::new,
8386    ))
8387}
8388future!(
8389    GetMessage,
8390    futures::future::AndThen<
8391        crate::__combinators::Send<Fut, B, E>,
8392        crate::__combinators::Json<B, E, crate::__types::MessageObject>,
8393        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::MessageObject>,
8394    >,
8395    crate::__types::MessageObject
8396);
8397#[doc = "Modify message"]
8398pub fn modify_message<C, Fut, B, E>(
8399    client: C,
8400    params: &crate::__types::modify_message::Params,
8401    request: &crate::__types::ModifyMessageRequest,
8402) -> ModifyMessage<Fut, B, E>
8403where
8404    C: FnOnce(http::Request<String>) -> Fut,
8405    Fut: Future<Output = Result<http::Response<B>, E>>,
8406    B: http_body::Body,
8407{
8408    ModifyMessage(futures::TryFutureExt::and_then(
8409        crate::__combinators::Send::new(
8410            client,
8411            || {
8412                let path = {
8413                    #[serde_with::serde_as]
8414                    #[derive(serde :: Serialize)]
8415                    struct Query<'a> {
8416                        #[serde(skip_serializing)]
8417                        _phantom: std::marker::PhantomData<&'a ()>,
8418                    }
8419                    let crate::__types::modify_message::Params {
8420                        thread_id,
8421                        message_id,
8422                    } = params;
8423                    #[allow(clippy::useless_format)]
8424                    let mut path = format!("/threads/{thread_id}/messages/{message_id}");
8425                    let query = serde_urlencoded::to_string(Query {
8426                        _phantom: std::marker::PhantomData,
8427                    })?;
8428                    if !query.is_empty() {
8429                        path.push('?');
8430                        path.push_str(&query);
8431                    }
8432                    path
8433                };
8434                let body = serde_json::to_string(request)?;
8435                Ok(http::Request::builder()
8436                    .method(http::Method::POST)
8437                    .uri(path)
8438                    .header(http::header::CONTENT_LENGTH, body.len())
8439                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
8440                    .body(body)?)
8441            },
8442            (
8443                http::StatusCode::from_u16(200u16).unwrap(),
8444                Some(mime::APPLICATION_JSON),
8445            ),
8446        ),
8447        crate::__combinators::Json::new,
8448    ))
8449}
8450future!(
8451    ModifyMessage,
8452    futures::future::AndThen<
8453        crate::__combinators::Send<Fut, B, E>,
8454        crate::__combinators::Json<B, E, crate::__types::MessageObject>,
8455        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::MessageObject>,
8456    >,
8457    crate::__types::MessageObject
8458);
8459#[doc = "Delete message"]
8460pub fn delete_message<C, Fut, B, E>(
8461    client: C,
8462    params: &crate::__types::delete_message::Params,
8463) -> DeleteMessage<Fut, B, E>
8464where
8465    C: FnOnce(http::Request<String>) -> Fut,
8466    Fut: Future<Output = Result<http::Response<B>, E>>,
8467    B: http_body::Body,
8468{
8469    DeleteMessage(futures::TryFutureExt::and_then(
8470        crate::__combinators::Send::new(
8471            client,
8472            || {
8473                let path = {
8474                    #[serde_with::serde_as]
8475                    #[derive(serde :: Serialize)]
8476                    struct Query<'a> {
8477                        #[serde(skip_serializing)]
8478                        _phantom: std::marker::PhantomData<&'a ()>,
8479                    }
8480                    let crate::__types::delete_message::Params {
8481                        thread_id,
8482                        message_id,
8483                    } = params;
8484                    #[allow(clippy::useless_format)]
8485                    let mut path = format!("/threads/{thread_id}/messages/{message_id}");
8486                    let query = serde_urlencoded::to_string(Query {
8487                        _phantom: std::marker::PhantomData,
8488                    })?;
8489                    if !query.is_empty() {
8490                        path.push('?');
8491                        path.push_str(&query);
8492                    }
8493                    path
8494                };
8495                let body = String::new();
8496                Ok(http::Request::builder()
8497                    .method(http::Method::DELETE)
8498                    .uri(path)
8499                    .header(http::header::CONTENT_LENGTH, body.len())
8500                    .body(body)?)
8501            },
8502            (
8503                http::StatusCode::from_u16(200u16).unwrap(),
8504                Some(mime::APPLICATION_JSON),
8505            ),
8506        ),
8507        crate::__combinators::Json::new,
8508    ))
8509}
8510future!(
8511    DeleteMessage,
8512    futures::future::AndThen<
8513        crate::__combinators::Send<Fut, B, E>,
8514        crate::__combinators::Json<B, E, crate::__types::DeleteMessageResponse>,
8515        fn(
8516            http::Response<B>,
8517        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteMessageResponse>,
8518    >,
8519    crate::__types::DeleteMessageResponse
8520);
8521#[doc = "List runs"]
8522pub fn list_runs<C, Fut, B, E>(
8523    client: C,
8524    params: &crate::__types::list_runs::Params,
8525) -> ListRuns<Fut, B, E>
8526where
8527    C: FnOnce(http::Request<String>) -> Fut,
8528    Fut: Future<Output = Result<http::Response<B>, E>>,
8529    B: http_body::Body,
8530{
8531    ListRuns(futures::TryFutureExt::and_then(
8532        crate::__combinators::Send::new(
8533            client,
8534            || {
8535                let path = {
8536                    #[serde_with::serde_as]
8537                    #[derive(serde :: Serialize)]
8538                    struct Query<'a> {
8539                        #[serde(rename = "limit")]
8540                        #[serde(skip_serializing_if = "Option::is_none")]
8541                        limit: &'a Option<i64>,
8542                        #[serde(rename = "order")]
8543                        #[serde(skip_serializing_if = "Option::is_none")]
8544                        order: &'a Option<crate::__types::list_runs::params::Order>,
8545                        #[serde(rename = "after")]
8546                        #[serde(skip_serializing_if = "Option::is_none")]
8547                        after: &'a Option<String>,
8548                        #[serde(rename = "before")]
8549                        #[serde(skip_serializing_if = "Option::is_none")]
8550                        before: &'a Option<String>,
8551                        #[serde(skip_serializing)]
8552                        _phantom: std::marker::PhantomData<&'a ()>,
8553                    }
8554                    let crate::__types::list_runs::Params {
8555                        thread_id,
8556                        limit,
8557                        order,
8558                        after,
8559                        before,
8560                    } = params;
8561                    #[allow(clippy::useless_format)]
8562                    let mut path = format!("/threads/{thread_id}/runs");
8563                    let query = serde_urlencoded::to_string(Query {
8564                        limit,
8565                        order,
8566                        after,
8567                        before,
8568                        _phantom: std::marker::PhantomData,
8569                    })?;
8570                    if !query.is_empty() {
8571                        path.push('?');
8572                        path.push_str(&query);
8573                    }
8574                    path
8575                };
8576                let body = String::new();
8577                Ok(http::Request::builder()
8578                    .method(http::Method::GET)
8579                    .uri(path)
8580                    .header(http::header::CONTENT_LENGTH, body.len())
8581                    .body(body)?)
8582            },
8583            (
8584                http::StatusCode::from_u16(200u16).unwrap(),
8585                Some(mime::APPLICATION_JSON),
8586            ),
8587        ),
8588        crate::__combinators::Json::new,
8589    ))
8590}
8591future!(
8592    ListRuns,
8593    futures::future::AndThen<
8594        crate::__combinators::Send<Fut, B, E>,
8595        crate::__combinators::Json<B, E, crate::__types::ListRunsResponse>,
8596        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::ListRunsResponse>,
8597    >,
8598    crate::__types::ListRunsResponse
8599);
8600#[doc = "Create run"]
8601pub fn create_run<C, Fut, B, E>(
8602    client: C,
8603    params: &crate::__types::create_run::Params,
8604    request: &crate::__types::CreateRunRequest,
8605) -> CreateRun<Fut, B, E>
8606where
8607    C: FnOnce(http::Request<String>) -> Fut,
8608    Fut: Future<Output = Result<http::Response<B>, E>>,
8609    B: http_body::Body,
8610{
8611    CreateRun(futures::TryFutureExt::and_then(
8612        crate::__combinators::Send::new(
8613            client,
8614            || {
8615                let path = {
8616                    #[serde_with::serde_as]
8617                    #[derive(serde :: Serialize)]
8618                    struct Query<'a> {
8619                        #[serde(rename = "include[]")]
8620                        #[serde(skip_serializing_if = "Option::is_none")]
8621                        include: &'a Option<Vec<crate::__types::create_run::params::include::Item>>,
8622                        #[serde(skip_serializing)]
8623                        _phantom: std::marker::PhantomData<&'a ()>,
8624                    }
8625                    let crate::__types::create_run::Params { thread_id, include } = params;
8626                    #[allow(clippy::useless_format)]
8627                    let mut path = format!("/threads/{thread_id}/runs");
8628                    let query = serde_urlencoded::to_string(Query {
8629                        include,
8630                        _phantom: std::marker::PhantomData,
8631                    })?;
8632                    if !query.is_empty() {
8633                        path.push('?');
8634                        path.push_str(&query);
8635                    }
8636                    path
8637                };
8638                let body = serde_json::to_string(request)?;
8639                Ok(http::Request::builder()
8640                    .method(http::Method::POST)
8641                    .uri(path)
8642                    .header(http::header::CONTENT_LENGTH, body.len())
8643                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
8644                    .body(body)?)
8645            },
8646            (
8647                http::StatusCode::from_u16(200u16).unwrap(),
8648                Some(mime::APPLICATION_JSON),
8649            ),
8650        ),
8651        crate::__combinators::Json::new,
8652    ))
8653}
8654future!(
8655    CreateRun,
8656    futures::future::AndThen<
8657        crate::__combinators::Send<Fut, B, E>,
8658        crate::__combinators::Json<B, E, crate::__types::RunObject>,
8659        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunObject>,
8660    >,
8661    crate::__types::RunObject
8662);
8663#[doc = "Retrieve run"]
8664pub fn get_run<C, Fut, B, E>(
8665    client: C,
8666    params: &crate::__types::get_run::Params,
8667) -> GetRun<Fut, B, E>
8668where
8669    C: FnOnce(http::Request<String>) -> Fut,
8670    Fut: Future<Output = Result<http::Response<B>, E>>,
8671    B: http_body::Body,
8672{
8673    GetRun(futures::TryFutureExt::and_then(
8674        crate::__combinators::Send::new(
8675            client,
8676            || {
8677                let path = {
8678                    #[serde_with::serde_as]
8679                    #[derive(serde :: Serialize)]
8680                    struct Query<'a> {
8681                        #[serde(skip_serializing)]
8682                        _phantom: std::marker::PhantomData<&'a ()>,
8683                    }
8684                    let crate::__types::get_run::Params { thread_id, run_id } = params;
8685                    #[allow(clippy::useless_format)]
8686                    let mut path = format!("/threads/{thread_id}/runs/{run_id}");
8687                    let query = serde_urlencoded::to_string(Query {
8688                        _phantom: std::marker::PhantomData,
8689                    })?;
8690                    if !query.is_empty() {
8691                        path.push('?');
8692                        path.push_str(&query);
8693                    }
8694                    path
8695                };
8696                let body = String::new();
8697                Ok(http::Request::builder()
8698                    .method(http::Method::GET)
8699                    .uri(path)
8700                    .header(http::header::CONTENT_LENGTH, body.len())
8701                    .body(body)?)
8702            },
8703            (
8704                http::StatusCode::from_u16(200u16).unwrap(),
8705                Some(mime::APPLICATION_JSON),
8706            ),
8707        ),
8708        crate::__combinators::Json::new,
8709    ))
8710}
8711future!(
8712    GetRun,
8713    futures::future::AndThen<
8714        crate::__combinators::Send<Fut, B, E>,
8715        crate::__combinators::Json<B, E, crate::__types::RunObject>,
8716        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunObject>,
8717    >,
8718    crate::__types::RunObject
8719);
8720#[doc = "Modify run"]
8721pub fn modify_run<C, Fut, B, E>(
8722    client: C,
8723    params: &crate::__types::modify_run::Params,
8724    request: &crate::__types::ModifyRunRequest,
8725) -> ModifyRun<Fut, B, E>
8726where
8727    C: FnOnce(http::Request<String>) -> Fut,
8728    Fut: Future<Output = Result<http::Response<B>, E>>,
8729    B: http_body::Body,
8730{
8731    ModifyRun(futures::TryFutureExt::and_then(
8732        crate::__combinators::Send::new(
8733            client,
8734            || {
8735                let path = {
8736                    #[serde_with::serde_as]
8737                    #[derive(serde :: Serialize)]
8738                    struct Query<'a> {
8739                        #[serde(skip_serializing)]
8740                        _phantom: std::marker::PhantomData<&'a ()>,
8741                    }
8742                    let crate::__types::modify_run::Params { thread_id, run_id } = params;
8743                    #[allow(clippy::useless_format)]
8744                    let mut path = format!("/threads/{thread_id}/runs/{run_id}");
8745                    let query = serde_urlencoded::to_string(Query {
8746                        _phantom: std::marker::PhantomData,
8747                    })?;
8748                    if !query.is_empty() {
8749                        path.push('?');
8750                        path.push_str(&query);
8751                    }
8752                    path
8753                };
8754                let body = serde_json::to_string(request)?;
8755                Ok(http::Request::builder()
8756                    .method(http::Method::POST)
8757                    .uri(path)
8758                    .header(http::header::CONTENT_LENGTH, body.len())
8759                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
8760                    .body(body)?)
8761            },
8762            (
8763                http::StatusCode::from_u16(200u16).unwrap(),
8764                Some(mime::APPLICATION_JSON),
8765            ),
8766        ),
8767        crate::__combinators::Json::new,
8768    ))
8769}
8770future!(
8771    ModifyRun,
8772    futures::future::AndThen<
8773        crate::__combinators::Send<Fut, B, E>,
8774        crate::__combinators::Json<B, E, crate::__types::RunObject>,
8775        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunObject>,
8776    >,
8777    crate::__types::RunObject
8778);
8779#[doc = "Cancel a run"]
8780pub fn cancel_run<C, Fut, B, E>(
8781    client: C,
8782    params: &crate::__types::cancel_run::Params,
8783) -> CancelRun<Fut, B, E>
8784where
8785    C: FnOnce(http::Request<String>) -> Fut,
8786    Fut: Future<Output = Result<http::Response<B>, E>>,
8787    B: http_body::Body,
8788{
8789    CancelRun(futures::TryFutureExt::and_then(
8790        crate::__combinators::Send::new(
8791            client,
8792            || {
8793                let path = {
8794                    #[serde_with::serde_as]
8795                    #[derive(serde :: Serialize)]
8796                    struct Query<'a> {
8797                        #[serde(skip_serializing)]
8798                        _phantom: std::marker::PhantomData<&'a ()>,
8799                    }
8800                    let crate::__types::cancel_run::Params { thread_id, run_id } = params;
8801                    #[allow(clippy::useless_format)]
8802                    let mut path = format!("/threads/{thread_id}/runs/{run_id}/cancel");
8803                    let query = serde_urlencoded::to_string(Query {
8804                        _phantom: std::marker::PhantomData,
8805                    })?;
8806                    if !query.is_empty() {
8807                        path.push('?');
8808                        path.push_str(&query);
8809                    }
8810                    path
8811                };
8812                let body = String::new();
8813                Ok(http::Request::builder()
8814                    .method(http::Method::POST)
8815                    .uri(path)
8816                    .header(http::header::CONTENT_LENGTH, body.len())
8817                    .body(body)?)
8818            },
8819            (
8820                http::StatusCode::from_u16(200u16).unwrap(),
8821                Some(mime::APPLICATION_JSON),
8822            ),
8823        ),
8824        crate::__combinators::Json::new,
8825    ))
8826}
8827future!(
8828    CancelRun,
8829    futures::future::AndThen<
8830        crate::__combinators::Send<Fut, B, E>,
8831        crate::__combinators::Json<B, E, crate::__types::RunObject>,
8832        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunObject>,
8833    >,
8834    crate::__types::RunObject
8835);
8836#[doc = "List run steps"]
8837pub fn list_run_steps<C, Fut, B, E>(
8838    client: C,
8839    params: &crate::__types::list_run_steps::Params,
8840) -> ListRunSteps<Fut, B, E>
8841where
8842    C: FnOnce(http::Request<String>) -> Fut,
8843    Fut: Future<Output = Result<http::Response<B>, E>>,
8844    B: http_body::Body,
8845{
8846    ListRunSteps(futures::TryFutureExt::and_then(
8847        crate::__combinators::Send::new(
8848            client,
8849            || {
8850                let path = {
8851                    #[serde_with::serde_as]
8852                    #[derive(serde :: Serialize)]
8853                    struct Query<'a> {
8854                        #[serde(rename = "limit")]
8855                        #[serde(skip_serializing_if = "Option::is_none")]
8856                        limit: &'a Option<i64>,
8857                        #[serde(rename = "order")]
8858                        #[serde(skip_serializing_if = "Option::is_none")]
8859                        order: &'a Option<crate::__types::list_run_steps::params::Order>,
8860                        #[serde(rename = "after")]
8861                        #[serde(skip_serializing_if = "Option::is_none")]
8862                        after: &'a Option<String>,
8863                        #[serde(rename = "before")]
8864                        #[serde(skip_serializing_if = "Option::is_none")]
8865                        before: &'a Option<String>,
8866                        #[serde(rename = "include[]")]
8867                        #[serde(skip_serializing_if = "Option::is_none")]
8868                        include:
8869                            &'a Option<Vec<crate::__types::list_run_steps::params::include::Item>>,
8870                        #[serde(skip_serializing)]
8871                        _phantom: std::marker::PhantomData<&'a ()>,
8872                    }
8873                    let crate::__types::list_run_steps::Params {
8874                        thread_id,
8875                        run_id,
8876                        limit,
8877                        order,
8878                        after,
8879                        before,
8880                        include,
8881                    } = params;
8882                    #[allow(clippy::useless_format)]
8883                    let mut path = format!("/threads/{thread_id}/runs/{run_id}/steps");
8884                    let query = serde_urlencoded::to_string(Query {
8885                        limit,
8886                        order,
8887                        after,
8888                        before,
8889                        include,
8890                        _phantom: std::marker::PhantomData,
8891                    })?;
8892                    if !query.is_empty() {
8893                        path.push('?');
8894                        path.push_str(&query);
8895                    }
8896                    path
8897                };
8898                let body = String::new();
8899                Ok(http::Request::builder()
8900                    .method(http::Method::GET)
8901                    .uri(path)
8902                    .header(http::header::CONTENT_LENGTH, body.len())
8903                    .body(body)?)
8904            },
8905            (
8906                http::StatusCode::from_u16(200u16).unwrap(),
8907                Some(mime::APPLICATION_JSON),
8908            ),
8909        ),
8910        crate::__combinators::Json::new,
8911    ))
8912}
8913future!(
8914    ListRunSteps,
8915    futures::future::AndThen<
8916        crate::__combinators::Send<Fut, B, E>,
8917        crate::__combinators::Json<B, E, crate::__types::ListRunStepsResponse>,
8918        fn(
8919            http::Response<B>,
8920        ) -> crate::__combinators::Json<B, E, crate::__types::ListRunStepsResponse>,
8921    >,
8922    crate::__types::ListRunStepsResponse
8923);
8924#[doc = "Retrieve run step"]
8925pub fn get_run_step<C, Fut, B, E>(
8926    client: C,
8927    params: &crate::__types::get_run_step::Params,
8928) -> GetRunStep<Fut, B, E>
8929where
8930    C: FnOnce(http::Request<String>) -> Fut,
8931    Fut: Future<Output = Result<http::Response<B>, E>>,
8932    B: http_body::Body,
8933{
8934    GetRunStep(futures::TryFutureExt::and_then(
8935        crate::__combinators::Send::new(
8936            client,
8937            || {
8938                let path = {
8939                    #[serde_with::serde_as]
8940                    #[derive(serde :: Serialize)]
8941                    struct Query<'a> {
8942                        #[serde(rename = "include[]")]
8943                        #[serde(skip_serializing_if = "Option::is_none")]
8944                        include:
8945                            &'a Option<Vec<crate::__types::get_run_step::params::include::Item>>,
8946                        #[serde(skip_serializing)]
8947                        _phantom: std::marker::PhantomData<&'a ()>,
8948                    }
8949                    let crate::__types::get_run_step::Params {
8950                        thread_id,
8951                        run_id,
8952                        step_id,
8953                        include,
8954                    } = params;
8955                    #[allow(clippy::useless_format)]
8956                    let mut path = format!("/threads/{thread_id}/runs/{run_id}/steps/{step_id}");
8957                    let query = serde_urlencoded::to_string(Query {
8958                        include,
8959                        _phantom: std::marker::PhantomData,
8960                    })?;
8961                    if !query.is_empty() {
8962                        path.push('?');
8963                        path.push_str(&query);
8964                    }
8965                    path
8966                };
8967                let body = String::new();
8968                Ok(http::Request::builder()
8969                    .method(http::Method::GET)
8970                    .uri(path)
8971                    .header(http::header::CONTENT_LENGTH, body.len())
8972                    .body(body)?)
8973            },
8974            (
8975                http::StatusCode::from_u16(200u16).unwrap(),
8976                Some(mime::APPLICATION_JSON),
8977            ),
8978        ),
8979        crate::__combinators::Json::new,
8980    ))
8981}
8982future!(
8983    GetRunStep,
8984    futures::future::AndThen<
8985        crate::__combinators::Send<Fut, B, E>,
8986        crate::__combinators::Json<B, E, crate::__types::RunStepObject>,
8987        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunStepObject>,
8988    >,
8989    crate::__types::RunStepObject
8990);
8991#[doc = "Submit tool outputs to run"]
8992pub fn submit_tool_ouputs_to_run<C, Fut, B, E>(
8993    client: C,
8994    params: &crate::__types::submit_tool_ouputs_to_run::Params,
8995    request: &crate::__types::SubmitToolOutputsRunRequest,
8996) -> SubmitToolOuputsToRun<Fut, B, E>
8997where
8998    C: FnOnce(http::Request<String>) -> Fut,
8999    Fut: Future<Output = Result<http::Response<B>, E>>,
9000    B: http_body::Body,
9001{
9002    SubmitToolOuputsToRun(futures::TryFutureExt::and_then(
9003        crate::__combinators::Send::new(
9004            client,
9005            || {
9006                let path = {
9007                    #[serde_with::serde_as]
9008                    #[derive(serde :: Serialize)]
9009                    struct Query<'a> {
9010                        #[serde(skip_serializing)]
9011                        _phantom: std::marker::PhantomData<&'a ()>,
9012                    }
9013                    let crate::__types::submit_tool_ouputs_to_run::Params { thread_id, run_id } =
9014                        params;
9015                    #[allow(clippy::useless_format)]
9016                    let mut path =
9017                        format!("/threads/{thread_id}/runs/{run_id}/submit_tool_outputs");
9018                    let query = serde_urlencoded::to_string(Query {
9019                        _phantom: std::marker::PhantomData,
9020                    })?;
9021                    if !query.is_empty() {
9022                        path.push('?');
9023                        path.push_str(&query);
9024                    }
9025                    path
9026                };
9027                let body = serde_json::to_string(request)?;
9028                Ok(http::Request::builder()
9029                    .method(http::Method::POST)
9030                    .uri(path)
9031                    .header(http::header::CONTENT_LENGTH, body.len())
9032                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9033                    .body(body)?)
9034            },
9035            (
9036                http::StatusCode::from_u16(200u16).unwrap(),
9037                Some(mime::APPLICATION_JSON),
9038            ),
9039        ),
9040        crate::__combinators::Json::new,
9041    ))
9042}
9043future!(
9044    SubmitToolOuputsToRun,
9045    futures::future::AndThen<
9046        crate::__combinators::Send<Fut, B, E>,
9047        crate::__combinators::Json<B, E, crate::__types::RunObject>,
9048        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::RunObject>,
9049    >,
9050    crate::__types::RunObject
9051);
9052#[doc = "Create upload"]
9053pub fn create_upload<C, Fut, B, E>(
9054    client: C,
9055    request: &crate::__types::CreateUploadRequest,
9056) -> CreateUpload<Fut, B, E>
9057where
9058    C: FnOnce(http::Request<String>) -> Fut,
9059    Fut: Future<Output = Result<http::Response<B>, E>>,
9060    B: http_body::Body,
9061{
9062    CreateUpload(futures::TryFutureExt::and_then(
9063        crate::__combinators::Send::new(
9064            client,
9065            || {
9066                let path = "/uploads";
9067                let body = serde_json::to_string(request)?;
9068                Ok(http::Request::builder()
9069                    .method(http::Method::POST)
9070                    .uri(path)
9071                    .header(http::header::CONTENT_LENGTH, body.len())
9072                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9073                    .body(body)?)
9074            },
9075            (
9076                http::StatusCode::from_u16(200u16).unwrap(),
9077                Some(mime::APPLICATION_JSON),
9078            ),
9079        ),
9080        crate::__combinators::Json::new,
9081    ))
9082}
9083future!(
9084    CreateUpload,
9085    futures::future::AndThen<
9086        crate::__combinators::Send<Fut, B, E>,
9087        crate::__combinators::Json<B, E, crate::__types::Upload>,
9088        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Upload>,
9089    >,
9090    crate::__types::Upload
9091);
9092#[doc = "Cancel upload"]
9093pub fn cancel_upload<C, Fut, B, E>(
9094    client: C,
9095    params: &crate::__types::cancel_upload::Params,
9096) -> CancelUpload<Fut, B, E>
9097where
9098    C: FnOnce(http::Request<String>) -> Fut,
9099    Fut: Future<Output = Result<http::Response<B>, E>>,
9100    B: http_body::Body,
9101{
9102    CancelUpload(futures::TryFutureExt::and_then(
9103        crate::__combinators::Send::new(
9104            client,
9105            || {
9106                let path = {
9107                    #[serde_with::serde_as]
9108                    #[derive(serde :: Serialize)]
9109                    struct Query<'a> {
9110                        #[serde(skip_serializing)]
9111                        _phantom: std::marker::PhantomData<&'a ()>,
9112                    }
9113                    let crate::__types::cancel_upload::Params { upload_id } = params;
9114                    #[allow(clippy::useless_format)]
9115                    let mut path = format!("/uploads/{upload_id}/cancel");
9116                    let query = serde_urlencoded::to_string(Query {
9117                        _phantom: std::marker::PhantomData,
9118                    })?;
9119                    if !query.is_empty() {
9120                        path.push('?');
9121                        path.push_str(&query);
9122                    }
9123                    path
9124                };
9125                let body = String::new();
9126                Ok(http::Request::builder()
9127                    .method(http::Method::POST)
9128                    .uri(path)
9129                    .header(http::header::CONTENT_LENGTH, body.len())
9130                    .body(body)?)
9131            },
9132            (
9133                http::StatusCode::from_u16(200u16).unwrap(),
9134                Some(mime::APPLICATION_JSON),
9135            ),
9136        ),
9137        crate::__combinators::Json::new,
9138    ))
9139}
9140future!(
9141    CancelUpload,
9142    futures::future::AndThen<
9143        crate::__combinators::Send<Fut, B, E>,
9144        crate::__combinators::Json<B, E, crate::__types::Upload>,
9145        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Upload>,
9146    >,
9147    crate::__types::Upload
9148);
9149#[doc = "Complete upload"]
9150pub fn complete_upload<C, Fut, B, E>(
9151    client: C,
9152    params: &crate::__types::complete_upload::Params,
9153    request: &crate::__types::CompleteUploadRequest,
9154) -> CompleteUpload<Fut, B, E>
9155where
9156    C: FnOnce(http::Request<String>) -> Fut,
9157    Fut: Future<Output = Result<http::Response<B>, E>>,
9158    B: http_body::Body,
9159{
9160    CompleteUpload(futures::TryFutureExt::and_then(
9161        crate::__combinators::Send::new(
9162            client,
9163            || {
9164                let path = {
9165                    #[serde_with::serde_as]
9166                    #[derive(serde :: Serialize)]
9167                    struct Query<'a> {
9168                        #[serde(skip_serializing)]
9169                        _phantom: std::marker::PhantomData<&'a ()>,
9170                    }
9171                    let crate::__types::complete_upload::Params { upload_id } = params;
9172                    #[allow(clippy::useless_format)]
9173                    let mut path = format!("/uploads/{upload_id}/complete");
9174                    let query = serde_urlencoded::to_string(Query {
9175                        _phantom: std::marker::PhantomData,
9176                    })?;
9177                    if !query.is_empty() {
9178                        path.push('?');
9179                        path.push_str(&query);
9180                    }
9181                    path
9182                };
9183                let body = serde_json::to_string(request)?;
9184                Ok(http::Request::builder()
9185                    .method(http::Method::POST)
9186                    .uri(path)
9187                    .header(http::header::CONTENT_LENGTH, body.len())
9188                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9189                    .body(body)?)
9190            },
9191            (
9192                http::StatusCode::from_u16(200u16).unwrap(),
9193                Some(mime::APPLICATION_JSON),
9194            ),
9195        ),
9196        crate::__combinators::Json::new,
9197    ))
9198}
9199future!(
9200    CompleteUpload,
9201    futures::future::AndThen<
9202        crate::__combinators::Send<Fut, B, E>,
9203        crate::__combinators::Json<B, E, crate::__types::Upload>,
9204        fn(http::Response<B>) -> crate::__combinators::Json<B, E, crate::__types::Upload>,
9205    >,
9206    crate::__types::Upload
9207);
9208#[doc = "List vector stores"]
9209pub fn list_vector_stores<C, Fut, B, E>(
9210    client: C,
9211    params: &crate::__types::list_vector_stores::Params,
9212) -> ListVectorStores<Fut, B, E>
9213where
9214    C: FnOnce(http::Request<String>) -> Fut,
9215    Fut: Future<Output = Result<http::Response<B>, E>>,
9216    B: http_body::Body,
9217{
9218    ListVectorStores(futures::TryFutureExt::and_then(
9219        crate::__combinators::Send::new(
9220            client,
9221            || {
9222                let path = {
9223                    #[serde_with::serde_as]
9224                    #[derive(serde :: Serialize)]
9225                    struct Query<'a> {
9226                        #[serde(rename = "limit")]
9227                        #[serde(skip_serializing_if = "Option::is_none")]
9228                        limit: &'a Option<i64>,
9229                        #[serde(rename = "order")]
9230                        #[serde(skip_serializing_if = "Option::is_none")]
9231                        order: &'a Option<crate::__types::list_vector_stores::params::Order>,
9232                        #[serde(rename = "after")]
9233                        #[serde(skip_serializing_if = "Option::is_none")]
9234                        after: &'a Option<String>,
9235                        #[serde(rename = "before")]
9236                        #[serde(skip_serializing_if = "Option::is_none")]
9237                        before: &'a Option<String>,
9238                        #[serde(skip_serializing)]
9239                        _phantom: std::marker::PhantomData<&'a ()>,
9240                    }
9241                    let crate::__types::list_vector_stores::Params {
9242                        limit,
9243                        order,
9244                        after,
9245                        before,
9246                    } = params;
9247                    #[allow(clippy::useless_format)]
9248                    let mut path = format!("/vector_stores");
9249                    let query = serde_urlencoded::to_string(Query {
9250                        limit,
9251                        order,
9252                        after,
9253                        before,
9254                        _phantom: std::marker::PhantomData,
9255                    })?;
9256                    if !query.is_empty() {
9257                        path.push('?');
9258                        path.push_str(&query);
9259                    }
9260                    path
9261                };
9262                let body = String::new();
9263                Ok(http::Request::builder()
9264                    .method(http::Method::GET)
9265                    .uri(path)
9266                    .header(http::header::CONTENT_LENGTH, body.len())
9267                    .body(body)?)
9268            },
9269            (
9270                http::StatusCode::from_u16(200u16).unwrap(),
9271                Some(mime::APPLICATION_JSON),
9272            ),
9273        ),
9274        crate::__combinators::Json::new,
9275    ))
9276}
9277future!(
9278    ListVectorStores,
9279    futures::future::AndThen<
9280        crate::__combinators::Send<Fut, B, E>,
9281        crate::__combinators::Json<B, E, crate::__types::ListVectorStoresResponse>,
9282        fn(
9283            http::Response<B>,
9284        ) -> crate::__combinators::Json<B, E, crate::__types::ListVectorStoresResponse>,
9285    >,
9286    crate::__types::ListVectorStoresResponse
9287);
9288#[doc = "Create vector store"]
9289pub fn create_vector_store<C, Fut, B, E>(
9290    client: C,
9291    request: &crate::__types::CreateVectorStoreRequest,
9292) -> CreateVectorStore<Fut, B, E>
9293where
9294    C: FnOnce(http::Request<String>) -> Fut,
9295    Fut: Future<Output = Result<http::Response<B>, E>>,
9296    B: http_body::Body,
9297{
9298    CreateVectorStore(futures::TryFutureExt::and_then(
9299        crate::__combinators::Send::new(
9300            client,
9301            || {
9302                let path = "/vector_stores";
9303                let body = serde_json::to_string(request)?;
9304                Ok(http::Request::builder()
9305                    .method(http::Method::POST)
9306                    .uri(path)
9307                    .header(http::header::CONTENT_LENGTH, body.len())
9308                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9309                    .body(body)?)
9310            },
9311            (
9312                http::StatusCode::from_u16(200u16).unwrap(),
9313                Some(mime::APPLICATION_JSON),
9314            ),
9315        ),
9316        crate::__combinators::Json::new,
9317    ))
9318}
9319future!(
9320    CreateVectorStore,
9321    futures::future::AndThen<
9322        crate::__combinators::Send<Fut, B, E>,
9323        crate::__combinators::Json<B, E, crate::__types::VectorStoreObject>,
9324        fn(
9325            http::Response<B>,
9326        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreObject>,
9327    >,
9328    crate::__types::VectorStoreObject
9329);
9330#[doc = "Retrieve vector store"]
9331pub fn get_vector_store<C, Fut, B, E>(
9332    client: C,
9333    params: &crate::__types::get_vector_store::Params,
9334) -> GetVectorStore<Fut, B, E>
9335where
9336    C: FnOnce(http::Request<String>) -> Fut,
9337    Fut: Future<Output = Result<http::Response<B>, E>>,
9338    B: http_body::Body,
9339{
9340    GetVectorStore(futures::TryFutureExt::and_then(
9341        crate::__combinators::Send::new(
9342            client,
9343            || {
9344                let path = {
9345                    #[serde_with::serde_as]
9346                    #[derive(serde :: Serialize)]
9347                    struct Query<'a> {
9348                        #[serde(skip_serializing)]
9349                        _phantom: std::marker::PhantomData<&'a ()>,
9350                    }
9351                    let crate::__types::get_vector_store::Params { vector_store_id } = params;
9352                    #[allow(clippy::useless_format)]
9353                    let mut path = format!("/vector_stores/{vector_store_id}");
9354                    let query = serde_urlencoded::to_string(Query {
9355                        _phantom: std::marker::PhantomData,
9356                    })?;
9357                    if !query.is_empty() {
9358                        path.push('?');
9359                        path.push_str(&query);
9360                    }
9361                    path
9362                };
9363                let body = String::new();
9364                Ok(http::Request::builder()
9365                    .method(http::Method::GET)
9366                    .uri(path)
9367                    .header(http::header::CONTENT_LENGTH, body.len())
9368                    .body(body)?)
9369            },
9370            (
9371                http::StatusCode::from_u16(200u16).unwrap(),
9372                Some(mime::APPLICATION_JSON),
9373            ),
9374        ),
9375        crate::__combinators::Json::new,
9376    ))
9377}
9378future!(
9379    GetVectorStore,
9380    futures::future::AndThen<
9381        crate::__combinators::Send<Fut, B, E>,
9382        crate::__combinators::Json<B, E, crate::__types::VectorStoreObject>,
9383        fn(
9384            http::Response<B>,
9385        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreObject>,
9386    >,
9387    crate::__types::VectorStoreObject
9388);
9389#[doc = "Modify vector store"]
9390pub fn modify_vector_store<C, Fut, B, E>(
9391    client: C,
9392    params: &crate::__types::modify_vector_store::Params,
9393    request: &crate::__types::UpdateVectorStoreRequest,
9394) -> ModifyVectorStore<Fut, B, E>
9395where
9396    C: FnOnce(http::Request<String>) -> Fut,
9397    Fut: Future<Output = Result<http::Response<B>, E>>,
9398    B: http_body::Body,
9399{
9400    ModifyVectorStore(futures::TryFutureExt::and_then(
9401        crate::__combinators::Send::new(
9402            client,
9403            || {
9404                let path = {
9405                    #[serde_with::serde_as]
9406                    #[derive(serde :: Serialize)]
9407                    struct Query<'a> {
9408                        #[serde(skip_serializing)]
9409                        _phantom: std::marker::PhantomData<&'a ()>,
9410                    }
9411                    let crate::__types::modify_vector_store::Params { vector_store_id } = params;
9412                    #[allow(clippy::useless_format)]
9413                    let mut path = format!("/vector_stores/{vector_store_id}");
9414                    let query = serde_urlencoded::to_string(Query {
9415                        _phantom: std::marker::PhantomData,
9416                    })?;
9417                    if !query.is_empty() {
9418                        path.push('?');
9419                        path.push_str(&query);
9420                    }
9421                    path
9422                };
9423                let body = serde_json::to_string(request)?;
9424                Ok(http::Request::builder()
9425                    .method(http::Method::POST)
9426                    .uri(path)
9427                    .header(http::header::CONTENT_LENGTH, body.len())
9428                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9429                    .body(body)?)
9430            },
9431            (
9432                http::StatusCode::from_u16(200u16).unwrap(),
9433                Some(mime::APPLICATION_JSON),
9434            ),
9435        ),
9436        crate::__combinators::Json::new,
9437    ))
9438}
9439future!(
9440    ModifyVectorStore,
9441    futures::future::AndThen<
9442        crate::__combinators::Send<Fut, B, E>,
9443        crate::__combinators::Json<B, E, crate::__types::VectorStoreObject>,
9444        fn(
9445            http::Response<B>,
9446        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreObject>,
9447    >,
9448    crate::__types::VectorStoreObject
9449);
9450#[doc = "Delete vector store"]
9451pub fn delete_vector_store<C, Fut, B, E>(
9452    client: C,
9453    params: &crate::__types::delete_vector_store::Params,
9454) -> DeleteVectorStore<Fut, B, E>
9455where
9456    C: FnOnce(http::Request<String>) -> Fut,
9457    Fut: Future<Output = Result<http::Response<B>, E>>,
9458    B: http_body::Body,
9459{
9460    DeleteVectorStore(futures::TryFutureExt::and_then(
9461        crate::__combinators::Send::new(
9462            client,
9463            || {
9464                let path = {
9465                    #[serde_with::serde_as]
9466                    #[derive(serde :: Serialize)]
9467                    struct Query<'a> {
9468                        #[serde(skip_serializing)]
9469                        _phantom: std::marker::PhantomData<&'a ()>,
9470                    }
9471                    let crate::__types::delete_vector_store::Params { vector_store_id } = params;
9472                    #[allow(clippy::useless_format)]
9473                    let mut path = format!("/vector_stores/{vector_store_id}");
9474                    let query = serde_urlencoded::to_string(Query {
9475                        _phantom: std::marker::PhantomData,
9476                    })?;
9477                    if !query.is_empty() {
9478                        path.push('?');
9479                        path.push_str(&query);
9480                    }
9481                    path
9482                };
9483                let body = String::new();
9484                Ok(http::Request::builder()
9485                    .method(http::Method::DELETE)
9486                    .uri(path)
9487                    .header(http::header::CONTENT_LENGTH, body.len())
9488                    .body(body)?)
9489            },
9490            (
9491                http::StatusCode::from_u16(200u16).unwrap(),
9492                Some(mime::APPLICATION_JSON),
9493            ),
9494        ),
9495        crate::__combinators::Json::new,
9496    ))
9497}
9498future!(
9499    DeleteVectorStore,
9500    futures::future::AndThen<
9501        crate::__combinators::Send<Fut, B, E>,
9502        crate::__combinators::Json<B, E, crate::__types::DeleteVectorStoreResponse>,
9503        fn(
9504            http::Response<B>,
9505        ) -> crate::__combinators::Json<B, E, crate::__types::DeleteVectorStoreResponse>,
9506    >,
9507    crate::__types::DeleteVectorStoreResponse
9508);
9509#[doc = "Create vector store file batch"]
9510pub fn create_vector_store_file_batch<C, Fut, B, E>(
9511    client: C,
9512    params: &crate::__types::create_vector_store_file_batch::Params,
9513    request: &crate::__types::CreateVectorStoreFileBatchRequest,
9514) -> CreateVectorStoreFileBatch<Fut, B, E>
9515where
9516    C: FnOnce(http::Request<String>) -> Fut,
9517    Fut: Future<Output = Result<http::Response<B>, E>>,
9518    B: http_body::Body,
9519{
9520    CreateVectorStoreFileBatch(futures::TryFutureExt::and_then(
9521        crate::__combinators::Send::new(
9522            client,
9523            || {
9524                let path = {
9525                    #[serde_with::serde_as]
9526                    #[derive(serde :: Serialize)]
9527                    struct Query<'a> {
9528                        #[serde(skip_serializing)]
9529                        _phantom: std::marker::PhantomData<&'a ()>,
9530                    }
9531                    let crate::__types::create_vector_store_file_batch::Params { vector_store_id } =
9532                        params;
9533                    #[allow(clippy::useless_format)]
9534                    let mut path = format!("/vector_stores/{vector_store_id}/file_batches");
9535                    let query = serde_urlencoded::to_string(Query {
9536                        _phantom: std::marker::PhantomData,
9537                    })?;
9538                    if !query.is_empty() {
9539                        path.push('?');
9540                        path.push_str(&query);
9541                    }
9542                    path
9543                };
9544                let body = serde_json::to_string(request)?;
9545                Ok(http::Request::builder()
9546                    .method(http::Method::POST)
9547                    .uri(path)
9548                    .header(http::header::CONTENT_LENGTH, body.len())
9549                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9550                    .body(body)?)
9551            },
9552            (
9553                http::StatusCode::from_u16(200u16).unwrap(),
9554                Some(mime::APPLICATION_JSON),
9555            ),
9556        ),
9557        crate::__combinators::Json::new,
9558    ))
9559}
9560future!(
9561    CreateVectorStoreFileBatch,
9562    futures::future::AndThen<
9563        crate::__combinators::Send<Fut, B, E>,
9564        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileBatchObject>,
9565        fn(
9566            http::Response<B>,
9567        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileBatchObject>,
9568    >,
9569    crate::__types::VectorStoreFileBatchObject
9570);
9571#[doc = "Retrieve vector store file batch"]
9572pub fn get_vector_store_file_batch<C, Fut, B, E>(
9573    client: C,
9574    params: &crate::__types::get_vector_store_file_batch::Params,
9575) -> GetVectorStoreFileBatch<Fut, B, E>
9576where
9577    C: FnOnce(http::Request<String>) -> Fut,
9578    Fut: Future<Output = Result<http::Response<B>, E>>,
9579    B: http_body::Body,
9580{
9581    GetVectorStoreFileBatch(futures::TryFutureExt::and_then(
9582        crate::__combinators::Send::new(
9583            client,
9584            || {
9585                let path = {
9586                    #[serde_with::serde_as]
9587                    #[derive(serde :: Serialize)]
9588                    struct Query<'a> {
9589                        #[serde(skip_serializing)]
9590                        _phantom: std::marker::PhantomData<&'a ()>,
9591                    }
9592                    let crate::__types::get_vector_store_file_batch::Params {
9593                        vector_store_id,
9594                        batch_id,
9595                    } = params;
9596                    #[allow(clippy::useless_format)]
9597                    let mut path =
9598                        format!("/vector_stores/{vector_store_id}/file_batches/{batch_id}");
9599                    let query = serde_urlencoded::to_string(Query {
9600                        _phantom: std::marker::PhantomData,
9601                    })?;
9602                    if !query.is_empty() {
9603                        path.push('?');
9604                        path.push_str(&query);
9605                    }
9606                    path
9607                };
9608                let body = String::new();
9609                Ok(http::Request::builder()
9610                    .method(http::Method::GET)
9611                    .uri(path)
9612                    .header(http::header::CONTENT_LENGTH, body.len())
9613                    .body(body)?)
9614            },
9615            (
9616                http::StatusCode::from_u16(200u16).unwrap(),
9617                Some(mime::APPLICATION_JSON),
9618            ),
9619        ),
9620        crate::__combinators::Json::new,
9621    ))
9622}
9623future!(
9624    GetVectorStoreFileBatch,
9625    futures::future::AndThen<
9626        crate::__combinators::Send<Fut, B, E>,
9627        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileBatchObject>,
9628        fn(
9629            http::Response<B>,
9630        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileBatchObject>,
9631    >,
9632    crate::__types::VectorStoreFileBatchObject
9633);
9634#[doc = "Cancel vector store file batch"]
9635pub fn cancel_vector_store_file_batch<C, Fut, B, E>(
9636    client: C,
9637    params: &crate::__types::cancel_vector_store_file_batch::Params,
9638) -> CancelVectorStoreFileBatch<Fut, B, E>
9639where
9640    C: FnOnce(http::Request<String>) -> Fut,
9641    Fut: Future<Output = Result<http::Response<B>, E>>,
9642    B: http_body::Body,
9643{
9644    CancelVectorStoreFileBatch(futures::TryFutureExt::and_then(
9645        crate::__combinators::Send::new(
9646            client,
9647            || {
9648                let path = {
9649                    #[serde_with::serde_as]
9650                    #[derive(serde :: Serialize)]
9651                    struct Query<'a> {
9652                        #[serde(skip_serializing)]
9653                        _phantom: std::marker::PhantomData<&'a ()>,
9654                    }
9655                    let crate::__types::cancel_vector_store_file_batch::Params {
9656                        vector_store_id,
9657                        batch_id,
9658                    } = params;
9659                    #[allow(clippy::useless_format)]
9660                    let mut path =
9661                        format!("/vector_stores/{vector_store_id}/file_batches/{batch_id}/cancel");
9662                    let query = serde_urlencoded::to_string(Query {
9663                        _phantom: std::marker::PhantomData,
9664                    })?;
9665                    if !query.is_empty() {
9666                        path.push('?');
9667                        path.push_str(&query);
9668                    }
9669                    path
9670                };
9671                let body = String::new();
9672                Ok(http::Request::builder()
9673                    .method(http::Method::POST)
9674                    .uri(path)
9675                    .header(http::header::CONTENT_LENGTH, body.len())
9676                    .body(body)?)
9677            },
9678            (
9679                http::StatusCode::from_u16(200u16).unwrap(),
9680                Some(mime::APPLICATION_JSON),
9681            ),
9682        ),
9683        crate::__combinators::Json::new,
9684    ))
9685}
9686future!(
9687    CancelVectorStoreFileBatch,
9688    futures::future::AndThen<
9689        crate::__combinators::Send<Fut, B, E>,
9690        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileBatchObject>,
9691        fn(
9692            http::Response<B>,
9693        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileBatchObject>,
9694    >,
9695    crate::__types::VectorStoreFileBatchObject
9696);
9697#[doc = "List vector store files in a batch"]
9698pub fn list_files_in_vector_store_batch<C, Fut, B, E>(
9699    client: C,
9700    params: &crate::__types::list_files_in_vector_store_batch::Params,
9701) -> ListFilesInVectorStoreBatch<Fut, B, E>
9702where
9703    C: FnOnce(http::Request<String>) -> Fut,
9704    Fut: Future<Output = Result<http::Response<B>, E>>,
9705    B: http_body::Body,
9706{
9707    ListFilesInVectorStoreBatch(futures::TryFutureExt::and_then(
9708        crate::__combinators::Send::new(
9709            client,
9710            || {
9711                let path = {
9712                    #[serde_with::serde_as]
9713                    #[derive(serde :: Serialize)]
9714                    struct Query<'a> {
9715                        #[serde(rename = "limit")]
9716                        #[serde(skip_serializing_if = "Option::is_none")]
9717                        limit: &'a Option<i64>,
9718                        #[serde(rename = "order")]
9719                        #[serde(skip_serializing_if = "Option::is_none")]
9720                        order: &'a Option<
9721                            crate::__types::list_files_in_vector_store_batch::params::Order,
9722                        >,
9723                        #[serde(rename = "after")]
9724                        #[serde(skip_serializing_if = "Option::is_none")]
9725                        after: &'a Option<String>,
9726                        #[serde(rename = "before")]
9727                        #[serde(skip_serializing_if = "Option::is_none")]
9728                        before: &'a Option<String>,
9729                        #[serde(rename = "filter")]
9730                        #[serde(skip_serializing_if = "Option::is_none")]
9731                        filter: &'a Option<
9732                            crate::__types::list_files_in_vector_store_batch::params::Filter,
9733                        >,
9734                        #[serde(skip_serializing)]
9735                        _phantom: std::marker::PhantomData<&'a ()>,
9736                    }
9737                    let crate::__types::list_files_in_vector_store_batch::Params {
9738                        vector_store_id,
9739                        batch_id,
9740                        limit,
9741                        order,
9742                        after,
9743                        before,
9744                        filter,
9745                    } = params;
9746                    #[allow(clippy::useless_format)]
9747                    let mut path =
9748                        format!("/vector_stores/{vector_store_id}/file_batches/{batch_id}/files");
9749                    let query = serde_urlencoded::to_string(Query {
9750                        limit,
9751                        order,
9752                        after,
9753                        before,
9754                        filter,
9755                        _phantom: std::marker::PhantomData,
9756                    })?;
9757                    if !query.is_empty() {
9758                        path.push('?');
9759                        path.push_str(&query);
9760                    }
9761                    path
9762                };
9763                let body = String::new();
9764                Ok(http::Request::builder()
9765                    .method(http::Method::GET)
9766                    .uri(path)
9767                    .header(http::header::CONTENT_LENGTH, body.len())
9768                    .body(body)?)
9769            },
9770            (
9771                http::StatusCode::from_u16(200u16).unwrap(),
9772                Some(mime::APPLICATION_JSON),
9773            ),
9774        ),
9775        crate::__combinators::Json::new,
9776    ))
9777}
9778future!(
9779    ListFilesInVectorStoreBatch,
9780    futures::future::AndThen<
9781        crate::__combinators::Send<Fut, B, E>,
9782        crate::__combinators::Json<B, E, crate::__types::ListVectorStoreFilesResponse>,
9783        fn(
9784            http::Response<B>,
9785        )
9786            -> crate::__combinators::Json<B, E, crate::__types::ListVectorStoreFilesResponse>,
9787    >,
9788    crate::__types::ListVectorStoreFilesResponse
9789);
9790#[doc = "List vector store files"]
9791pub fn list_vector_store_files<C, Fut, B, E>(
9792    client: C,
9793    params: &crate::__types::list_vector_store_files::Params,
9794) -> ListVectorStoreFiles<Fut, B, E>
9795where
9796    C: FnOnce(http::Request<String>) -> Fut,
9797    Fut: Future<Output = Result<http::Response<B>, E>>,
9798    B: http_body::Body,
9799{
9800    ListVectorStoreFiles(futures::TryFutureExt::and_then(
9801        crate::__combinators::Send::new(
9802            client,
9803            || {
9804                let path = {
9805                    #[serde_with::serde_as]
9806                    #[derive(serde :: Serialize)]
9807                    struct Query<'a> {
9808                        #[serde(rename = "limit")]
9809                        #[serde(skip_serializing_if = "Option::is_none")]
9810                        limit: &'a Option<i64>,
9811                        #[serde(rename = "order")]
9812                        #[serde(skip_serializing_if = "Option::is_none")]
9813                        order: &'a Option<crate::__types::list_vector_store_files::params::Order>,
9814                        #[serde(rename = "after")]
9815                        #[serde(skip_serializing_if = "Option::is_none")]
9816                        after: &'a Option<String>,
9817                        #[serde(rename = "before")]
9818                        #[serde(skip_serializing_if = "Option::is_none")]
9819                        before: &'a Option<String>,
9820                        #[serde(rename = "filter")]
9821                        #[serde(skip_serializing_if = "Option::is_none")]
9822                        filter: &'a Option<crate::__types::list_vector_store_files::params::Filter>,
9823                        #[serde(skip_serializing)]
9824                        _phantom: std::marker::PhantomData<&'a ()>,
9825                    }
9826                    let crate::__types::list_vector_store_files::Params {
9827                        vector_store_id,
9828                        limit,
9829                        order,
9830                        after,
9831                        before,
9832                        filter,
9833                    } = params;
9834                    #[allow(clippy::useless_format)]
9835                    let mut path = format!("/vector_stores/{vector_store_id}/files");
9836                    let query = serde_urlencoded::to_string(Query {
9837                        limit,
9838                        order,
9839                        after,
9840                        before,
9841                        filter,
9842                        _phantom: std::marker::PhantomData,
9843                    })?;
9844                    if !query.is_empty() {
9845                        path.push('?');
9846                        path.push_str(&query);
9847                    }
9848                    path
9849                };
9850                let body = String::new();
9851                Ok(http::Request::builder()
9852                    .method(http::Method::GET)
9853                    .uri(path)
9854                    .header(http::header::CONTENT_LENGTH, body.len())
9855                    .body(body)?)
9856            },
9857            (
9858                http::StatusCode::from_u16(200u16).unwrap(),
9859                Some(mime::APPLICATION_JSON),
9860            ),
9861        ),
9862        crate::__combinators::Json::new,
9863    ))
9864}
9865future!(
9866    ListVectorStoreFiles,
9867    futures::future::AndThen<
9868        crate::__combinators::Send<Fut, B, E>,
9869        crate::__combinators::Json<B, E, crate::__types::ListVectorStoreFilesResponse>,
9870        fn(
9871            http::Response<B>,
9872        )
9873            -> crate::__combinators::Json<B, E, crate::__types::ListVectorStoreFilesResponse>,
9874    >,
9875    crate::__types::ListVectorStoreFilesResponse
9876);
9877#[doc = "Create vector store file"]
9878pub fn create_vector_store_file<C, Fut, B, E>(
9879    client: C,
9880    params: &crate::__types::create_vector_store_file::Params,
9881    request: &crate::__types::CreateVectorStoreFileRequest,
9882) -> CreateVectorStoreFile<Fut, B, E>
9883where
9884    C: FnOnce(http::Request<String>) -> Fut,
9885    Fut: Future<Output = Result<http::Response<B>, E>>,
9886    B: http_body::Body,
9887{
9888    CreateVectorStoreFile(futures::TryFutureExt::and_then(
9889        crate::__combinators::Send::new(
9890            client,
9891            || {
9892                let path = {
9893                    #[serde_with::serde_as]
9894                    #[derive(serde :: Serialize)]
9895                    struct Query<'a> {
9896                        #[serde(skip_serializing)]
9897                        _phantom: std::marker::PhantomData<&'a ()>,
9898                    }
9899                    let crate::__types::create_vector_store_file::Params { vector_store_id } =
9900                        params;
9901                    #[allow(clippy::useless_format)]
9902                    let mut path = format!("/vector_stores/{vector_store_id}/files");
9903                    let query = serde_urlencoded::to_string(Query {
9904                        _phantom: std::marker::PhantomData,
9905                    })?;
9906                    if !query.is_empty() {
9907                        path.push('?');
9908                        path.push_str(&query);
9909                    }
9910                    path
9911                };
9912                let body = serde_json::to_string(request)?;
9913                Ok(http::Request::builder()
9914                    .method(http::Method::POST)
9915                    .uri(path)
9916                    .header(http::header::CONTENT_LENGTH, body.len())
9917                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
9918                    .body(body)?)
9919            },
9920            (
9921                http::StatusCode::from_u16(200u16).unwrap(),
9922                Some(mime::APPLICATION_JSON),
9923            ),
9924        ),
9925        crate::__combinators::Json::new,
9926    ))
9927}
9928future!(
9929    CreateVectorStoreFile,
9930    futures::future::AndThen<
9931        crate::__combinators::Send<Fut, B, E>,
9932        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileObject>,
9933        fn(
9934            http::Response<B>,
9935        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileObject>,
9936    >,
9937    crate::__types::VectorStoreFileObject
9938);
9939#[doc = "Retrieve vector store file"]
9940pub fn get_vector_store_file<C, Fut, B, E>(
9941    client: C,
9942    params: &crate::__types::get_vector_store_file::Params,
9943) -> GetVectorStoreFile<Fut, B, E>
9944where
9945    C: FnOnce(http::Request<String>) -> Fut,
9946    Fut: Future<Output = Result<http::Response<B>, E>>,
9947    B: http_body::Body,
9948{
9949    GetVectorStoreFile(futures::TryFutureExt::and_then(
9950        crate::__combinators::Send::new(
9951            client,
9952            || {
9953                let path = {
9954                    #[serde_with::serde_as]
9955                    #[derive(serde :: Serialize)]
9956                    struct Query<'a> {
9957                        #[serde(skip_serializing)]
9958                        _phantom: std::marker::PhantomData<&'a ()>,
9959                    }
9960                    let crate::__types::get_vector_store_file::Params {
9961                        vector_store_id,
9962                        file_id,
9963                    } = params;
9964                    #[allow(clippy::useless_format)]
9965                    let mut path = format!("/vector_stores/{vector_store_id}/files/{file_id}");
9966                    let query = serde_urlencoded::to_string(Query {
9967                        _phantom: std::marker::PhantomData,
9968                    })?;
9969                    if !query.is_empty() {
9970                        path.push('?');
9971                        path.push_str(&query);
9972                    }
9973                    path
9974                };
9975                let body = String::new();
9976                Ok(http::Request::builder()
9977                    .method(http::Method::GET)
9978                    .uri(path)
9979                    .header(http::header::CONTENT_LENGTH, body.len())
9980                    .body(body)?)
9981            },
9982            (
9983                http::StatusCode::from_u16(200u16).unwrap(),
9984                Some(mime::APPLICATION_JSON),
9985            ),
9986        ),
9987        crate::__combinators::Json::new,
9988    ))
9989}
9990future!(
9991    GetVectorStoreFile,
9992    futures::future::AndThen<
9993        crate::__combinators::Send<Fut, B, E>,
9994        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileObject>,
9995        fn(
9996            http::Response<B>,
9997        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileObject>,
9998    >,
9999    crate::__types::VectorStoreFileObject
10000);
10001#[doc = "Delete vector store file"]
10002pub fn delete_vector_store_file<C, Fut, B, E>(
10003    client: C,
10004    params: &crate::__types::delete_vector_store_file::Params,
10005) -> DeleteVectorStoreFile<Fut, B, E>
10006where
10007    C: FnOnce(http::Request<String>) -> Fut,
10008    Fut: Future<Output = Result<http::Response<B>, E>>,
10009    B: http_body::Body,
10010{
10011    DeleteVectorStoreFile(futures::TryFutureExt::and_then(
10012        crate::__combinators::Send::new(
10013            client,
10014            || {
10015                let path = {
10016                    #[serde_with::serde_as]
10017                    #[derive(serde :: Serialize)]
10018                    struct Query<'a> {
10019                        #[serde(skip_serializing)]
10020                        _phantom: std::marker::PhantomData<&'a ()>,
10021                    }
10022                    let crate::__types::delete_vector_store_file::Params {
10023                        vector_store_id,
10024                        file_id,
10025                    } = params;
10026                    #[allow(clippy::useless_format)]
10027                    let mut path = format!("/vector_stores/{vector_store_id}/files/{file_id}");
10028                    let query = serde_urlencoded::to_string(Query {
10029                        _phantom: std::marker::PhantomData,
10030                    })?;
10031                    if !query.is_empty() {
10032                        path.push('?');
10033                        path.push_str(&query);
10034                    }
10035                    path
10036                };
10037                let body = String::new();
10038                Ok(http::Request::builder()
10039                    .method(http::Method::DELETE)
10040                    .uri(path)
10041                    .header(http::header::CONTENT_LENGTH, body.len())
10042                    .body(body)?)
10043            },
10044            (
10045                http::StatusCode::from_u16(200u16).unwrap(),
10046                Some(mime::APPLICATION_JSON),
10047            ),
10048        ),
10049        crate::__combinators::Json::new,
10050    ))
10051}
10052future!(
10053    DeleteVectorStoreFile,
10054    futures::future::AndThen<
10055        crate::__combinators::Send<Fut, B, E>,
10056        crate::__combinators::Json<B, E, crate::__types::DeleteVectorStoreFileResponse>,
10057        fn(
10058            http::Response<B>,
10059        )
10060            -> crate::__combinators::Json<B, E, crate::__types::DeleteVectorStoreFileResponse>,
10061    >,
10062    crate::__types::DeleteVectorStoreFileResponse
10063);
10064#[doc = "Update vector store file attributes"]
10065pub fn update_vector_store_file_attributes<C, Fut, B, E>(
10066    client: C,
10067    params: &crate::__types::update_vector_store_file_attributes::Params,
10068    request: &crate::__types::UpdateVectorStoreFileAttributesRequest,
10069) -> UpdateVectorStoreFileAttributes<Fut, B, E>
10070where
10071    C: FnOnce(http::Request<String>) -> Fut,
10072    Fut: Future<Output = Result<http::Response<B>, E>>,
10073    B: http_body::Body,
10074{
10075    UpdateVectorStoreFileAttributes(futures::TryFutureExt::and_then(
10076        crate::__combinators::Send::new(
10077            client,
10078            || {
10079                let path = {
10080                    #[serde_with::serde_as]
10081                    #[derive(serde :: Serialize)]
10082                    struct Query<'a> {
10083                        #[serde(skip_serializing)]
10084                        _phantom: std::marker::PhantomData<&'a ()>,
10085                    }
10086                    let crate::__types::update_vector_store_file_attributes::Params {
10087                        vector_store_id,
10088                        file_id,
10089                    } = params;
10090                    #[allow(clippy::useless_format)]
10091                    let mut path = format!("/vector_stores/{vector_store_id}/files/{file_id}");
10092                    let query = serde_urlencoded::to_string(Query {
10093                        _phantom: std::marker::PhantomData,
10094                    })?;
10095                    if !query.is_empty() {
10096                        path.push('?');
10097                        path.push_str(&query);
10098                    }
10099                    path
10100                };
10101                let body = serde_json::to_string(request)?;
10102                Ok(http::Request::builder()
10103                    .method(http::Method::POST)
10104                    .uri(path)
10105                    .header(http::header::CONTENT_LENGTH, body.len())
10106                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
10107                    .body(body)?)
10108            },
10109            (
10110                http::StatusCode::from_u16(200u16).unwrap(),
10111                Some(mime::APPLICATION_JSON),
10112            ),
10113        ),
10114        crate::__combinators::Json::new,
10115    ))
10116}
10117future!(
10118    UpdateVectorStoreFileAttributes,
10119    futures::future::AndThen<
10120        crate::__combinators::Send<Fut, B, E>,
10121        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileObject>,
10122        fn(
10123            http::Response<B>,
10124        ) -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileObject>,
10125    >,
10126    crate::__types::VectorStoreFileObject
10127);
10128#[doc = "Retrieve vector store file content"]
10129pub fn retrieve_vector_store_file_content<C, Fut, B, E>(
10130    client: C,
10131    params: &crate::__types::retrieve_vector_store_file_content::Params,
10132) -> RetrieveVectorStoreFileContent<Fut, B, E>
10133where
10134    C: FnOnce(http::Request<String>) -> Fut,
10135    Fut: Future<Output = Result<http::Response<B>, E>>,
10136    B: http_body::Body,
10137{
10138    RetrieveVectorStoreFileContent(futures::TryFutureExt::and_then(
10139        crate::__combinators::Send::new(
10140            client,
10141            || {
10142                let path = {
10143                    #[serde_with::serde_as]
10144                    #[derive(serde :: Serialize)]
10145                    struct Query<'a> {
10146                        #[serde(skip_serializing)]
10147                        _phantom: std::marker::PhantomData<&'a ()>,
10148                    }
10149                    let crate::__types::retrieve_vector_store_file_content::Params {
10150                        vector_store_id,
10151                        file_id,
10152                    } = params;
10153                    #[allow(clippy::useless_format)]
10154                    let mut path =
10155                        format!("/vector_stores/{vector_store_id}/files/{file_id}/content");
10156                    let query = serde_urlencoded::to_string(Query {
10157                        _phantom: std::marker::PhantomData,
10158                    })?;
10159                    if !query.is_empty() {
10160                        path.push('?');
10161                        path.push_str(&query);
10162                    }
10163                    path
10164                };
10165                let body = String::new();
10166                Ok(http::Request::builder()
10167                    .method(http::Method::GET)
10168                    .uri(path)
10169                    .header(http::header::CONTENT_LENGTH, body.len())
10170                    .body(body)?)
10171            },
10172            (
10173                http::StatusCode::from_u16(200u16).unwrap(),
10174                Some(mime::APPLICATION_JSON),
10175            ),
10176        ),
10177        crate::__combinators::Json::new,
10178    ))
10179}
10180future!(
10181    RetrieveVectorStoreFileContent,
10182    futures::future::AndThen<
10183        crate::__combinators::Send<Fut, B, E>,
10184        crate::__combinators::Json<B, E, crate::__types::VectorStoreFileContentResponse>,
10185        fn(
10186            http::Response<B>,
10187        )
10188            -> crate::__combinators::Json<B, E, crate::__types::VectorStoreFileContentResponse>,
10189    >,
10190    crate::__types::VectorStoreFileContentResponse
10191);
10192#[doc = "Search vector store"]
10193pub fn search_vector_store<C, Fut, B, E>(
10194    client: C,
10195    params: &crate::__types::search_vector_store::Params,
10196    request: &crate::__types::VectorStoreSearchRequest,
10197) -> SearchVectorStore<Fut, B, E>
10198where
10199    C: FnOnce(http::Request<String>) -> Fut,
10200    Fut: Future<Output = Result<http::Response<B>, E>>,
10201    B: http_body::Body,
10202{
10203    SearchVectorStore(futures::TryFutureExt::and_then(
10204        crate::__combinators::Send::new(
10205            client,
10206            || {
10207                let path = {
10208                    #[serde_with::serde_as]
10209                    #[derive(serde :: Serialize)]
10210                    struct Query<'a> {
10211                        #[serde(skip_serializing)]
10212                        _phantom: std::marker::PhantomData<&'a ()>,
10213                    }
10214                    let crate::__types::search_vector_store::Params { vector_store_id } = params;
10215                    #[allow(clippy::useless_format)]
10216                    let mut path = format!("/vector_stores/{vector_store_id}/search");
10217                    let query = serde_urlencoded::to_string(Query {
10218                        _phantom: std::marker::PhantomData,
10219                    })?;
10220                    if !query.is_empty() {
10221                        path.push('?');
10222                        path.push_str(&query);
10223                    }
10224                    path
10225                };
10226                let body = serde_json::to_string(request)?;
10227                Ok(http::Request::builder()
10228                    .method(http::Method::POST)
10229                    .uri(path)
10230                    .header(http::header::CONTENT_LENGTH, body.len())
10231                    .header(http::header::CONTENT_TYPE, mime::APPLICATION_JSON.as_ref())
10232                    .body(body)?)
10233            },
10234            (
10235                http::StatusCode::from_u16(200u16).unwrap(),
10236                Some(mime::APPLICATION_JSON),
10237            ),
10238        ),
10239        crate::__combinators::Json::new,
10240    ))
10241}
10242future!(
10243    SearchVectorStore,
10244    futures::future::AndThen<
10245        crate::__combinators::Send<Fut, B, E>,
10246        crate::__combinators::Json<B, E, crate::__types::VectorStoreSearchResultsPage>,
10247        fn(
10248            http::Response<B>,
10249        )
10250            -> crate::__combinators::Json<B, E, crate::__types::VectorStoreSearchResultsPage>,
10251    >,
10252    crate::__types::VectorStoreSearchResultsPage
10253);