> For the complete documentation index, see [llms.txt](https://relationlabs.gitbook.io/relation-one-api/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://relationlabs.gitbook.io/relation-one-api/api-zh/api/recommendation.md).

# 用户推荐

## <mark style="color:blue;">GET</mark> /api/v1/recommend

* 说明：Social Graph推荐引擎根据用户twitter关注、以太坊链上交易、持有的nft、当前following的用户等信息进行用户推荐
* Header

| Field         | Type   | Remarks                                                            |
| ------------- | ------ | ------------------------------------------------------------------ |
| ApiKey        | String | 从管理员获取的[ApiKey](/relation-one-api/api-zh/guide/glossary.md#apikey) |
| Authorization | String | Bearer ${unifiedAuthToken} ,其中unifiedAuthToken来自/api/v1/auth接口的返回  |

* Request Parameters

| Field  | Type   | Remarks                         |
| ------ | ------ | ------------------------------- |
| limit  | int    | 每次查询数量，上限100                    |
| cursor | string | 上一页返回的 cursor数据,cursor为空表示查询第一页 |

* Request Example

```shell
curl GET 'https://api.relationlabs.ai/api/v1/recommend?cursor=a604fdd8e80142dfaf07af11096d5150&limit=10' \
--header 'Authorization: Bearer ey1JhbGciOiJFUzI1NiJ9.eyJqdGkiOiIyYzAzYTMwZGY4NjY0Mjk5OWZlMDcwODhh1MzVhNGU0YiIsImlzcyI6InJlbGF0aW9ubGFicy5haSIsImlhdCI6MTY2MTQwNTQxOSwic3ViIjoiYmFmMzQta2lhYWEtYWFhYWstYWNnamEtY2FpIiwiZXhwIjoxNjYyMDEwMjE5fQ.1EVbUxmtVCm6aEVZtEAji1KuCM1dsZEOMExcYvT-GdKrHRQ1qzyghXsNZSdSDUAwoSe9jGV48_1zdi2Rlrylw3Q' \
--header 'ApiKey: <ApiKey>'
```

* Response Parameters

| Field | Type              | Remarks |
| ----- | ----------------- | ------- |
| code  | String            | 返回码     |
| desc  | String            | 返回信息    |
| data  | RecommendResponse | 数据      |

The RecommendResponse field consists of the following subfields:

| Field  | Type                 | Remarks    |
| ------ | -------------------- | ---------- |
| cursor | String               | 游标         |
| list   | List\[RecommendUser] | follower列表 |

The RecommendUser field consists of the following subfields:

| Field           | Type    | Remarks                                                                                                   |
| --------------- | ------- | --------------------------------------------------------------------------------------------------------- |
| relationId      | String  | 用户id                                                                                                      |
| name            | String  | 用户姓名                                                                                                      |
| avatar          | String  | 用户头像                                                                                                      |
| recommendReason | String  | 推荐理由:Following on twitterCounterparty on ethereumHolder of ${nft name}Followed by ${followingUser's name} |
| following       | boolean | 是否关注：true-已关注；false-未关注                                                                                   |

* Response Body

```json
{
  "code": "0",
  "desc": "success",
  "data": {
    "cursor": "a8728c5910a04c94b70e18694d72cbb0",
    "list": [
      {
        "relationId": "aoafg-eqaaa-aaaaj-afena-cai",
        "name": "test_user",
        "avatar": "https://3fypb-gqaaa-aaaag-aaedq-cai.ic1.io/avatar/nft/eth/0xed5af388653567af2f388e6224dc7c4b3241c544/1.jpg",
        "recommendReason": "Holder of Azuki",
        "following": false
      },
      ...
    ]
  }
}
```

* Return Code

| code | desc    | Remarks |
| ---- | ------- | ------- |
| 0    | success | 接口调用成功  |


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://relationlabs.gitbook.io/relation-one-api/api-zh/api/recommendation.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
