-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathtypes.ts
63 lines (57 loc) · 1.34 KB
/
types.ts
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
import { HTTPStatusRes } from './structures/http_status'
interface GistOptions {
secret: boolean
}
interface IGist {
create(files: GistFile, description: string, options?: Partial<GistOptions>): Promise<any>
delete(id: string): Promise<any>
get(id: string): Promise<any>
}
interface GistResponse {
url: string
forks_url: string
commits_url: string
id: string
node_id: string
git_pull_url: string
git_push_url: string
html_url: string
files: GistFile
public: boolean
created_at: string
updated_at: string
description: string
comments: number
comments_url: string
owner: {
login: string
id: number
node_id: string
avatar_url: string
gravatar_id: string
url: string
html_url: string
followers_url: string
following_url: string
gists_url: string
starred_url: string
subscriptions_url: string
organizations_url: string
repos_url: string
events_url: string
received_events_url: string
type: string
site_admin: boolean
}
truncated: boolean
}
interface ReqRet<T> {
data?: T
status: HTTPStatusRes
}
interface GistFile {
[key: string]: {
content: string
}
}
export { GistOptions, IGist, GistResponse, GistFile, ReqRet }