Retrieve Synonym Groups

This endpoint is used to retrieve any or all synonym groups owned by the given key. If no group_id or phrase is given, all owned groups will be returned. Otherwise, only the synonym group with the given group id will be returned.

curl -X GET -H "Content-Type: application/json" \
-u"[your token]:" "https://ac.cnstrc.com/v1/synonym_groups?key=[your API key]"
curl -X GET -H "Content-Type: application/json" \
-u"[your token]:" "https://ac.cnstrc.com/v1/synonym_groups/4?key=[your API key]"
info

The above command returns a 200 Success response on success.

HTTP Request#

GET https://ac.cnstrc.com/v1/synonym_groups?key=[your API key]

GET https://ac.cnstrc.com/v1/synonym_groups/[group_id]?key=[your API key]

GET https://ac.cnstrc.com/v1/synonym_groups/[phrase]?key=[your API key]

Response format#

{
"synonym_groups": [
{
"synonym_group_id": 4,
"synonyms": ["0% milk", "skim milk", "nonfat milk"]
},
{
"synonym_group_id": 5,
"synonyms": ["orange juice", "oj", "o.j."]
}
],
"total_count": 2
}

Query Parameters#

ParameterRequired?Description
group_idNoThe synonym group you would like returned.
phraseNoThe phrase for which all synonym groups containing it will be returned.
num_results_per_pageNoThe number of synonym groups to return. Defaults to 100.
pageNoThe page of results to return. Defaults to 1.