index_search_api.rst 941 B

12345678910111213141516171819202122232425262728293031323334353637383940414243
  1. :title: Docker Index documentation
  2. :description: Documentation for docker Index
  3. :keywords: docker, index, api
  4. =======================
  5. Docker Index Search API
  6. =======================
  7. Search
  8. ------
  9. .. http:get:: /v1/search
  10. Search the Index given a search term. It accepts :http:method:`get` only.
  11. **Example request**:
  12. .. sourcecode:: http
  13. GET /v1/search?q=search_term HTTP/1.1
  14. Host: example.com
  15. Accept: application/json
  16. **Example response**:
  17. .. sourcecode:: http
  18. HTTP/1.1 200 OK
  19. Vary: Accept
  20. Content-Type: application/json
  21. {"query":"search_term",
  22. "num_results": 2,
  23. "results" : [
  24. {"name": "dotcloud/base", "description": "A base ubuntu64 image..."},
  25. {"name": "base2", "description": "A base ubuntu64 image..."},
  26. ]
  27. }
  28. :query q: what you want to search for
  29. :statuscode 200: no error
  30. :statuscode 500: server error