Sound
A sound with the number of posts using it.
GET
apiKeyheader
AuthorizationBearer <token>An API key from the dashboard: Authorization: Bearer sapi_….
url?stringIts link, or a share link.
id?stringIts id, instead of url.
maxAge?integerHow old a cached answer may be, in seconds; 0 always fetches. Default and most: the endpoint's cache lifetime.
Format
int64Range
0 <= valueThe answer.
application/json- response
One item, as every single-item endpoint answers: { "data": … }.
data*A sound.
import { SocialAPI } from "@socialapihq/sdk";const client = new SocialAPI({ apiKey: process.env.SOCIALAPI_API_KEY });const { data } = await client.douyin.sound({ id: "7711657555281382185" });Example Response
{ "data": { "id": "7711657555281382185", "title": "@野兽先生MrBeast创作的原声", "artist": "野兽先生MrBeast", "url": "https://www.douyin.com/music/7711657555281382185", "coverUrl": "https://p3-pc.douyinpic.com/aweme/1080x1080/aweme-avatar/tos-cn-avt-0015_b29d2aa6fae189e4b4242b03c4893dc4.jpeg?from=889713528", "playUrl": "https://sf11-cdn-tos.douyinstatic.com/obj/ies-music/7711657580631706431.mp3", "durationSeconds": 1254, "original": true, "posts": 162, "ext": { "ownerSecUid": "MS4wLjABAAAA5387Fmmln-gOAeC9xGyzE6khw7Az0K4knE1QGyGdjlZ2RoGkhnRAXLadkJTCF4IW", "ownerName": "野兽先生MrBeast", "album": null } }}