API Documentation

TikTok User Posts API

Query public TikTok data synchronously; empty results and failures are free.

Test API

Results return directly in the same request; no task submission or polling is needed.

Open product page and API Tester

Endpoint and authentication

GET https://api.goanyapi.com/api/v1/tiktok/user-posts

Authenticate with Authorization: Bearer YOUR_API_KEY. Supply query-string parameters; there is no request body.

Input parameters

ParameterTypeLocationRequiredConstraints / defaultDescription
AuthorizationstringHeaderYesBearer YOUR_API_KEYAPI key for the current account
usernamestringQueryOne of two^[A-Za-z0-9._]+$Username. Example: spidey.glow. Supply the username without @.
urlstringQueryOne of two^https://(www\.)?tiktok\.com/@[A-Za-z0-9._]+/?(?:\?[^#\s]*)?(?:#[^\s]*)?$Full TikTok profile URL. Example: https://www.tiktok.com/@spidey.glow. Supply either url or username, never both. Sharing parameters and fragments are removed. Short links are unsupported. URL resolution adds no separate credit charge.
cursorstringQueryNoDefault: 0Collection cursor. Use nextCursor only when returned; never infer an offset.
countintegerQueryNoDefault: 15; Fixed: 15Fixed page size 15; actual returned records may be fewer.

Full URL supported: https://www.tiktok.com/@spidey.glow. Supply either url or username, never both. Sharing parameters, fragments and trailing slashes are removed; short links are unsupported. URL format handling adds no separate charge.

Supply either url or username=spidey.glow, never both. Accepts a profile URL or username without @. No ID lookup is required. Identifier handling is automatic and adds no separate charge. Only the final non-empty successful posts result is billed once; empty results and failures are free. Keep the URL or name unchanged and update cursor for subsequent pages. Replace legacy sec_uid inputs with a URL or name.

Query by name:

GET /api/v1/tiktok/user-posts?username=spidey.glow&cursor=0
Authorization: Bearer YOUR_API_KEY

Request example

GET /api/v1/tiktok/user-posts?url=https%3A%2F%2Fwww.tiktok.com%2F%40spidey.glow&cursor=0&count=15
Authorization: Bearer YOUR_API_KEY

Output parameters

Success returns HTTP 200. Null, empty and missing business fields are preserved; a zero statistic is valid. Only documented public fields are returned.

FieldTypeDescription
codestringok on success
messagestringRequest message
data.creditsUsednumberCredits charged for this request; zero for empty results
data.remainingCreditsnumberAccount balance after settlement
data.itemsarrayPosts on this page; [] for empty results
data.hasMorebooleanWhether more records are reported; does not guarantee a cursor
data.nextCursorstring | nullReturned next cursor, or null when unavailable; never invent a cursor even when hasMore=true
data.pageSizeintegerFixed requested maximum 15
data.items[].idstringPost ID
data.items[].descstringPost description
data.items[].createTimenumberUnix timestamp in seconds
data.items[].isAdbooleanAdvertisement indicator
data.items[].authorobjectAuthor information
data.items[].statsobjectEngagement statistics
data.items[].statsV2objectString statistics
data.items[].videoobjectVideo media information
data.items[].author.idstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.uniqueIdstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.nicknamestring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.signaturestring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.secUidstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.avatarThumbstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.avatarMediumstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.avatarLargerstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.verifiedstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.privateAccountstring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].author.createTimestring | number | boolean | nullReturned public author field; may be absent or empty
data.items[].video.idstring | number | nullReturned public media field; may be absent or empty
data.items[].video.descstring | number | nullReturned public media field; may be absent or empty
data.items[].video.createTimestring | number | nullReturned public media field; may be absent or empty
data.items[].video.durationstring | number | nullReturned public media field; may be absent or empty
data.items[].video.widthstring | number | nullReturned public media field; may be absent or empty
data.items[].video.heightstring | number | nullReturned public media field; may be absent or empty
data.items[].video.ratiostring | number | nullReturned public media field; may be absent or empty
data.items[].video.coverstring | number | nullReturned public media field; may be absent or empty
data.items[].video.originCoverstring | number | nullReturned public media field; may be absent or empty
data.items[].video.dynamicCoverstring | number | nullReturned public media field; may be absent or empty
data.items[].video.playAddrstring | number | nullReturned public media field; may be absent or empty
data.items[].video.downloadAddrstring | number | nullReturned public media field; may be absent or empty
data.items[].stats.diggCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.shareCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.commentCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.playCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.collectCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.followerCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.followingCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.heartCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.heartnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.videoCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.friendCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].stats.viewCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.diggCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.shareCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.commentCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.playCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.collectCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.followerCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.followingCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.heartCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.heartnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.videoCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.friendCountnumber | string | nullReturned statistic; may be absent or empty
data.items[].statsV2.viewCountnumber | string | nullReturned statistic; may be absent or empty

