Skip to content

Kuaishou User Published Videos API (V2) ​

GET
API health status
Healthy Available Limited Mostly unavailable No data
Loading health status...

Retrieve public videos published by a Kuaishou user, with optional cursor-based pagination. Use it to review a creator's content history or select videos for detail and comment requests.

Parameters ​

NameInTypeRequiredDefaultDescription
tokenquerystringYes-Access token for this API service.
userIdquerystringYes-The unique user ID on Kuaishou.
pcursorquerystringNo-Pagination cursor for subsequent pages.

Code Samples ​

bash
curl --max-time 120 -X GET 'https://api.justoneapi.com/api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE'
text
I want to use the "User Published Videos (V2)" API from JustOneAPI.
Base URL: https://api.justoneapi.com.
API Path: /api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE
API Endpoint: BASE_URL + /api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE
HTTP Method: GET
Authentication: Append the "token" query parameter to the URL.
OpenAPI Definition: https://docs.justoneapi.com/openapi/kuaishou/user-published-videos-v2-en.json

Parameters:
- token (query): Access token for this API service. (Required)
- userId (query): The unique user ID on Kuaishou. (Required)
- pcursor (query): Pagination cursor for subsequent pages.

Return format: safely handle JSON or text according to the actual Content-Type.

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 the request timeout to 120 seconds. If 120 seconds is too long for your use case, use at least 60 seconds, but a small number of requests may time out before receiving a result.
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
   - 602: Token Budget Exceeded
4. Code 601 means the shared account balance is insufficient. Code 602 means the current API token's own cumulative budget limit has been reached. Token budget limits do not transfer funds out of the shared account balance.

Please help me write a script in my preferred programming language to call this API and handle the response.
python
import requests

BASE_URL = "https://api.justoneapi.com"  # Provided by OpenAPI servers

url = BASE_URL + "/api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE"
response = requests.get(url, timeout=120)
print(response.status_code)
if response.content:
    content_type = response.headers.get("content-type", "").lower()
    if "json" in content_type:
        try:
            print(response.json())
        except ValueError:
            print(response.text)
    elif content_type.startswith("text/") or "xml" in content_type or content_type.split(";", 1)[0].strip() in {"application/javascript", "application/x-www-form-urlencoded", "application/graphql"}:
        print(response.text)
    else:
        with open("response.bin", "wb") as output:
            output.write(response.content)
        print(f"Saved {len(response.content)} bytes to response.bin")
js
const BASE_URL = "https://api.justoneapi.com"; // Provided by OpenAPI servers
const url = BASE_URL + "/api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE";

const response = await fetch(url, {
  method: "GET",
  signal: AbortSignal.timeout(120000)
});
console.log(response.status);
const responseBytes = await response.arrayBuffer();
if (responseBytes.byteLength) {
  const contentType = (response.headers.get("content-type") || "").toLowerCase();
  const mediaType = contentType.split(";", 1)[0].trim();
  const textual = contentType.startsWith("text/") || contentType.includes("json") || contentType.includes("xml") || ["application/javascript", "application/x-www-form-urlencoded", "application/graphql"].includes(mediaType);
  if (textual) {
    const responseText = new TextDecoder().decode(responseBytes);
    let data = responseText;
    if (contentType.includes("json")) {
      try { data = JSON.parse(responseText); } catch { /* Keep the raw body. */ }
    }
    console.log(data);
  } else {
    console.log(`Received ${responseBytes.byteLength} binary bytes`);
  }
}
java
import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
import java.time.Duration;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Path;

public class Main {
    public static void main(String[] args) throws Exception {
        final String BASE_URL = "https://api.justoneapi.com"; // Provided by OpenAPI servers
        final String url = BASE_URL + "/api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE";

        HttpClient client = HttpClient.newBuilder().connectTimeout(Duration.ofSeconds(120)).build();
        HttpRequest.Builder builder = HttpRequest.newBuilder()
            .uri(URI.create(url))
            .timeout(Duration.ofSeconds(120))
            .method("GET", HttpRequest.BodyPublishers.noBody());

        HttpRequest request = builder.build();

        HttpResponse<byte[]> response = client.send(request, HttpResponse.BodyHandlers.ofByteArray());
        System.out.println(response.statusCode());
        String contentType = response.headers().firstValue("content-type").orElse("").toLowerCase();
        String mediaType = contentType.split(";", 2)[0].trim();
        if (contentType.startsWith("text/") || contentType.contains("json") || contentType.contains("xml") || mediaType.equals("application/javascript") || mediaType.equals("application/x-www-form-urlencoded") || mediaType.equals("application/graphql")) {
            System.out.println(new String(response.body(), StandardCharsets.UTF_8));
        } else {
            Files.write(Path.of("response.bin"), response.body());
            System.out.println("Saved " + response.body().length + " bytes to response.bin");
        }
    }
}
go
package main

