获取成员[单个]

  • 接口地址: /api/fresns/member/detail
  • 请求方式: POST
  • 请求格式: JSON

header 可选参数:

参数名公开模式(是否必传)私有模式(是否必传)
uidNOYES
midNOYES
tokenNOYES

body 参数:

参数名类型是否必传说明
viewMidStringNO输出该 mid 的成员信息
viewMnameStringNO输出该 mname 的成员信息

返回结果:

成功

{
    "code": 0,
    "message": "ok",
    "data": {
        "common": {
            "seoInfo": {
                //以成员表 ID 和语言标签在 SEO 数据表查找值,如果找不到则为空。
                //接口请求语言标签为空,则以默认语言查找,如果接口有语言标签参数,则以此查找。
                //无论哪种语言标签,找不到则留空,无默认内容。
                "title": "seo > title",
                "keywords": "seo > keywords",
                "description": "seo > description"
            },
            "manages": [
                // plugin_usages > type=5 + scene 字段包含 3
                // plugin_usages > member_roles 为空,则全部输出;有值则判断当前请求成员的所有关联角色 id 是否在字段配置中。
                {
                    "plugin": "plugin_usages > plugin_unikey",
                    "name": "plugin_usages > name 多语言",
                    "icon": "plugin_usages > icon_file_url",
                    "url": "详见 plugins 地址拼接说明"
                }
            ],
            "features": [
                // plugin_usages > type=7
                // plugin_usages > member_roles 为空,则全部输出;有值则判断当前请求成员的所有关联角色 id 是否在字段配置中。
                // 查看别人信息时不输出。
                {
                    "plugin": "plugin_usages > plugin_unikey",
                    "name": "plugin_usages > name 多语言",
                    "icon": "plugin_usages > icon_file_url",
                    "url": "详见 plugins 地址拼接说明",
                    "badgesType": "plugin_badges > display_type",
                    "badgesValue": "plugin_badges > value_text 或者 value_number"
                }
            ],
            "profiles": [
                // plugin_usages > type=8
                // plugin_usages > member_roles 为空,则全部输出;有值则判断当前请求成员的所有关联角色 id 是否在字段配置中。
                // 查看别人信息时不输出。
                {
                    "plugin": "plugin_usages > plugin_unikey",
                    "name": "plugin_usages > name 多语言",
                    "icon": "plugin_usages > icon_file_url",
                    "url": "详见 plugins 地址拼接说明",
                    "badgesType": "plugin_badges > display_type",
                    "badgesValue": "plugin_badges > value_text 或者 value_number"
                }
            ]
        },
        "detail": {
            "mid": "members > uuid",
            "mname": "members > name",
            "nickname": "members > nickname",
            "rid": "主角色的值 member_roles > id",
            "nicknameColor": "主角色的值 member_roles > nickname_color",
            "roleName": "主角色的值 member_roles > name 多语言",
            "roleNameDisplay": "主角色的值 member_roles > is_display_name",
            "roleIcon": "主角色的值 member_roles > icon_file_url",
            "roleIconDisplay": "主角色的值 member_roles > is_display_icon",
            "avatar": "members > avatar_file_url",
            "decorate": "members > decorate_file_url",
            "gender": "members > gender",
            "birthday": "members > birthday",
            "bio": "members > bio",
            "dialogLimit": "members > dialog_limit",
            "timezone": "members > timezone",
            "language": "members > language",
            "expiredTime": "members > expired_at",
            "verifiedStatus": "members > verified_status",
            "verifiedIcon": "members > verified_file_url",
            "verifiedDesc": "members > verified_desc",
            "lastEditMname": "members > last_name_at",
            "lastEditNickname": "members > last_nickname_at",
            "createdTime": "members > created_at",
            "status": "members > is_enable",
            "roles": [
                {
                    "type": "member_role_rels > type",
                    "rid": "member_roles > id",
                    "name": "member_roles > name 多语言",
                    "icon": "member_roles > icon_file_url",
                    "nicknameColor": "member_roles > nickname_color",
                    "permission": [
                        // member_roles 表 permission 字段所有内容
                    ]
                }
            ],
            "stats": {
                "likeMemberCount": "member_stats > like_member_count",
                "likeGroupCount": "member_stats > like_group_count",
                "likeHashtagCount": "member_stats > like_hashtag_count",
                "likePostCount": "member_stats > like_post_count",
                "likeCommentCount": "member_stats > like_comment_count",
                "followMemberCount": "member_stats > follow_member_count",
                "followGroupCount": "member_stats > follow_group_count",
                "followHashtagCount": "member_stats > follow_hashtag_count",
                "followPostCount": "member_stats > follow_post_count",
                "followCommentCount": "member_stats > follow_comment_count",
                "shieldMemberCount": "member_stats > shield_member_count",
                "shieldGroupCount": "member_stats > shield_group_count",
                "shieldHashtagCount": "member_stats > shield_hashtag_count",
                "shieldPostCount": "member_stats > shield_post_count",
                "shieldCommentCount": "member_stats > shield_comment_count",
                "likeMeCount": "member_stats > like_me_count",
                "followMeCount": "member_stats > follow_me_count",
                "shieldMeCount": "member_stats > shield_me_count",
                "postPublishCount": "member_stats > post_publish_count",
                "postLikeCount": "member_stats > post_like_count",
                "commentPublishCount": "member_stats > comment_publish_count",
                "commentLikeCount": "member_stats > comment_like_count",
                "extcredits1Status": "扩展 1 状态 extcredits1_status",
                "extcredits1Name": "扩展 1 名称 extcredits1_name 多语言",
                "extcredits1Unit": "扩展 1 单位 extcredits1_unit 多语言",
                "extcredits1": "member_stats > extcredits1",
                "extcredits2Status": "扩展 2 状态 extcredits2_status",
                "extcredits2Name": "扩展 2 名称 extcredits2_name 多语言",
                "extcredits2Unit": "扩展 2 单位 extcredits2_unit 多语言",
                "extcredits2": "member_stats > extcredits2",
                "extcredits3Status": "扩展 3 状态 extcredits3_status",
                "extcredits3Name": "扩展 3 名称 extcredits3_name 多语言",
                "extcredits3Unit": "扩展 3 单位 extcredits3_unit 多语言",
                "extcredits3": "member_stats > extcredits3",
                "extcredits4Status": "扩展 1 状态 extcredits4_status",
                "extcredits4Name": "扩展 4 名称 extcredits4_name 多语言",
                "extcredits4Unit": "扩展 4 单位 extcredits4_unit 多语言",
                "extcredits4": "member_stats > extcredits4",
                "extcredits5Status": "扩展 1 状态 extcredits5_status",
                "extcredits5Name": "扩展 5 名称 extcredits5_name 多语言",
                "extcredits5Unit": "扩展 5 单位 extcredits5_unit 多语言",
                "extcredits5": "member_stats > extcredits5"
            },
            "icons": [
                {
                    "icon": "member_icons > icon_file_url",
                    "name": "member_icons > name 多语言",
                    "type": "member_icons > type",
                    "url": "member_icons > plugin_unikey 根据关联插件输出地址,详见 plugins 地址拼接说明"
                }
            ],
            "draftCount": {
                // 查看别人信息时不输出,只有自己时输出
                "posts": "实时计算帖子草稿数量(state=1+4)",
                "comments": "实时计算评论草稿数量(state=1+4)"
            },
            "memberName": "配置表键名 member_name 多语言",
            "memberIdName": "配置表键名 member_id_name 多语言",
            "memberNameName": "配置表键名 member_name_name 多语言",
            "memberNicknameName": "配置表键名 member_nickname_name 多语言",
            "memberRoleName": "配置表键名 member_role_name 多语言",
            "followSetting": "配置表键名 follow_member_setting 布尔型",
            "followName": "配置表键名 follow_member_name 多语言",
            "followStatus": "查询 member_follows 表,我是否关注了他。0.未关注 1.已关注",
            "followMeStatus": "反向查询 member_follows 表,他是否关注了我。0.未关注 1.已关注",
            "likeSetting": "配置表键名 like_member_setting 布尔型",
            "likeName": "配置表键名 like_member_name 多语言",
            "likeStatus": "查询 member_likes 表。输出 0.未点赞 1.已点赞",
            "shieldSetting": "配置表键名 shield_member_setting 布尔型",
            "shieldName": "配置表键名 shield_member_name 多语言",
            "shieldStatus": "查询 member_shields 表。输出 0.未屏蔽 1.已屏蔽"
        }
    }
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163

失败

{
    "code": "code_messages > code",
    "message": "code_messages > message"
}
1
2
3
4

开发说明

  • 无论是否登录,输出的是 viewMidviewMname 成员信息,不是 header 里的 mid 的成员信息。
  • viewMidviewMname 二选一。如果 viewMid 有值,则忽略 viewMname 参数;如果 viewMid 为空,则以 viewMname 查询成员信息。
  • 自己的 mid 和接口 viewMid 参数一样,则代表自己查看自己的信息;参数不一样,代表查看别人的信息。
  • 查看别人的信息,参数 extcredits1 要判断 extcredits1_status 键值,未启用或者为私有状态,则不输出。其他 2~5 同理。
  • 查看别人的信息,featuresprofiles 扩展列表不输出。
  • 所有涉及图片的参数,需要判断是否开启了防盗链,如果开启了,不能直接使用 URL 字段值,需要获取防盗链链接。