Skip to content

User Panel

  • Endpoint Path: /api/v2/user/panel
  • Method: GET
  • Request: Query

Headers Optional Parameter

Parameter NamePublic Mode (Required)Private Mode (Required)
X-Fresns-Aidrequiredrequired
X-Fresns-Aid-Tokenrequiredrequired
X-Fresns-Uidoptionaloptional
X-Fresns-Uid-Tokenoptionaloptional

Query Params

Parameter NameTypeRequiredDescription
uidOrUsernameNumber / StringoptionalUser uid or username

Request Description

  • Unlogged user can also request
  • The headers X-Fresns-Uid and Query uidOrUsername cannot be empty, one of them must be passed.
  • If uidOrUsername is passed, then the user panel information is requested, if it is empty, then the X-Fresns-Uid user panel information is requested.
  • Query user uidOrUsername must belong to a logged-in account, querying other users is not supported.

Return

json
{
    "code": 0,
    "message": "ok",
    "data": {
        "multiUser": {
            "status": "Boolean / Whether they have the right to use",
            "service": "String / Service plugin URL parameter"
        },
        "features": [
            {
                // User Feature Extensions
                // Common Data Structure -> Extend Function Info
            }
        ],
        "profiles": [
            {
                // User Profile Extensions
                // Common Data Structure -> Extend Function Info
            }
        ],
        "conversations": {
            "conversationCount": "Number / Conversation count",
            "unreadMessages": "Number / Unread conversation message count"
        },
        "unreadNotifications":{
            "all": "Number / Total of all unread below",
            "systems": "Number / Unread system notifications",
            "recommends": "Number / Unread recommendations",
            "likes": "Number / Unread likes",
            "dislikes": "Number / Unread dislikes",
            "follows": "Number / Unread follows",
            "blocks": "Number / Unread blocks",
            "mentions": "Number / Unread mentions (at)",
            "comments": "Number / Unread comments (replies)",
            "quotes": "Number / Unread quotes (reshare)"
        },
        "draftCount": {
            "posts": "Number / Post draft count",
            "comments": "Number / Comment draft count"
        },
        "fileAccept": {
            "images": "String / Allowed image extensions",
            "videos": "String / Allowed video extensions",
            "audios": "String / Allowed audio extensions",
            "documents": "String / Allowed document extensions"
        }
    }
}

Released under the Apache-2.0 License