Skip to content

Commit

Permalink
Fix rest-api.md (#2540)
Browse files Browse the repository at this point in the history
  • Loading branch information
16BitNarwhal authored Jun 26, 2024
1 parent 964ffef commit 9cc2d89
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions docs/rest-api.md
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ The search query endpoint is `api/v1.0/indexes/{index_name}/search?query={query}

Path variables:

- `index`: The index name to query. Default is "msmarco-v1-passage"
- `index_name`: The index name to query. Default is "msmarco-v1-passage"

Query parameters:

Expand Down Expand Up @@ -118,11 +118,16 @@ Here's an example of getting the document of the top candidate from the above ex
curl -X GET "http://localhost:8080/api/v1.0/indexes/msmarco-v2.1-doc/documents/msmarco_v2.1_doc_15_390497775"
```

Output is an object containing the 'cached' property
Output is an object of the same format as a candidate from search

```json
{
"cached": true
"doc": {
"url": "https://diabetestalk.net/blood-sugar/conversion-of-carbohydrates-to-glucose",
"title": "Conversion Of Carbohydrates To Glucose | DiabetesTalk.Net",
"headings": "...",
"body": "..."
}
}
```

Expand All @@ -140,11 +145,6 @@ Output is an object containing the 'cached' property

```json
{
"doc": {
"url": "https://diabetestalk.net/blood-sugar/conversion-of-carbohydrates-to-glucose",
"title": "Conversion Of Carbohydrates To Glucose | DiabetesTalk.Net",
"headings": "...",
"body": "..."
}
"cached": true
}
```

0 comments on commit 9cc2d89

Please sign in to comment.