Spaces:
Sleeping
Sleeping
Create index.html
Browse files- index.html +58 -0
index.html
ADDED
@@ -0,0 +1,58 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<!DOCTYPE html>
|
2 |
+
<html lang="en">
|
3 |
+
|
4 |
+
<head>
|
5 |
+
<meta charset="utf-8" />
|
6 |
+
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
7 |
+
<meta name="description" content="SwaggerUI" />
|
8 |
+
<title>3GPP SBI OpenAPI</title>
|
9 |
+
<link rel="stylesheet" href="https://unpkg.com/[email protected]/swagger-ui.css" />
|
10 |
+
<style>
|
11 |
+
#sidebar {
|
12 |
+
position: fixed;
|
13 |
+
top: 0;
|
14 |
+
left: 0;
|
15 |
+
width: 200px;
|
16 |
+
height: 100%;
|
17 |
+
border-right: 1px solid #ccc;
|
18 |
+
padding: 10px;
|
19 |
+
overflow: auto;
|
20 |
+
}
|
21 |
+
|
22 |
+
#swagger-ui {
|
23 |
+
margin-left: 210px;
|
24 |
+
padding-top: 20px;
|
25 |
+
}
|
26 |
+
</style>
|
27 |
+
</head>
|
28 |
+
|
29 |
+
<body>
|
30 |
+
<div id="sidebar">
|
31 |
+
<h3>Select API:</h3>
|
32 |
+
<ul>
|
33 |
+
<li><a href="#" onclick="loadSwagger('https://petstore3.swagger.io/api/v3/openapi.json')">Petstore</a></li>
|
34 |
+
<li><a href="#" onclick="loadSwagger('https://raw.githubusercontent.com/OAI/OpenAPI-Specification/main/examples/v3.0/api-with-examples.yaml')">Second API</a></li>
|
35 |
+
|
36 |
+
<!-- Add more API links here -->
|
37 |
+
</ul>
|
38 |
+
</div>
|
39 |
+
<div id="swagger-ui"></div>
|
40 |
+
<script src="https://unpkg.com/[email protected]/swagger-ui-bundle.js" crossorigin></script>
|
41 |
+
<script>
|
42 |
+
function loadSwagger(url) {
|
43 |
+
if (window.ui) {
|
44 |
+
window.ui.destroy();
|
45 |
+
}
|
46 |
+
window.ui = SwaggerUIBundle({
|
47 |
+
url: url,
|
48 |
+
dom_id: '#swagger-ui'
|
49 |
+
});
|
50 |
+
}
|
51 |
+
|
52 |
+
window.onload = () => {
|
53 |
+
loadSwagger('https://petstore3.swagger.io/api/v3/openapi.json');
|
54 |
+
};
|
55 |
+
</script>
|
56 |
+
</body>
|
57 |
+
|
58 |
+
</html>
|