Skip to content

Xiaohongshu Pgy APIs - Fans Profile (V1)

prod-global
GET
/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1

Get detailed fans profile for a specific KOL.

Parameters

NameInTypeRequiredDescription
tokenquerystringYesUser authentication token.
userIdquerystringYesKOL's user ID.

Code Samples

💡 Environment Note

Default samples use https://api.justoneapi.com (prod-global). For users in Mainland China, it is recommended to replace it with http://47.117.133.51:30015 (prod-cn) for better performance. See Environment Guide.

bash
# Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
curl -X GET "https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1?token=YOUR_API_KEY&userId=VALUE"
text
I want to use the "Fans Profile (V1)" API from Just One API.
API Endpoint: https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1
HTTP Method: GET
Authentication: Append "?token=YOUR_API_KEY" to the URL.
OpenAPI Definition: https://docs.justoneapi.com/openapi/xiaohongshu-pgy-apis/fans-profile-v1-en.json

Parameters:
- token (query): User authentication token. (Required)
- userId (query): KOL's user ID. (Required)

Return format: JSON

Response Handling & Error Codes:
1. Business results should be determined by the "code" field in the response body (code 0 means success).
2. Timeout Recommendation: Set request timeout to at least 60 seconds.
3. Business Code Reference:
   - 0: Success
   - 100: Invalid or Inactive Token
   - 301: Collection Failed. Please Retry.
   - 302: Rate Limit Exceeded
   - 303: Daily Quota Exceeded
   - 400: Invalid Parameters
   - 500: Internal Server Error
   - 600: Permission Denied
   - 601: Insufficient Balance

Please help me write a script in my preferred programming language to call this API and handle the response.
python
# Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
import requests

url = "https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1?token=YOUR_API_KEY&userId=VALUE"
response = requests.get(url)
print(response.json())
js
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
const response = await fetch("https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1?token=YOUR_API_KEY&userId=VALUE", {
  method: "GET"
});
const data = await response.json();
console.log(data);
java
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;

public class Main {
    public static void main(String[] args) throws Exception {
        HttpClient client = HttpClient.newHttpClient();
        HttpRequest request = HttpRequest.newBuilder()
            .uri(URI.create("https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1?token=YOUR_API_KEY&userId=VALUE"))
            .method("GET", HttpRequest.BodyPublishers.noBody())
            .build();

        HttpResponse<String> response = client.send(request, HttpResponse.BodyHandlers.ofString());
        System.out.println(response.body());
    }
}
go
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
package main

import (
	"fmt"
	"io"
	"net/http"
)

func main() {
	client := &http.Client{}
	url := "https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1?token=YOUR_API_KEY&userId=VALUE"
	req, _ := http.NewRequest("GET", url, nil)
	resp, _ := client.Do(req)
	defer resp.Body.Close()
	body, _ := io.ReadAll(resp.Body)
	fmt.Println(string(body))
}
php
// Tip: For Mainland China, replace https://api.justoneapi.com with http://47.117.133.51:30015
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "https://api.justoneapi.com/api/xiaohongshu-pgy/api/solar/kol/data/userId/fans_profile/v1?token=YOUR_API_KEY&userId=VALUE");
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
$response = curl_exec($ch);
curl_close($ch);
echo $response;

Responses

