openai2 2.0.0

OpenAi client, generated from the OpenAPI spec.
Documentation
1
2
3
4
5
6
7
8
9
10
#![allow(unused_imports)]
use openai::OpenAiClient;
use openai::model::*;
#[tokio::main]
async fn main() {
    let client = OpenAiClient::from_env();
    let file_id = "your file id";
    let response = client.retrieve_file(file_id).await.unwrap();
    println!("{:#?}", response);
}