API

Search for Notes

Description

Retrieves notes that match a given search query

URL

/api/v1/notes/

HTTP Method

GET

Path Parameters

None

Query Parameters

  • q (String): the search query (required)

Data Parameters

None

Request Headers

  • Content-Type: application/json
  • Authorization: Bearer

Response

  • Status Code: 200
  • Content-Type: application/json
  • Schema/Example::
{
  "data": {
    "search_results": [
      {
        "item_id": "w078qlgo",
        "title": "Beautiful One bedroom - must see! - apts/housing for rent -...",
        "url": "https://newyork.craigslist.org/brx/apa/d/bronx-beautiful-one-bedroom-must-see/7294892474.html",
        "note": "<p>places in town now</p>",
        "tags": [],
        "created": "2021-07-11T10:09:01.252539Z",
        "modified": "2021-07-11T10:09:01.252584Z"
      },
      {
        "item_id": "a69jntmo",
        "title": "Hacker News",
        "url": "https://news.ycombinator.com/",
        "note": "<p>checking for save status just for now</p>",
        "tags": [],
        "created": "2021-07-11T10:09:01.252539Z",
        "modified": "2021-07-11T10:09:01.252584Z"
      }
    ],
    "count": 50,
    "next": "https://histre.com/api/v1/notes/?page=2&q=e",
    "previous": null
  }
  "error": false,
  "errcode": 0,
  "errmsg": null,
  "status": 200
}

Note: This endpoint returns a paginated response, please see Pagination section under Overview of this API documentation.

Search for Collections

Description

Search for collections that belong to a user using a search query

URL

/api/v1/collections/search/

HTTP Method

GET

Path Parameters

None

Query Parameters

  • q (String): all or part of the collection title to search for (required)
  • url (String): if passed, the collections in search results will include info if they're associated (linked) to the given URL (optional)
  • channel (String): the source of the search request, can be "extension" or "web" (optional; the default is "web")

Data Parameters

None

Request Headers

  • Content-Type: application/json
  • Authorization: Bearer

Response

  • Status Code: 200
  • Content-Type: application/json
  • Schema/Example: the below example is the response when the source channel is "web"
{
  "data": {
    "search_results": [
      {
        "book_id": "i129h6zu",
        "title": "First Private Collection of user1",
        "slug": "first-private-collection-of-user1",
        "public": false,
        "created": "2021-07-11T10:09:01.252539Z",
        "modified": "2021-07-11T10:09:01.252584Z"
      },
      {
        "book_id": "i1zpxqtz",
        "title": "First Public Collection of user1",
        "slug": "first-public-collection-of-user1",
        "public": true,
        "created": "2021-07-11T10:09:01.252539Z",
        "modified": "2021-07-11T10:09:01.252584Z"
      }
    ]
  },
  "error": false,
  "errcode": 0,
  "errmsg": null,
  "status": 200
}
Selection