-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathindex.html
110 lines (83 loc) · 3.52 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
104
105
106
107
108
109
110
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>WAS API Client Demo</title>
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap.min.css">
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.5/css/bootstrap-theme.min.css">
</head>
<body class="container">
<br/>
<div class="row">
<div class="col-md-6">
<h1>Login</h1><br/>
<p>In order to use the Infomedia API you should first log in. You can use your username and password for
Infomedia's apps. If you've been given a token by Infomedia then you can use that for logging in.</p>
<p>The <a href="http://api-sandbox.superservice.com/v1/auth/docs/">Login</a> service will generate an Access
Token that grants you access to all authorized Infomedia API services. You should pass it in the
"Authorization" header in all API calls.</p>
<p>You can view the full documentation of the Authentication service here:
<br/>
<a href="http://api-sandbox.superservice.com/v1/auth/docs/">http://api-sandbox.superservice.com/v1/auth/docs/</a>
</p>
<br/>
<p>Please choose one of the following login options:</p>
<br/>
<form class="col-md-offset-1" onsubmit="event.preventDefault();login()">
<div class="form-group">
<label>Username:
<input type="email" name="username" value=""/>
</label>
</div>
<div class="form-group">
<label>Password:
<input type="password" name="password" value=""/>
</label>
</div>
Or
<br/><br/>
<div class="form-group">
<label>Refresh Token:
<input type="text" name="refreshToken" value=""/>
</label>
</div>
<button type="submit" class="btn btn-primary">Log In</button>
</form>
</div>
<div id="appointments" style="display:none" class="col-md-6">
<h1>Get Appointments</h1><br/>
<p>Now that you're logged in you can try calling the <a href="http://api-sandbox.superservice.com/v1/was/docs/">Get
Appointments</a> service.</p>
<p>You can view the full documentation of the WAS service here:
<br/>
<a href="http://api-sandbox.superservice.com/v1/was/docs/">http://api-sandbox.superservice.com/v1/was/docs/</a>
</p>
<p>The following JSON will be posted to the service. Click the button below to call the <b>/appointmentGet</b>
service.</p>
<textarea id="getAppointmentsRequest" style="width:450px;height:200px">
{
"transactionHeader": {
"dealerID": "12345"
},
"dmsDealerID": "12345",
"appointmentDateTimeFromLocal": "2015-10-14T10:08:15Z",
"appointmentDateTimeToLocal": "2015-10-15T10:08:15Z"
}
</textarea>
<br/>
<button type="submit" class="btn btn-primary" onclick="getAppointments()">Get Appointments</button>
<br/><br/>
<textarea id="getAppointmentsRequestResult" style="width:450px;height:150px;display:none"></textarea>
</div>
</div>
<hr/>
<div class="row jumbotron">
<div class="col-md-12" id="output">
</div>
</div>
</body>
<script src="util.js"></script>
<script src="main.js"></script>
</html>