generated from x-dr/chatgptProxyAPI
-
Notifications
You must be signed in to change notification settings - Fork 0
/
index.html
103 lines (98 loc) · 7.36 KB
/
index.html
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
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<link rel="icon" href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAACAAAAAgCAYAAABzenr0AAAAAXNSR0IArs4c6QAABnxJREFUWEetV2lMlFcUPd8MMMywyiKrDIussgzKqoKgIhYFtbFWa2Lq0hhj1ZhImjRtmjRp2iamtbY1GumSGC2gFgVUsKAi+z44DPu+yi4MO8x8zXvICDgwEH0/Jpm8d+8975177r0fgwXrwq3rnhwu5zgLdjsAIQCdhWdW+H8ELJoApHE43D9+PHBUMteemf1z5uFlnrZM8AuAzwBwVhhkuccVYHFtXH/0/K8RZyeIEQUwE5yfCjBbluvpnc4xeDauO7qTgKAAouNirgI4+U5OV2jMAlcufnziNEM4Z7hM6XKe3VCgixAXD7hZCmEo0MGUfBotfT3Ib6hGWUs92JWBkLMsREx03PXLAHNGna2rxRp8EhgKTa4GWvq60TU0AC0NTaxdbQk9bT4qOlpwpygLWlwNjE1OYGxqUp1LMGAvMdFxMVIAbkudtlpljNNbIzE4NoKbeU/R1t+rPK7B5eJE8E7Ym5rPc9E+0Ie0ilJI25sXd81CylyIi5ExgO5SAE6GRMDayASXHt9D3/CQ8igBFiUKgJ2pOYbHx/CirREDI8MwEOjAw9oOBnwBiptqcbswCwpWoSqEjLzAotS5WtrAz84JblZCZNdKkViaR53o8vjY6bEBvnZONA/SK8uQWVOO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pPxaGBjRhlTUVIv4BbcnflU2I1Ldvtx9EG0DvbQEs+xMwySKMNbVUwYm7TbC0w8ioQOl5k5hJm1YLhZrcCxoB7UjdJU21yO+8LmybixZCWc3Nzm60cwmuk0oycbk9LTSjiRTsLMHQl28QAaSgoZqpJYX03wga5ZCIltS/UjdWGwtOZAQAAQI4b68vZl2OiMdPbhbC+lMQLpjojiPNqHZRfbPh++jews1rwqE2pGMJB9JSBtjU0rB7CKtOCYjZd7sR6amwwGh0Ofr4Lf0xHnAFn2B6NiYS2BwbtE3er1BqhnJjYnpKXzoswneNg4YnZxAc183ZGOjdCawMTHDxNQUbuU9QVXnTFNSt5gv4v/yULBy8XLG8rnOSLn1d3DBGiMT8DV5lB6ijufVEgy+npDUBacqID/RsTFXwODUcgze95k3n2bDghSwCHnfAdT5m/dxypMJfmJmPtG46gzf174SwKzDC7Ex7hyGPc6yTBjLQKjum+FdgfwPVAUVDIGyUFAAAAAASUVORK5CYII=
" />
<meta content="width=device-width, initial-scale=1, maximum-scale=1, user-scalable=no" name="viewport">
<title>OpenAI/ChatGPT 工具箱</title>
<!-- Bootstrap CSS -->
<link href="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.2.3/css/bootstrap.min.css" rel="stylesheet">
<script defer src="https://cdn.bootcdn.net/ajax/libs/alpinejs/3.12.0/cdn.min.js"></script>
<link href="/assets/css/style.css" rel="stylesheet">
</head>
<body>
<nav class="navbar navbar-expand-md navbar-dark fixed-top bg-dark">
<div class="container">
<button class="navbar-toggler" type="button" data-bs-toggle="collapse" data-bs-target="#navbarCollapse"
aria-controls="navbarCollapse" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarCollapse">
<ul class="navbar-nav me-auto mb-2 mb-lg-0">
<li class="nav-item">
<a class="nav-link active" href="/">Home</a>
</li>
<!-- <li class="nav-item">
<a class="nav-link" href="./gallery.html">Gallery</a>
</li> -->
<li class="nav-item">
<a class="nav-link" href="./about.html">About</a>
</li>
</ul>
</div>
</div>
</nav>
<div class="container kv-main">
<div class="page-header" x-data="{ origin: '' }" x-init="origin = window.location.origin">
<h2>查询 OpenaiAPI 余额</h2>
<p>API接口: <span class="proxy" x-text="origin" @click="copyToClipboard(origin)"></span>
;支持批量查询,一行一个;点击清理可以清理失效的key。<a style="text-decoration: none;" href="/about.html">Authorization获取方法</a> </p>
</div>
<main x-data="app" x-cloak>
<p x-show.transition.opacity="alert" :class="alert?.type" x-text="alert?.message"></p>
<textarea class="form-control" rows="5" placeholder="请输入以sess-xxxx开头的Authorization" x-model="u"></textarea></p>
<div class="d-grid gap-2 d-sm-block">
<button :class="{ loading }" class="btn btn-primary me-sm-3 " :disabled="loading"
@click="submit($refs)">查询</button>
<button class="btn btn-secondary" @click="clear">清理</button>
</div>
<p></p>
<div x-show.transition.opacity="total && total.length > 0" x-cloak class="card mb-3">
<div class="card-body table-responsive">
<table class="table">
<thead>
<tr>
<th scope="col">#</th>
<th scope="col">API KEY</th>
<th scope="col">账号类型</th>
<th scope="col">最高模型</th>
<th scope="col">额度总量</th>
<th scope="col">已用额度</th>
<th scope="col">剩余额度</th>
<th scope="col">过期时间</th>
</tr>
</thead>
<tbody x-show.transition.opacity="total" x-cloak>
<template x-for="(item, index) in total" :key="index">
<tr>
<th scope="row" x-text="index + 1"></th>
<td x-text="item.msgkey"></td>
<td x-text="item.plan"></td>
<td x-text="item.latest_gpt"></td>
<td x-text="item.total_granted"></td>
<td x-text="item.total_used"></td>
<td x-text="item.total_available"></td>
<td x-text="item.endDate"></td>
</tr>
</template>
</tbody>
</table>
</div>
</div>
</main>
<div class="page-footer"></div>
</div>
<footer class="footer">
<div class="container text-center">
<!-- <p class="text-muted" x-data="ip" x-init='$nextTick(() => {getipinfo()})' x-show.transition.opacity="ipinfo"
x-text="ipinfo"></p> -->
<p>本程序基于Cloudflare Pages,开源于GitHub <a href="https://github.com/x-dr/chatgptProxyAPI"
target="_blank">chatgptProxyAPI</a></p>
</div>
</footer>
<script src="./assets/js/openai.js"></script>
<script src="https://cdn.bootcdn.net/ajax/libs/twitter-bootstrap/5.2.3/js/bootstrap.min.js"></script>
</body>
</html>