Search for the interest you actually want to discuss

For a hypothetical balcony-gardening exchange, use that precise subject in keyword instead of a broad lifestyle term. Group search discovers potentially relevant discussion entry points. It does not verify discussion quality or guarantee that every candidate permits immediate membership. Define what you want to ask so you can assess whether the subject fits.

Group pagination starts at zero

This operation uses page_no beginning at zero, unlike some note and user searches. Preserve the initial search_id for further retrieval and set source and is_recommend according to their definitions; the recommendation switch uses zero for no and one for yes. Do not interpret that switch as a quality certification. Record changed search conditions rather than mixing different keyword results into an unexplained ranking.

Check published conditions before joining

Your shortlist can contain the source, relevant subject, joining requirements to confirm, and reasons to set an option aside. Do not assume the search reads membership lists or chat history, and do not infer members’ identities from a group name. Review the current group description and respect its participation boundaries. The result should be a few places worth exploring. Appearing in search is not joining authorisation or an invitation to use a community for unsolicited promotion.

Request URL and parameters

GET https://api.trmesh.com/openapi/api/v1/xiaohongshu/app_v2/search_groups

Parameter Type Required Meaning
keyword string Yes Search keyword
page_no integer No Page number, start from 0
search_id string No Search ID for pagination
source string No Source
is_recommend integer No Is recommend: 0=no, 1=yes

Run the Python example

Install requests and set TRMESH_API_TOKEN in your environment. Replace the sample identifiers with the public object you intend to inspect. Example IDs may no longer be available.

import os
import requests

# Read your own developer key from the server environment.
url = "https://api.trmesh.com/openapi/api/v1/xiaohongshu/app_v2/search_groups"
params = {
    "keyword": "上海",
    "page_no": "0",
    "source": "unifiedSearchGroup",
    "is_recommend": "0"
}
response = requests.get(
    url, params=params, timeout=30,
    headers={"Authorization": f"Bearer {os.environ['TRMESH_API_TOKEN']}"},
)
response.raise_for_status()
payload = response.json()
print(payload)  # Inspect the actual response before mapping fields

Endpoint documentation · Free profile tool

API calls use your TRMesh account allowance. Check the endpoint price before running a script.