Newer Version Available
Topics on Records Resource
The topics assigned to a record or feed item. Get
information about topics assigned to a record or feed item and add, remove, and replace
topics on a record or feed item. Only users with the “Assign Topics”
permission can remove topics from records or feed items and add existing topics to records or
feed items. Only users with the “Create Topics” permission can add new topics to
records or feed items. Administrators must enable topics
for objects before users can add topics to records of that object type.
- Resource
-
1/connect/records/recordId/topics1/connect/communities/communityId/records/recordId/topics - Available since version
- 30.0
- Requires Chatter
- No
- HTTP methods
- GET, DELETE, POST, PUT
PUT is supported in version 35.0 and later.
- Request parameters for DELETE
-
Parameter Name Type Description Required or Optional Available Version topicId String ID of an existing topic Required 30.0 - Response body for DELETE
- 204: Successful Delete
- Request body for POST
-
- Root XML tag
- <topicAssignment>
- JSON
- The following example assigns a topic to a record:
1{ "topicId": "0TOD0000000090r" 2} - Properties
-
- Request parameters for POST
-
Parameter Name Type Description Required or Optional Available Version topicId String ID of an existing topic Required for existing topics if the topicName parameter isn’t used 30.0 topicName String Name of a new or existing topic Required for new topics; required for existing topics if the topicId parameter isn’t used 30.0 - Response body for POST
- Topic
- Example for POST
- This example passes the ID of an existing topic in the topidId parameter to associate it with an
opportunity
record:
1POST /connect/records/006D000000CtYBc/topics?topicId=0TOD0000000090r - Request body for PUT
- PUT requests reassign all topics on a record or feed item, that is, replace all assigned topics on a record or feed item with different topics.
-
- Root XML tag
- <topicNamesCollection>
- JSON example
-
1{ "topicNames": ["API", "Chatter REST API", "ConnectApi"] 2} - Properties
-
Name Type Description Required or Optional Available Version topicNames String[] A list of up to 10 topic names for a feed item or 100 topic names for a record. Required 35.0
- Response body for PUT
- Topic Collection