{
  "openapi": "3.0.1",
  "info": {
    "title": "NetEase Cloud Music Comments Scraper 网易云音乐",
    "description": "Scrape NetEase Cloud Music (网易云音乐) song comments: text, likes, reply threads, commenter nickname and avatar, and timestamps. Input a song URL or ID. No browser needed, uses the site's own comment API directly.",
    "version": "1.0",
    "x-build-id": "5EjGzMs3rBBglhOas"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/getascraper~netease-music-comments-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-getascraper-netease-music-comments-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/getascraper~netease-music-comments-scraper/runs": {
      "post": {
        "operationId": "runs-sync-getascraper-netease-music-comments-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/getascraper~netease-music-comments-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-getascraper-netease-music-comments-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "songUrls": {
            "title": "Song URLs",
            "type": "array",
            "description": "NetEase Cloud Music song page URLs, e.g. 'https://music.163.com/song?id=186016'. Leave empty if using Song IDs.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "songIds": {
            "title": "Song IDs",
            "type": "array",
            "description": "Numeric NetEase song IDs (the 'id=' part of a song URL), e.g. '186016'.",
            "items": {
              "type": "string"
            },
            "default": []
          },
          "sortType": {
            "title": "Comment sort order",
            "enum": [
              "1",
              "2",
              "3"
            ],
            "type": "string",
            "description": "How to order the top-level comments pulled for each song. Hottest comments are usually the most useful for sentiment/NLP work; Time order is best for incremental 'what's new' monitoring together with 'Stop at comment ID' below. Hot comments (top pinned picks) are always included regardless of this setting.",
            "default": "2"
          },
          "maxCommentsPerSong": {
            "title": "Max comments per song",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Cap on top-level comments returned per song (0 = as many as the API will return in one pass). Popular songs can have millions of comments; this keeps runs predictable and affordable.",
            "default": 200
          },
          "includeReplies": {
            "title": "Include reply threads",
            "type": "boolean",
            "description": "Fetch nested replies for every top-level comment that has replies. Adds one extra request per replied-to comment, so it costs more on songs with deep threads.",
            "default": false
          },
          "maxRepliesPerComment": {
            "title": "Max replies per comment",
            "minimum": 0,
            "maximum": 10000,
            "type": "integer",
            "description": "Cap on nested replies fetched per top-level comment (0 = all available). Only applies when 'Include reply threads' is on.",
            "default": 20
          },
          "sinceCommentId": {
            "title": "Stop at comment ID (incremental runs)",
            "type": "string",
            "description": "For monitoring a song's comments over time: paste the newest comment ID you already collected on a previous run. Pagination stops as soon as this ID is seen again, so you only get comments newer than it. Works best with Comment sort order set to Time. Leave empty for a full pull.",
            "default": ""
          },
          "fetchSongTitle": {
            "title": "Fetch song title & artist",
            "type": "boolean",
            "description": "Look up the song's title and artist from its page and attach them to every comment row. Adds one extra plain HTML request per song.",
            "default": true
          },
          "maxItems": {
            "title": "Maximum total comments",
            "minimum": 0,
            "maximum": 1000000,
            "type": "integer",
            "description": "Hard cap on total rows (comments + replies) across all songs in this run (0 = unlimited).",
            "default": 500
          },
          "debugLogging": {
            "title": "Verbose debug logs",
            "type": "boolean",
            "description": "Print a log line for every single comment/reply emitted, not just per page.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy setup",
            "type": "object",
            "description": "No IP-reputation gating was observed against the comment API during testing, so Datacenter proxies (the default) are fast and cheap. Switch to Residential only if you start seeing blocked or empty responses on a large run.",
            "default": {
              "useApifyProxy": true
            }
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}