json
{
  "code": 0,
  "data": {
    "ages": [
      {
        "group": "<18",
        "percent": 0.07849255324084814
      },
      {
        "group": "18-24",
        "percent": 0.10353547070013455
      },
      {
        "group": "25-34",
        "percent": 0.2690228738458683
      },
      {
        "group": "35-44",
        "percent": 0.2506031642926739
      },
      {
        "group": ">44",
        "percent": 0.2983459379204751
      }
    ],
    "gender": {
      "male": 0.19751310722405235,
      "female": 0.8024868927759476
    },
    "interests": [
      {
        "name": "生活记录",
        "percent": 0.09937930058430662
      },
      {
        "name": "美食",
        "percent": 0.08938700597336137
      },
      {
        "name": "娱乐",
        "percent": 0.06654940097901124
      },
      {
        "name": "情感",
        "percent": 0.05395344866705755
      },
      {
        "name": "萌娃",
        "percent": 0.053854604026121945
      },
      {
        "name": "搞笑",
        "percent": 0.04894382254691189
      },
      {
        "name": "兴趣爱好",
        "percent": 0.045039459229955316
      },
      {
        "name": "影视",
        "percent": 0.0435792543070429
      },
      {
        "name": "二次元",
        "percent": 0.04190563481847406
      },
      {
        "name": "母婴",
        "percent": 0.04181802252309932
      },
      {
        "name": "宠物",
        "percent": 0.039315455932138664
      },
      {
        "name": "时尚",
        "percent": 0.03778561046674889
      },
      {
        "name": "社科",
        "percent": 0.036080540410609624
      },
      {
        "name": "家居家装",
        "percent": 0.03414633050502872
      },
      {
        "name": "游戏",
        "percent": 0.033921683593811425
      },
      {
        "name": "健康",
        "percent": 0.028516678909923328
      },
      {
        "name": "美妆",
        "percent": 0.02366879856585412
      },
      {
        "name": "教育",
        "percent": 0.02037772131652076
      },
      {
        "name": "旅游",
        "percent": 0.01917361387239606
      },
      {
        "name": "健身减肥",
        "percent": 0.014923294312164855
      }
    ],
    "provinces": [
      {
        "name": "广东",
        "percent": 0.09235000147854629
      },
      {
        "name": "山东",
        "percent": 0.08270002267104316
      },
      {
        "name": "海外",
        "percent": 0.07914165459187193
      },
      {
        "name": "江苏",
        "percent": 0.06495746715162985
      },
      {
        "name": "浙江",
        "percent": 0.053592374643916765
      },
      {
        "name": "河南",
        "percent": 0.05126612847581591
      },
      {
        "name": "河北",
        "percent": 0.04311440991217435
      },
      {
        "name": "四川",
        "percent": 0.038452060600684075
      },
      {
        "name": "北京",
        "percent": 0.038442203625395514
      },
      {
        "name": "湖北",
        "percent": 0.03402627869611931
      },
      {
        "name": "上海",
        "percent": 0.03359257178342254
      },
      {
        "name": "辽宁",
        "percent": 0.031966170860809655
      },
      {
        "name": "湖南",
        "percent": 0.0311283279612818
      },
      {
        "name": "安徽",
        "percent": 0.03041862574050527
      },
      {
        "name": "福建",
        "percent": 0.029196360804723463
      },
      {
        "name": "陕西",
        "percent": 0.027875526116056027
      },
      {
        "name": "山西",
        "percent": 0.0226414722378291
      },
      {
        "name": "广西",
        "percent": 0.020384224896748186
      },
      {
        "name": "江西",
        "percent": 0.020334940020305368
      },
      {
        "name": "黑龙江",
        "percent": 0.019713950577125904
      },
      {
        "name": "重庆",
        "percent": 0.017013139348059654
      },
      {
        "name": "云南",
        "percent": 0.016589289410651447
      },
      {
        "name": "天津",
        "percent": 0.015761303486412158
      },
      {
        "name": "吉林",
        "percent": 0.015721875585257908
      },
      {
        "name": "内蒙古",
        "percent": 0.015169884969098383
      },
      {
        "name": "贵州",
        "percent": 0.01225222028368375
      },
      {
        "name": "新疆",
        "percent": 0.011729800593389912
      },
      {
        "name": "台湾",
        "percent": 0.011650944791081409
      },
      {
        "name": "甘肃",
        "percent": 0.011345378557135957
      },
      {
        "name": "香港",
        "percent": 0.010438536830588166
      },
      {
        "name": "海南",
        "percent": 0.00784615232969611
      },
      {
        "name": "宁夏",
        "percent": 0.004277927275236321
      },
      {
        "name": "青海",
        "percent": 0.0019418241318469014
      },
      {
        "name": "中国",
        "percent": 0.001389833515687376
      },
      {
        "name": "澳门",
        "percent": 0.0011236951828961766
      },
      {
        "name": "西藏",
        "percent": 0.0004534208632738958
      }
    ],
    "cities": [
      {
        "name": "北京",
        "percent": 0.038442203625395514
      },
      {
        "name": "上海",
        "percent": 0.03359257178342254
      },
      {
        "name": "广州",
        "percent": 0.018550827493075475
      },
      {
        "name": "深圳",
        "percent": 0.018195976382687207
      },
      {
        "name": "重庆",
        "percent": 0.017013139348059654
      },
      {
        "name": "成都",
        "percent": 0.016875141694019772
      },
      {
        "name": "天津",
        "percent": 0.015761303486412158
      },
      {
        "name": "杭州",
        "percent": 0.01429261416841628
      },
      {
        "name": "武汉",
        "percent": 0.013474485219465555
      }
    ],
    "devices": [
      {
        "name": "apple inc.",
        "desc": "苹果",
        "percent": 0.27666663380878687
      },
      {
        "name": "huawei",
        "desc": "华为",
        "percent": 0.22285528403994204
      },
      {
        "name": "vivo",
        "desc": "vivo",
        "percent": 0.12216231135469753
      },
      {
        "name": "oppo",
        "desc": "oppo",
        "percent": 0.11489743412816544
      },
      {
        "name": "honor",
        "desc": "honor",
        "percent": 0.10273344702159748
      },
      {
        "name": "xiaomi",
        "desc": "小米",
        "percent": 0.09607972635957693
      },
      {
        "name": "samsung",
        "desc": "三星",
        "percent": 0.021134188295366053
      },
      {
        "name": "realme",
        "desc": "realme",
        "percent": 0.01045866314430195
      },
      {
        "name": "oneplus",
        "desc": "oneplus",
        "percent": 0.008782911273867142
      },
      {
        "name": "wiko",
        "desc": "wiko",
        "percent": 0.0037063688428440465
      }
    ],
    "dateKey": "2026-03-08"
  }
}

💡 Note: For list data, the example shows only 1-2 items for simplicity. The actual count depends on the API response.