Real response example

Saved from a real successful response and projected to public fields. Lists show only the first two records. Account balance and request charges are omitted; live responses also contain creditsUsed and remainingCredits based on current configuration. Displaying the example sends no query and charges no credits.

{
  "code": "ok",
  "message": "ok",
  "data": {
    "items": [
      {
        "id": "7688000247930309920",
        "desc": "Comment “CHRISTMAS” if you need this 🎄👇 #christmas #christmasgift #christmasdecor #santa #christmasiscoming ",
        "createTime": 1790002051,
        "isAd": false,
        "author": {
          "id": "7672400417817625622",
          "uniqueId": "spidey.glow",
          "nickname": "SpideyGlow",
          "signature": "",
          "secUid": "MS4wLjABAAAAK4RIcIbr3DY__BALfxpDu7FXrXMdNIkck5Zzt7ScvdWxtGgRjeLDOCixGr4nFQrG",
          "avatarThumb": "https://p19-common-sign.tiktokcdn-us.com/tos-useast2a-avt-0068-euttp/58cb4b19080af86926f621f3ced3a91d~tplv-tiktokx-cropcenter:100:100.jpeg?dr=9640&refresh_token=4babe6a8&x-expires=1794646800&x-signature=L1xXQL6lgzSEukL%2FUee7vsdWmGY%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
          "avatarMedium": "https://p19-common-sign.tiktokcdn-us.com/tos-useast2a-avt-0068-euttp/58cb4b19080af86926f621f3ced3a91d~tplv-tiktokx-cropcenter:720:720.jpeg?dr=9640&refresh_token=3c32fc27&x-expires=1794646800&x-signature=oCM8plBfPRp69Viiu7KrbRfYko8%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
          "avatarLarger": "https://p16-common-sign.tiktokcdn-us.com/tos-useast2a-avt-0068-euttp/58cb4b19080af86926f621f3ced3a91d~tplv-tiktokx-cropcenter:1080:1080.jpeg?dr=9640&refresh_token=77a532ec&x-expires=1794646800&x-signature=VNupCvmJLvBS4NlYIIyGjijt9gw%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
          "verified": false,
          "privateAccount": false
        },
        "stats": {
          "diggCount": 642,
          "shareCount": 461,
          "commentCount": 53,
          "playCount": 59100,
          "collectCount": 168
        },
        "statsV2": {
          "diggCount": "642",
          "shareCount": "461",
          "commentCount": "53",
          "playCount": "59100",
          "collectCount": "168"
        },
        "video": {
          "id": "7688000247930309920",
          "duration": 13,
          "width": 576,
          "height": 1024,
          "ratio": "540p",
          "cover": "https://p16-common-sign.tiktokcdn-us.com/tos-useast2a-p-0037-euttp/ogYaBfX3DDOqF4LEUxEQUrE4sBmIVAxQfORwLA~tplv-tiktokx-origin.image?dr=9636&x-expires=1794646800&x-signature=w0nOvfJTYcRbdvZaG4mZ69AbI9Y%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
          "originCover": "https://p16-common-sign.tiktokcdn-us.com/tos-useast2a-p-0037-euttp/oQSLImED8VfDxfRBQqUxEXAI4PFS3RAsLUBXlQ~tplv-tiktokx-origin.image?dr=9636&x-expires=1794646800&x-signature=DG1c21HZZMtlEoyXBSg9Qq9Ae%2F0%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
          "dynamicCover": "https://p16-common-sign.tiktokcdn-us.com/tos-useast2a-p-0037-euttp/o0IlXRBq4sxQLFx3fAaD4QCEmXDfAUVaLIC3EU~tplv-tiktokx-origin.image?dr=9636&x-expires=1794646800&x-signature=sRsNqDjDrRjkRI2XcK993VzBToM%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
          "playAddr": "https://v16-webapp-prime.us.tiktok.com/video/tos/useast2a/tos-useast2a-ve-0068c001-euttp/ocLsDffUEEbmE4QXVQqQFB3xIWRUA3xA6D3BL6/?a=1988&bti=ODszNWYuMDE6&&bt=1131&ft=aEeq8qT0mIoPD12zEwZI3wUpyjAbMeF~O5&mime_type=video_mp4&rc=M2QzZjk0ZmRkZzUzNjtoOkBpM3Fpd3k5cm9uZDMzZjczNUAvLzUuLWA1NjQxLjYwMGJjYSMtL21eMmQ0MmxhLS1kMTNzcw%3D%3D&expire=1794648924&l=2026111209351141FBC8FD2946BE013520&ply_type=2&policy=2&signature=c01baf5c6aac64ca6541ef107b59f63f&tk=tt_chain_token&btag=e000b0000",
          "downloadAddr": "https://video-useast5-bp.us.tiktok.com/dce8044a8c76dc4460f55572e45776bc/6af82b5c/kmoat/mps/logo/v2/r/p/v26044gc0000daok5l7og65vatpf2n00/8535125446364b0cbb8058ad7ef9d972/06e56f18f2b4636c145cb9d8da38976f/mp4/main.mp4?a=1988&bti=ODszNWYuMDE6&&bt=0&eid=1286&ft=aERFuqT0mIoPD12zEwZI3wUpyjAbMeF~O5&mime_type=video_mp4&rc=cnF8b2hsc2d3SkBwaHIxaDFybndmNTw8aGc7M2VmZTk5NzU4OEBpM3Fpd3k5cm9uZDMzZjczNUBjRl5Nc3FePmJKYSNvYF90aHFmOiM0YWM0XjI1Xy0xMDEyLjA1YSMtL21eMmQ0MmxhLS1kMTNzcw%3D%3D&definition=720p&du=14&item_id=7688000247930309920&l=2026111209351141FBC8FD2946BE013520&logo_type=tiktok_m&ply_type=2&policy=eyJ2bSI6MiwiY2siOiJ0dF9jaGFpbl90b2tlbiJ9&user_text=spidey.glow&btag=e000b0000"
        }
      },
      {
        "id": "7687843512632528161",
        "desc": "Comment “SANTA” if you need one 🤭🎄 #christmas #christmasiscoming #projector #merrychristmas #christmasdecor ",
        "createTime": 1789965567,
        "isAd": false,
        "author": {
          "id": "7672400417817625622",
          "uniqueId": "spidey.glow",
          "nickname": "SpideyGlow",
          "signature": "",
          "secUid": "MS4wLjABAAAAK4RIcIbr3DY__BALfxpDu7FXrXMdNIkck5Zzt7ScvdWxtGgRjeLDOCixGr4nFQrG",
          "avatarThumb": "https://p19-common-sign.tiktokcdn-us.com/tos-useast2a-avt-0068-euttp/58cb4b19080af86926f621f3ced3a91d~tplv-tiktokx-cropcenter:100:100.jpeg?dr=9640&refresh_token=4babe6a8&x-expires=1794646800&x-signature=L1xXQL6lgzSEukL%2FUee7vsdWmGY%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
          "avatarMedium": "https://p19-common-sign.tiktokcdn-us.com/tos-useast2a-avt-0068-euttp/58cb4b19080af86926f621f3ced3a91d~tplv-tiktokx-cropcenter:720:720.jpeg?dr=9640&refresh_token=3c32fc27&x-expires=1794646800&x-signature=oCM8plBfPRp69Viiu7KrbRfYko8%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
          "avatarLarger": "https://p16-common-sign.tiktokcdn-us.com/tos-useast2a-avt-0068-euttp/58cb4b19080af86926f621f3ced3a91d~tplv-tiktokx-cropcenter:1080:1080.jpeg?dr=9640&refresh_token=77a532ec&x-expires=1794646800&x-signature=VNupCvmJLvBS4NlYIIyGjijt9gw%3D&t=4d5b0474&ps=13740610&shp=a5d48078&shcp=81f88b70&idc=useast5",
          "verified": false,
          "privateAccount": false
        },
        "stats": {
          "diggCount": 108,
          "shareCount": 27,
          "commentCount": 17,
          "playCount": 5767,
          "collectCount": 13
        },
        "statsV2": {
          "diggCount": "108",
          "shareCount": "27",
          "commentCount": "17",
          "playCount": "5767",
          "collectCount": "13"
        },
        "video": {
          "id": "7687843512632528161",
          "duration": 9,
          "width": 576,
          "height": 1024,
          "ratio": "540p",
          "cover": "https://p16-common-sign.tiktokcdn-us.com/tos-useast2a-p-0037-euttp/o8IApiB8BQ1fW3WEP1ZoAWzwFrECIxrEBFtXio~tplv-tiktokx-origin.image?dr=9636&x-expires=1794646800&x-signature=RnI25S2wTHkLKEzZQttmswXpMzc%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
          "originCover": "https://p19-common-sign.tiktokcdn-us.com/tos-useast2a-p-0037-euttp/o0QCBW1zQIAFXwFQrltpwfBHWoi3EABG1IEIai~tplv-tiktokx-origin.image?dr=9636&x-expires=1794646800&x-signature=4oZwWWrK2Wk4ZpVJ4%2Fcsq6nTJ9c%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
          "dynamicCover": "https://p19-common-sign.tiktokcdn-us.com/tos-useast2a-p-0037-euttp/oUqFuDfEnQsQqrsmIQBTRWASfgQFFJE4Du6Ltw~tplv-tiktokx-origin.image?dr=9636&x-expires=1794646800&x-signature=bj8jvxvtg0LS5uIOWS%2BD%2BjJV7NQ%3D&t=4d5b0474&ps=13740610&shp=81f88b70&shcp=43f4a2f9&idc=useast5",
          "playAddr": "https://v16-webapp-prime.us.tiktok.com/video/tos/useast2a/tos-useast2a-ve-0068-euttp/o0yICt4WiiAEcWQoEIPBz1ErFXtBp31wWBQfAQ/?a=1988&bti=ODszNWYuMDE6&&bt=1433&ft=aEeq8qT0mIoPD12zEwZI3wUpyjAbMeF~O5&mime_type=video_mp4&rc=OzszNTM8PDM3MzY6aTRnOkBpM3FsN3E5cnRlZDMzZjczNUAxLi80YGJiXi0xLjAyNDJgYSNfai0vMmRzNmxhLS1kMTNzcw%3D%3D&expire=1794648920&l=2026111209351141FBC8FD2946BE013520&ply_type=2&policy=2&signature=e73b2540a51c975b4489271861123d93&tk=tt_chain_token&btag=e000b0000",
          "downloadAddr": "https://video-useast5-bp.us.tiktok.com/cece39029f9aa1a6349408a737a67286/6af82b58/kmoat/mps/logo/v2/r/p/v26044gc0000daob9qvog65n240imnb0/b4b2a72c7ac54ccb9b154ad7c3246382/647807a59c16252074d53c7c9485ea45/mp4/main.mp4?a=1988&bti=ODszNWYuMDE6&&bt=0&eid=1286&ft=aERFuqT0mIoPD12zEwZI3wUpyjAbMeF~O5&mime_type=video_mp4&rc=cnF8b2hsc2d3SkBwaHIxaDFybndmNTY3NjpkOGVlZjhkZjo1N0BpM3FsN3E5cnRlZDMzZjczNUBjRl5Nc3FePmJKYSNvYF90aHFmOiM1My9gYTEuNmAxYDQvXl9fYSNfai0vMmRzNmxhLS1kMTNzcw%3D%3D&definition=720p&du=10&item_id=7687843512632528161&l=2026111209351141FBC8FD2946BE013520&logo_type=tiktok_m&ply_type=2&policy=eyJ2bSI6MiwiY2siOiJ0dF9jaGFpbl90b2tlbiJ9&user_text=spidey.glow&btag=e000b0000"
        }
      }
    ],
    "hasMore": true,
    "nextCursor": "1788892633304",
    "pageSize": 15
  }
}

Pagination

Each request asks for up to 15 records. Actual counts may be smaller. Continue only when hasMore=true and nextCursor is a valid string; pass it as cursor. Never infer an offset from record counts. When hasMore=true but nextCursor=null, this response cannot supply a subsequent page. Each next page is a separate billed request; pages are not fetched automatically.

Billing

With the current configuration, each successful request costs 1 credit.

Non-empty successful results use the currently configured rate; empty results and failures are free. Sufficient balance is required before requesting. A concurrent settlement with insufficient balance also returns 402 without delivering unsettled paid results. Empty or null details and lists without meaningful records are empty; individual empty fields do not make a populated result empty.

Errors

400: invalid parameters; 401: invalid authentication; 402: insufficient credits; 429: rate limit; 502: request failed; 503: API or pricing not configured. Errors contain code and message without internal addresses or credentials.

{"code":"invalid_params","message":"Invalid parameter"}