import (
	"fmt"
	"io"
	"os"
	"strings"
	"net/http"
	"time"
)

const BASE_URL = "https://api.justoneapi.com" // Provided by OpenAPI servers

func main() {
	client := &http.Client{Timeout: 120 * time.Second}
	url := BASE_URL + "/api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE"
	req, _ := http.NewRequest("GET", url, nil)
	resp, _ := client.Do(req)
	defer resp.Body.Close()
	fmt.Println(resp.StatusCode)
	bodyBytes, _ := io.ReadAll(resp.Body)
	contentType := strings.ToLower(resp.Header.Get("Content-Type"))
	mediaType := strings.TrimSpace(strings.SplitN(contentType, ";", 2)[0])
	if strings.HasPrefix(contentType, "text/") || strings.Contains(contentType, "json") || strings.Contains(contentType, "xml") || mediaType == "application/javascript" || mediaType == "application/x-www-form-urlencoded" || mediaType == "application/graphql" {
		fmt.Println(string(bodyBytes))
	} else {
		os.WriteFile("response.bin", bodyBytes, 0600)
		fmt.Printf("Saved %d bytes to response.bin\n", len(bodyBytes))
	}
}
php
<?php
$BASE_URL = 'https://api.justoneapi.com'; // Provided by OpenAPI servers
$url = $BASE_URL . '/api/kuaishou/get-user-video-list/v2?token=YOUR_API_KEY&userId=VALUE';

$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_TIMEOUT, 120);
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, "GET");
$response = curl_exec($ch);
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
$contentType = strtolower((string) curl_getinfo($ch, CURLINFO_CONTENT_TYPE));
curl_close($ch);
echo $status . PHP_EOL;
$mediaType = trim(explode(';', $contentType, 2)[0]);
if (str_starts_with($contentType, 'text/') || str_contains($contentType, 'json') || str_contains($contentType, 'xml') || in_array($mediaType, ['application/javascript', 'application/x-www-form-urlencoded', 'application/graphql'], true)) {
    echo $response;
} else {
    file_put_contents('response.bin', $response);
    echo 'Saved ' . strlen($response) . ' bytes to response.bin' . PHP_EOL;
}

Response Fields ​

Key fields in a successful response (code = 0).

Posts and pagination3 fields

data

A page of public posts for the requested Kuaishou account.

FieldTypeDescription
resultintegerResult code reported with the listing data.
feedsarrayPosts on the current page. This list can be empty.
pcursorstringPass a returned cursor unchanged as pcursor with the same userId to request the next page. The value no_more means there is no next page.
Post information10 fields

data.feeds[]

One post returned for the account.

FieldTypeDescription
photo_idintegerKuaishou post ID. This integer can exceed JavaScript's safe integer range. Use lossless JSON parsing to preserve all digits.
captionstringCaption of the post.
typeintegerType code reported for the post.
photo_statusintegerStatus code reported for the post.
timestampintegerPublication timestamp in milliseconds since the Unix epoch.
timestringPublication time as display text.
durationintegerDuration in milliseconds reported on the post.
longVideobooleanIndicates whether the post is marked as a long video.
hasVotebooleanIndicates whether the post has a poll.
hasMusicTagbooleanIndicates whether the post has a music tag.
Publishing account9 fields

data.feeds[]

FieldTypeDescription
user_idintegerNumeric ID of the account that published the post.
user_namestringDisplay name of the account that published the post.
user_sexstringGender value shown for the author.
kwaiIdstringPublic Kuaishou account handle reported for the author. The userId query uses the numeric account ID.
verifiedbooleanVerification indicator reported for the author.
headurlsarrayAuthor avatar image sources.
headurls[]objectOne author avatar image source.
headurls[].cdnstringCDN label for this media source.
headurls[].urlstringAuthor avatar image URL.
Engagement and comments9 fields

data.feeds[]

FieldTypeDescription
like_countintegerReported like count for the post.
comment_countintegerReported number of comments on the post.
view_countintegerReported number of views on the post.
collect_countintegerReported collection count for the post.
share_countintegerReported share count for the post.
forward_countintegerReported forward count for the post.
commentInfoobjectComment settings reported for the post.
commentInfo.permissionsintegerReported comment permission code.
enableShareToStorybooleanIndicates whether the post is marked as shareable to Stories.
Covers and playback12 fields

data.feeds[]

