forked from bterlson/openai-in-typespec
-
Notifications
You must be signed in to change notification settings - Fork 1
/
main.tsp
36 lines (33 loc) · 859 Bytes
/
main.tsp
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import "@typespec/http";
import "@typespec/openapi3";
import "@typespec/openapi";
import "./audio";
import "./assistants";
import "./chat";
import "./completions";
import "./embeddings";
import "./files";
import "./fine-tuning";
import "./images";
import "./messages";
import "./models";
import "./moderations";
import "./runs";
import "./threads";
using TypeSpec.Http;
/** The OpenAI REST API. Please see https://platform.openai.com/docs/api-reference for more details. */
@service({
title: "OpenAI API",
termsOfService: "https://openai.com/policies/terms-of-use",
contact: {
name: "OpenAI Support",
url: "https://help.openai.com",
},
license: {
name: "MIT",
url: "https://github.com/openai/openai-openapi/blob/master/LICENSE",
}
})
@server("https://api.openai.com/v1", "OpenAI Endpoint")
@useAuth(BearerAuth)
namespace OpenAI;