-
Notifications
You must be signed in to change notification settings - Fork 1
/
doc.php
192 lines (190 loc) · 6.32 KB
/
doc.php
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
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>Betaville Web Service</title>
</head>
<body>
<div>
<div>
<h1>Welcome to the Betaville Web Service</h1>
<div>
<p>The web service is broken up into <em>sections</em>, each of which has a number of calls available, which are described as <em>requests</em></p>
</div>
</div>
<!-- Lists the sections and requests -->
<div>
<ul>
<li>
<h3>user</h3>
<ul>
<li>
<h4>auth</h4><p>logs a user in</p>
<p><strong>Returns</strong> - Session token</p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> - The username</li>
<li><strong>password</strong> - The password</li>
</ul>
</li>
<li>
<h4>startsession</h4><p>logs a user in<br /><em>Deprecated (use "auth")</em></p>
<p><strong>Returns</strong> - Session token</p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> - The username</li>
<li><strong>password</strong> - The password</li>
</ul>
</li>
<li>
<h4>endsession</h4><p>logs a user out, invalidating the session token</p>
<p><strong>Returns</strong> - true or false, depending on success</p>
<h5>parameters</h5>
<ul>
<li><strong>token</strong> - The session token</li>
</ul>
</li>
<li>
<h4>add</h4><p>Adds a new user</p>
<p><strong>Returns</strong> - true or false, depending on success</p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> - new username</li>
<li><strong>password</strong> - new user's password</li>
<li><strong>email</strong> - email address of the user where validation mail will be sent</li>
</ul>
</li>
<li>
<h4>activateuser</h4><p>Activates a user account</p>
<p><strong>Returns</strong> - true or false, depending on success</p>
<h5>parameters</h5>
<ul>
<li><strong>code</strong> The user's activation code</li>
</ul>
</li>
<li>
<h4>activated</h4><p>Checks if a user has already been activated</p>
<p><strong>Returns</strong> - true or false, depending on whether or not the user has been activated</p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> The user name to check the activation state of</li>
</ul>
</li>
<li>
<h4>available</h4><p>Checks if a username is available for registration</p>
<p><strong>Returns</strong> - true or false, depending on whether or not the username can be registered</p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> The user name to check the availability of</li>
</ul>
</li>
<li>
<h4>changepass</h4><p>Changes a user's password</p>
<p><strong>Returns</strong> - true or a response indicating the lack of authenticated credentials</p>
<h5>parameters</h5>
<ul>
<li><strong>oldpass</strong> The user's previous password</li>
<li><strong>newpass</strong> The user's new password</li>
</ul>
</li>
<li>
<h4>changebio</h4><p>Changes a user's biographic entry</p>
<p><strong>Returns</strong> - true or a response indicating the lack of authenticated credentials</p>
<h5>parameters</h5>
<ul>
<li><strong>bio</strong> The user's new biographical information</li>
</ul>
</li>
<li>
<h4>updateavatar</h4><p>Changes a user's avatar image</p>
<p><strong>Returns</strong> - true or a response indicating the lack of authenticated credentials</p>
<h5>parameters</h5>
<ul>
<li><strong>FILE DATA</strong> The user's new avatar image</li>
</ul>
</li>
<li>
<h4>getmail</h4><p>Gets a user's email address if it is available</p>
<p><strong>Returns</strong> - The user's email address</p>
<h5>parameters</h5>
<ul>
</ul>
</li>
<li>
<h4>checklevel</h4><p>Gets the user's user type</p>
<p><strong>Returns</strong> - <strong>member</strong>, or <strong>base_committer</strong>, or <strong>data_searcher</strong>, or <strong>moderator</strong>, or <strong>admin</strong></p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> - The username to get the user type of</li>
</ul>
</li>
<li>
<h4>getpublicinfo</h4><p>Gets the user's publicly available details</p>
<p><strong>Returns</strong> - The user's publicly available information</p>
<h5>parameters</h5>
<ul>
<li><strong>username</strong> - The username to get the details of</li>
</ul>
</li>
</ul>
</li>
<li>
<h3>coordinate</h3>
<ul>
<li>
<h4>getutm</h4><p>Gets a coordinate as a UTM coordinate</p>
<p><strong>Returns</strong> - A UTM coordinate</p>
<h5>parameters</h5>
<ul>
<li><strong>id</strong> - The id of the coordinate to retrieve</li>
</ul>
</li>
<li>
<h4>getlatlon</h4><p>Gets a coordinate as a lat/lon coordinate</p>
<p><strong>Returns</strong> - A lat/lon coordinate</p>
<h5>parameters</h5>
<ul>
<li><strong>id</strong> - The id of the coordinate to retrieve</li>
</ul>
</li>
</ul>
</li>
<li>
<h3>design</h3>
<ul>
<li>
<h4>synchronizedata</h4><p><em>unimplemented</em></p>
<p><strong>Returns</strong> - </p>
<h5>parameters</h5>
<ul>
</ul>
</li>
<li>
<h4>addempty</h4><p><em>unimplemented</em></p>
<p><strong>Returns</strong> - </p>
<h5>parameters</h5>
<ul>
</ul>
</li>
<li>
<h4>addbase</h4><p><em>unimplemented</em></p>
<p><strong>Returns</strong> - </p>
<h5>parameters</h5>
<ul>
</ul>
</li>
<li>
<h4>addbasethumbnail</h4><p><em>Adds a thumbnail for a model</em></p>
<p><strong>Returns</strong> - </p>
<h5>parameters</h5>
<ul>
<li><strong>FILE DATA</strong> The new thumbnail image</li>
</ul>
</li>
</ul>
</li>
</ul>
</div>
</div>
</body>
</html>