FieldTypeDescription
cover_thumbnail_urlsarrayThumbnail image sources for the post cover.
cover_thumbnail_urls[]objectOne cover thumbnail source.
cover_thumbnail_urls[].cdnstringCDN label for this media source.
cover_thumbnail_urls[].urlstringCover thumbnail image URL.
ff_cover_thumbnail_urlsarrayAlternate cover thumbnail image sources reported for the post.
ff_cover_thumbnail_urls[]objectOne alternate cover thumbnail source.
ff_cover_thumbnail_urls[].cdnstringCDN label for this media source.
ff_cover_thumbnail_urls[].urlstringAlternate cover thumbnail image URL.
main_mv_urlsarrayPrimary video playback sources.
main_mv_urls[]objectOne primary video playback source.
main_mv_urls[].cdnstringCDN label for this media source.
main_mv_urls[].urlstringPrimary video playback URL.
Video rendition metadata19 fields

data.feeds[].streamManifest

Technical metadata for the video stream.

FieldTypeDescription
mediaTypeintegerMedia type code in the stream metadata.
videoIdstringVideo identifier in the stream metadata.
adaptationSetarrayGroups of available video renditions.
adaptationSet[]objectOne group of video renditions.
adaptationSet[].idintegerIdentifier of the rendition group.
adaptationSet[].durationintegerDuration in milliseconds reported for this rendition group.
adaptationSet[].representationarrayAvailable video renditions in this group.
adaptationSet[].representation[]objectTechnical metadata for one video rendition.
adaptationSet[].representation[].idintegerIdentifier of this video rendition.
adaptationSet[].representation[].widthintegerVideo rendition width in pixels.
adaptationSet[].representation[].heightintegerVideo rendition height in pixels.
adaptationSet[].representation[].frameRatenumberFrame rate of this video rendition, in frames per second.
adaptationSet[].representation[].maxBitrateintegerMaximum bitrate reported for this rendition.
adaptationSet[].representation[].avgBitrateintegerAverage bitrate reported for this rendition.
adaptationSet[].representation[].qualityintegerQuality code for this video rendition.
adaptationSet[].representation[].qualityTypestringQuality type for this video rendition.
adaptationSet[].representation[].qualityLabelstringDisplay label for the rendition quality.
adaptationSet[].representation[].hdrTypeintegerHDR type code for this rendition.
adaptationSet[].representation[].mutebooleanIndicates whether this rendition is marked as muted.
Soundtrack information11 fields

data.feeds[].soundTrack

Soundtrack metadata attached to the post.

FieldTypeDescription
idstringSoundtrack ID.
namestringSoundtrack title.
artiststringArtist name reported for the soundtrack.
durationintegerDuration reported for the soundtrack.
photoIdintegerPost ID associated with the soundtrack. This integer can exceed JavaScript's safe integer range.
typeintegerType code reported for the soundtrack.
audioTypeintegerAudio type code reported for the soundtrack.
genreIdintegerGenre identifier reported for the soundtrack.
loudnessnumberLoudness value reported for the soundtrack.
isOfflinebooleanIndicates whether the soundtrack is marked offline.
hasCopyrightbooleanCopyright indicator reported for the soundtrack.
Soundtrack account and media21 fields

data.feeds[].soundTrack

FieldTypeDescription
userobjectAccount information associated with the soundtrack.
user.user_idintegerNumeric ID of the account associated with the soundtrack.
user.user_namestringDisplay name of the account associated with the soundtrack.
user.kwaiIdstringPublic Kuaishou account handle reported for the soundtrack account.
user.headurlstringAvatar image URL for the soundtrack account.
user.headurlsarrayAvatar image sources for the soundtrack account.
user.headurls[]objectOne avatar image source for the soundtrack account.
user.headurls[].cdnstringCDN label for this media source.
user.headurls[].urlstringAvatar image URL for the soundtrack account.
imageUrlsarrayImage sources for the soundtrack.
imageUrls[]objectOne soundtrack image source.
imageUrls[].cdnstringCDN label for this media source.
imageUrls[].urlstringSoundtrack image URL.
avatarUrlsarrayAvatar image sources reported in the soundtrack metadata.
avatarUrls[]objectOne avatar image source in the soundtrack metadata.
avatarUrls[].cdnstringCDN label for this media source.
avatarUrls[].urlstringAvatar image URL reported in the soundtrack metadata.
audioUrlsarrayAudio sources for the soundtrack.
audioUrls[]objectOne soundtrack audio source.
audioUrls[].cdnstringCDN label for this media source.
audioUrls[].urlstringSoundtrack audio URL.
Promotional display7 fields

data.feeds[].ad

Promotional information attached to some posts.

FieldTypeDescription
titlestringPromotional title.
merchantTitlestringMerchant title reported for the promotion.
merchantDescriptionstringMerchant description reported for the promotion.
merchantEnhanceDisplayobjectAdditional merchant display information for the promotion.
merchantEnhanceDisplay.merchantDisplayTitleInfostringMerchant title display text.
merchantEnhanceDisplay.merchantDisplayPriceInfostringMerchant price display text.
merchantEnhanceDisplay.merchantSaleInfostringMerchant sales display text.

Response Example ​

Loading the response example...