Search Posts API

Overview

The Search Posts API allows you to search and sort relevant posts created in Social Plus. This API returns a sorted list of post objects that contain the relevant content.

API Endpoint

Example Curl


curl --location 'https://beta.amity.services/api/v3/search/posts?query=Amity&targetType=community&types[]=image&postedUserId=userId' \
--header 'Authorization: Bearer {access_token}'

Query Params Details

targetType can be the following values:

  • community: Search posts in all communities specified in targetIds.

  • user: Search all posts on the user feed specified in targetIds.

  • targetIds limited to 100 Ids per search.

filter can be the following values:

  • all: Search posts in all public communities

  • member: Search posts in all communities that the user has joined

  • notMember: Search posts in all public communities that the user has not joined

Limitations

  • Currently, searching within a post’s metadata is not supported.

  • Posts created on a user feed within a network that has privacy enabled are not yet searchable.

Last updated