| 0 |
## Read API |
0 |
## Read API |
| ... |
|
... |
|
| 30 |
|
30 |
|
| 31 |
<p style="padding-left: 224px;"> |
31 |
|
| 32 |
<img src="/static/images/arrow.red.png" alt="arrow" /><a href="#querying">Querying for Objects (/things)</a><br /> |
32 |
<ul style="padding-left: 224px;"> |
| 33 |
<img src="/static/images/arrow.red.png" alt="arrow" /><a href="#getting">Getting an Object (/get)</a><br /> |
33 |
<li><a href="#querying">Querying for Objects (/things)</a></li> |
| 34 |
<img src="/static/images/arrow.red.png" alt="arrow" /><a href="#versions">Queries for Versions (/versions)</a><br /> |
34 |
<li><a href="#getting">Getting an Object (/get)</a></li> |
| 35 |
<img src="/static/images/arrow.red.png" alt="arrow" /><a href="#search">Search queries (/search)</a><br /> |
35 |
<li><a href="#versions">Queries for Versions (/versions)</a></li> |
| 36 |
</p> |
36 |
<li><a href="#search">Search queries (/search)</a></li> |
|
|
37 |
</ul> |
|
|
38 |
|
| 37 |
|
37 |
|
| ... |
|
... |
|
| 42 |
<br clear="all" /> |
42 |
<br clear="all" /> |
| 43 |
<a name="querying"></a> |
45 |
<a name="querying"> </a> |
| 44 |
|
44 |
|
| ... |
|
... |
|
| 51 |
|
51 |
|
| 52 |
<script> |
54 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
55 |
<pre> |
| 53 |
var request = { |
53 |
var request = { |
| ... |
|
... |
|
| 63 |
query(request, response); |
63 |
query(request, response); |
| 64 |
</script> |
67 |
</pre></div> |
| 65 |
|
68 |
|
| 66 |
A curl request for the above, then, would read as follows: |
69 |
A curl request for the above, then, would read as follows: |
| 67 |
|
70 |
|
| 68 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
71 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
| 69 |
<pre>$ curl -G --data-urlencode 'query={"type":"\/type\/edition", "isbn_10":"0789312239"}' \ |
72 |
<pre> |
|
|
73 |
$ curl -G --data-urlencode 'query={"type":"\/type\/edition", "isbn_10":"0789312239"}' \ |
| 70 |
http://openlibrary.org/api/things</pre> |
70 |
http://openlibrary.org/api/things</pre> |
| ... |
|
... |
|
| 78 |
|
78 |
|
| 79 |
<script> |
83 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
84 |
<pre> |
| 80 |
var request = { |
80 |
var request = { |
| ... |
|
... |
|
| 116 |
query(request, response); |
116 |
query(request, response); |
| 117 |
</script> |
122 |
</pre></div> |
| 118 |
|
118 |
|
| ... |
|
... |
|
| 126 |
|
126 |
|
| 127 |
<script> |
132 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
133 |
<pre> |
| 128 |
var request = { |
128 |
var request = { |
| ... |
|
... |
|
| 141 |
|
141 |
|
| 142 |
</script> |
148 |
</pre></div> |
| 143 |
|
149 |
|
| 144 |
By default sort operation returns the results in the ascending order. To reverse that order, prepend minus (`-`) to the value of `sort` directive. |
150 |
By default sort operation returns the results in the ascending order. To reverse that order, prepend minus (`-`) to the value of `sort` directive. |
| 145 |
|
151 |
|
| 146 |
<script> |
152 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
153 |
<pre> |
| 147 |
var request = { |
147 |
var request = { |
| ... |
|
... |
|
| 161 |
|
161 |
|
| 162 |
</script> |
169 |
</pre></div> |
| 163 |
|
163 |
|
| ... |
|
... |
|
| 169 |
|
169 |
|
| 170 |
<script> |
177 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
178 |
<pre> |
| 171 |
var request = { |
171 |
var request = { |
| ... |
|
... |
|
| 192 |
query(request, response); |
192 |
query(request, response); |
| 193 |
</script> |
201 |
</pre></div> |
| 194 |
|
202 |
|
| 195 |
The `offset` directive can be used to ask infogami to give results from a specific offset. |
203 |
The `offset` directive can be used to ask infogami to give results from a specific offset. |
| 196 |
|
204 |
|
| 197 |
The following query gives the next 10 templates. |
205 |
The following query gives the next 10 templates. |
| 198 |
|
206 |
|
| 199 |
<script> |
207 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
208 |
<pre> |
| 200 |
var request = { |
200 |
var request = { |
| ... |
|
... |
|
| 223 |
query(request, response); |
223 |
query(request, response); |
| 224 |
</script> |
233 |
</pre></div> |
| 225 |
|
225 |
|
| ... |
|
... |
|
| 231 |
|
231 |
|
| 232 |
<script> |
241 |
<div class="query" style="width: 800px; margin-left: 100px;"> |
|
|
242 |
<pre> |
| 233 |
|
233 |
|
| ... |
|
... |
|
| 252 |
query(request, response) |
252 |
query(request, response) |
| 253 |
</script> |
263 |
</pre></div> |
| 254 |
|
264 |
|
| 255 |
<a name="getting"></a> |
265 |
<a name="getting"> </a> |
| 256 |
### Getting an Object (/get) |
256 |
### Getting an Object (/get) |
| ... |
|
... |
|
| 359 |
|
359 |
|
| 360 |
<a name="versions"></a> |
370 |
<a name="versions"> </a> |
| 361 |
### Queries for Versions (/versions) |
361 |
### Queries for Versions (/versions) |
| ... |
|
... |
|
| 425 |
|
425 |
|
| 426 |
<a name="search"></a> |
436 |
<a name="search">&nsbp;</a> |
| 427 |
### Search queries (/search) |
437 |
### Search queries (/search) |
| 428 |
|
438 |
|
| 429 |
There is an incomplete search API as the final interface has not been decided. Only rudimentary search functions are supported for now. Development in progress is being discussed in the Open Library bug tracker at <a href="https://bugs.launchpad.net/openlibrary/+bug/236947">https://bugs.launchpad.net/openlibrary/+bug/236947</a>; interested parties are invited to post comments and requests in that tracker item. |
439 |
<b>This search API is deprecated and not maintained now. The <a href="/dev/docs/api/books">Open Library Books API</a> can be used for searching for ISBNs or other identifiers. We are working on a new work search API to replace this.</b> |
|
|
440 |
|
|
|
441 |
<del class="black"> |
|
|
442 |
There is an incomplete search API as the final interface has not been decided. Only rudimentary search functions are supported for now. Development in progress is being discussed in the Open Library bug tracker at https://bugs.launchpad.net/openlibrary/+bug/236947; interested parties are invited to post comments and requests in that tracker item.</del> |
| 430 |
|
430 |
|
| ... |
|
... |
|
| 484 |
<br /><br /><br /> |
484 |
<br /><br /><br /> |
|