How to add a new line in an existing topic query
To add a new into a query in an existing topic, we need to set the field override
to FALSE. It will act as if you click on the button “New Line” in the UI:
Command
curl -X POST 'https://api.talkwalker.com/api/v2/talkwalker/p/<project_id>/topics/import?access_token=<access_token>'
Request
{
"topic_type": "search",
"topic_line_import": [
{
"topic_id": "l2stbi2e_1555byu18z5b5",
"topic_title": "my new topic",
"category_id": "default",
"override": false,
"query": "sourcetype:Trendiction AND sourcetype:SOCIALMEDIA_TWITTER",
"included_query": true
}
]
}
important
The field “topic_id” is mandatory, otherwise a new topic will be created even if there is already a topic with the same name in the group.
The fields “category_id” and “topic_title” are also mandatory.
Result in Talkwalker: