Sand AISand AI MAGI-2MAGI-2 hiện đã có trên SandBase: video 1080p với âm thanh gốcDùng thử ngay

Bilibili User ID Extraction

Tài liệu API
https://api.sandbase.ai/v1/api/bilibili/web/get-user-id

Extracts and returns a Bilibili user ID from a provided space share link. Takes a user profile URL and resolves the numeric account identifier.

Giá
$0.001USD / lượt gọi
Phương thức
POST
Phản hồi
JSON
Tham số
1 bắt buộc · 0 tùy chọn

Phòng thử nghiệm

Đầu vào
Đầu raVí dụ
Phản hồioutputs · 60 B · 7 dòng
[
  {
    "data": {
      "user_id": "178360345"
    }
  }
]

Ví dụ

Chọn một ví dụ để nạp đầu vào và kết quả của nó vào playground.

README API

Bilibili User ID Extraction API

This API takes a Bilibili user space share link in share_link and returns the numeric user ID found in it. The response has one field, user_id, returned as a string.

Use cases

  • Turn a copied https://space.bilibili.com/... link into a numeric ID for storage or matching.
  • Clean a list of creator profile URLs collected from web pages into one ID column.
  • Get the user ID you need before calling Bilibili profile, video, or dynamic endpoints.

Request

curl -X POST "https://api.sandbase.ai/v1/api/bilibili/web/get-user-id" \
  -H "Authorization: Bearer $SANDBASE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"share_link": "https://space.bilibili.com/178360345"}'

The result is returned in outputs[0].data.

Parameters

NameTypeRequiredDescription
share_linkstringYesUser share link

Example response

Real response for the request above, trimmed: lists keep their first item and long strings are cut.

{
  "user_id": "178360345"
}

Response fields

FieldMeaning
user_idThe numeric Bilibili account ID taken from the share link. For the example link https://space.bilibili.com/178360345, the value is "178360345".
user_idThe value is a JSON string, not a number. Keep it as text when you store it or pass it on.
user_idThis is the only field in the response. It matches the number at the end of the space link in share_link.

Notes

  • Pass a full space link such as https://space.bilibili.com/178360345 in share_link.
  • user_id is a string, so keep it as text if you pass it on to other calls.
  • Use the ID with Bilibili User Profile to get account details, or with Bilibili User Post Videos to list the user's videos.

Pricing

$0.001 per successful call. Failed calls are not charged. It is included in the daily free quota of each organization.

Khám phá thêm

APIs liên quan

Tất cả APIs
APIGiáPhản hồi
Bilibili$0.001 mỗi lần gọiJSON
Bilibili$0.001 mỗi lần gọiJSON
Bilibili$0.001 mỗi lần gọiJSON
Bilibili$0.001 mỗi lần gọiJSON
Bilibili$0.001 mỗi lần gọiJSON
Bilibili$0.001 mỗi lần gọiJSON

Hướng dẫn:Best Bilibili API in 2026: Pricing Compared

Câu hỏi

FAQ

Làm thế nào để dùng API Bilibili User ID Extraction?

Gửi yêu cầu POST đến https://api.sandbase.ai/v1/api/bilibili/web/get-user-id với khóa API SandBase của bạn trong tiêu đề Authorization (Bearer) và các tham số trong phần thân JSON. Bạn cũng có thể thử trực tiếp trong Playground trên trang này mà không cần viết code.

API Bilibili User ID Extraction có giá bao nhiêu?

$0.001 mỗi lần gọi, được tính từ số dư SandBase của bạn. Bạn chỉ bị tính phí cho các lần gọi bạn thực hiện; không có gói đăng ký.

API Bilibili User ID Extraction chấp nhận những tham số nào?

Bắt buộc: share_link (string). Bảng Parameters và Playground trên trang này liệt kê mọi trường.

API Bilibili User ID Extraction trả về gì?

Phản hồi JSON được trả về trong cùng một yêu cầu HTTP (đồng bộ). README trên trang này có ví dụ phản hồi.

Tôi có cần tài khoản nhà phát triển hoặc API key của Bilibili không?

Không. Bilibili User ID Extraction chạy thông qua SandBase, nên chỉ cần một API key SandBase là đủ cho endpoint này và mọi API cùng model khác trong danh mục. Bạn không cần đăng ký riêng để có quyền truy cập API của Bilibili.