File tree Expand file tree Collapse file tree
connector_typesense/readme Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1+ typesense
2+ ~~~~~~~~~
3+
4+ requirements: to pretty print json, install jq on your system;
5+
6+
7+ in terminal export the API key
8+
9+ .. code-block ::
10+
11+ export TYPESENSE_API_KEY='xyz'
12+ export TYPESENSE_HOST='http://localhost:8108'
13+
14+ list all collections (indexes):
15+
16+ .. code-block ::
17+
18+ curl -H "X-TYPESENSE-API-KEY: ${TYPESENSE_API_KEY}" \
19+ "http://localhost:8108/collections" | jq
20+
21+
22+ retrieve collection details of the products collection (index):
23+
24+ .. code-block ::
25+
26+ curl -H "X-TYPESENSE-API-KEY: ${TYPESENSE_API_KEY}" \
27+ -X GET "http://localhost:8108/collections/typesense_backend_1_product_variant_en_us" | jq
28+
29+
30+ list aliases:
31+
32+ .. code-block ::
33+ curl -H "X-TYPESENSE-API-KEY: ${TYPESENSE_API_KEY}" \
34+ "http://localhost:8108/aliases" | jq
35+
36+
37+
38+ get alias info:
39+
40+ .. code-block ::
41+ curl -H "X-TYPESENSE-API-KEY: ${TYPESENSE_API_KEY}" \
42+ "http://localhost:8108/aliases/typesense_backend_1_product_variant_en_us" | jq
43+
44+
45+
46+
47+ search for all products:
48+
49+ curl -H "X-TYPESENSE-API-KEY: ${TYPESENSE_API_KEY}" \
50+ "http://localhost:8108/collections/typesense_backend_1_product_variant_en_us/documents/search?q=*" | jq
You can’t perform that action at this time.
0 commit comments