Get task
curl --request GET \
--url https://api.dreamto.ai/api/v1/jobs/recordInfo \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.dreamto.ai/api/v1/jobs/recordInfo"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.dreamto.ai/api/v1/jobs/recordInfo', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.dreamto.ai/api/v1/jobs/recordInfo';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.dreamto.ai/api/v1/jobs/recordInfo"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.dreamto.ai/api/v1/jobs/recordInfo")
.header("Authorization", "Bearer <token>")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.dreamto.ai/api/v1/jobs/recordInfo",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}require 'uri'
require 'net/http'
url = URI("https://api.dreamto.ai/api/v1/jobs/recordInfo")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyusing RestSharp;
var options = new RestClientOptions("https://api.dreamto.ai/api/v1/jobs/recordInfo");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
import Foundation
let url = URL(string: "https://api.dreamto.ai/api/v1/jobs/recordInfo")!
var request = URLRequest(url: url)
request.httpMethod = "GET"
request.timeoutInterval = 10
request.allHTTPHeaderFields = ["Authorization": "Bearer <token>"]
let (data, _) = try await URLSession.shared.data(for: request)
print(String(decoding: data, as: UTF8.self))val client = OkHttpClient()
val request = Request.Builder()
.url("https://api.dreamto.ai/api/v1/jobs/recordInfo")
.get()
.addHeader("Authorization", "Bearer <token>")
.build()
val response = client.newCall(request).execute()false{
"code": 200,
"msg": "success",
"data": {
"taskId": "7d3f0a9c41e85b2f6a1c9e04b8d27f53",
"model": "ai-music-api/timeStamped-lyrics",
"state": "success",
"param": "{\"input\":\"{\\\"task_id\\\":\\\"c2a81e5f09d34b7e8f61a2d4c9b03e75\\\",\\\"audio_id\\\":\\\"f924248f-e765-48fd-9ea9-c64290225e4e\\\"}\",\"model\":\"ai-music-api/timeStamped-lyrics\"}",
"resultJson": "{\"code\":200,\"data\":{\"alignedWords\":[{\"endS\":6.251,\"palign\":0,\"startS\":5.572,\"success\":true,\"word\":\"[Verse]\\nKettle \"},{\"endS\":6.767,\"palign\":0,\"startS\":6.331,\"success\":true,\"word\":\"starts \"},{\"endS\":7.048,\"palign\":0,\"startS\":6.858,\"success\":true,\"word\":\"its \"},{\"endS\":7.412,\"palign\":0,\"startS\":7.10867,\"success\":true,\"word\":\"little \"},{\"endS\":10.234,\"palign\":0,\"startS\":7.53775,\"success\":true,\"word\":\"song\\n\"},{\"endS\":10.694,\"palign\":0,\"startS\":10.326,\"success\":true,\"word\":\"First \"},{\"endS\":11.023,\"palign\":0,\"startS\":10.7598,\"success\":true,\"word\":\"light \"},{\"endS\":11.55,\"palign\":0,\"startS\":11.0665,\"success\":true,\"word\":\"slips \"},{\"endS\":12.047,\"palign\":0,\"startS\":11.63,\"success\":true,\"word\":\"across \"},{\"endS\":12.151,\"palign\":0,\"startS\":12.08167,\"success\":true,\"word\":\"the \"},{\"endS\":14.99,\"palign\":0,\"startS\":12.231,\"success\":true,\"word\":\"floor\\n\"},{\"endS\":15.794,\"palign\":0,\"startS\":15.124,\"success\":true,\"word\":\"Coffee \"},{\"endS\":16.189,\"palign\":0,\"startS\":15.84767,\"success\":true,\"word\":\"warms \"},{\"endS\":16.426,\"palign\":0,\"startS\":16.3075,\"success\":true,\"word\":\"my \"},{\"endS\":16.913,\"palign\":0,\"startS\":16.5234,\"success\":true,\"word\":\"hands \"},{\"endS\":18.977,\"palign\":0,\"startS\":16.993,\"success\":true,\"word\":\"awake\\n\"},{\"endS\":19.186,\"palign\":0,\"startS\":19.04667,\"success\":true,\"word\":\"And \"},{\"endS\":19.209,\"palign\":0,\"startS\":19.209,\"success\":true,\"word\":\"I’\"},{\"endS\":19.3,\"palign\":0,\"startS\":19.3,\"success\":true,\"word\":\"m \"},{\"endS\":20.596,\"palign\":0,\"startS\":19.3705,\"success\":true,\"word\":\"ready \"},{\"endS\":21.254,\"palign\":0,\"startS\":20.68733,\"success\":true,\"word\":\"for \"},{\"endS\":21.657,\"palign\":0,\"startS\":21.33567,\"success\":true,\"word\":\"the \"},{\"endS\":23.30364,\"palign\":0,\"startS\":21.737,\"success\":true,\"word\":\"day\\n\\n\"},{\"endS\":23.572,\"palign\":0,\"startS\":23.32429,\"success\":true,\"word\":\"[Chorus]\\nGood \"},{\"endS\":24.24057,\"palign\":0,\"startS\":23.652,\"success\":true,\"word\":\"morning, \"},{\"endS\":25.3146,\"palign\":0,\"startS\":24.30914,\"success\":true,\"word\":\"coffee, \"},{\"endS\":25.58,\"palign\":0,\"startS\":25.3792,\"success\":true,\"word\":\"here \"},{\"endS\":25.879,\"palign\":0,\"startS\":25.713,\"success\":true,\"word\":\"we \"},{\"endS\":26.479,\"palign\":0,\"startS\":25.9735,\"success\":true,\"word\":\"go\\n\"},{\"endS\":26.721,\"palign\":0,\"startS\":26.55967,\"success\":true,\"word\":\"One \"},{\"endS\":27.122,\"palign\":0,\"startS\":26.8012,\"success\":true,\"word\":\"sweet \"},{\"endS\":27.474,\"palign\":0,\"startS\":27.219,\"success\":true,\"word\":\"sip \"},{\"endS\":27.648,\"palign\":0,\"startS\":27.532,\"success\":true,\"word\":\"and \"},{\"endS\":27.754,\"palign\":0,\"startS\":27.68333,\"success\":true,\"word\":\"the \"},{\"endS\":27.92,\"palign\":0,\"startS\":27.7872,\"success\":true,\"word\":\"whole \"},{\"endS\":28.127,\"palign\":0,\"startS\":27.9614,\"success\":true,\"word\":\"world \"},{\"endS\":28.603,\"palign\":0,\"startS\":28.2122,\"success\":true,\"word\":\"slows\\n\"},{\"endS\":28.676,\"palign\":0,\"startS\":28.676,\"success\":true,\"word\":\"A \"},{\"endS\":28.989,\"palign\":0,\"startS\":28.72817,\"success\":true,\"word\":\"little \"},{\"endS\":29.755,\"palign\":0,\"startS\":29.069,\"success\":true,\"word\":\"warmth, \"},{\"endS\":29.821,\"palign\":0,\"startS\":29.814,\"success\":true,\"word\":\"a \"},{\"endS\":30.155,\"palign\":0,\"startS\":29.87667,\"success\":true,\"word\":\"little \"},{\"endS\":31.172,\"palign\":0,\"startS\":30.235,\"success\":true,\"word\":\"cheer\\n\"},{\"endS\":31.32,\"palign\":0,\"startS\":31.22133,\"success\":true,\"word\":\"The \"},{\"endS\":31.682,\"palign\":0,\"startS\":31.4,\"success\":true,\"word\":\"best \"},{\"endS\":31.978,\"palign\":0,\"startS\":31.756,\"success\":true,\"word\":\"part \"},{\"endS\":32.212,\"palign\":0,\"startS\":32.095,\"success\":true,\"word\":\"of \"},{\"endS\":32.375,\"palign\":0,\"startS\":32.26633,\"success\":true,\"word\":\"the \"},{\"endS\":32.845,\"palign\":0,\"startS\":32.461,\"success\":true,\"word\":\"morning’\"},{\"endS\":32.966,\"palign\":0,\"startS\":32.845,\"success\":true,\"word\":\"s \"},{\"endS\":33.44077,\"palign\":0,\"startS\":33.046,\"success\":true,\"word\":\"here\\n\\n\"},{\"endS\":33.666,\"palign\":0,\"startS\":33.45954,\"success\":true,\"word\":\"[Outro]\\nGood \"},{\"endS\":35.00886,\"palign\":0,\"startS\":33.80814,\"success\":true,\"word\":\"morning, \"},{\"endS\":36.003,\"palign\":0,\"startS\":35.12171,\"success\":true,\"word\":\"coffee—\"},{\"endS\":37.222,\"palign\":0,\"startS\":36.064,\"success\":true,\"word\":\"cheers \"},{\"endS\":38.233,\"palign\":0,\"startS\":37.33,\"success\":true,\"word\":\"to \"},{\"endS\":38.633,\"palign\":0,\"startS\":38.283,\"success\":true,\"word\":\"today!\\n\\n\"}],\"hootCer\":0.13354037267080746,\"isStreamed\":false,\"waveformData\":[0.03921,0.042,0.14231,0.07978,0.1271,0.1338,0.1161,0.07379,0.14826,0.11464,0.10707,0.12289,0.12867,0.11005,0.15521,0.14257,0.08681,0.13299,0.10376,0.0655,0.17031,0.13765,0.09706,0.13877,0.1445,0.10997,0.16552,0.06776,0.14401,0.05294,0.09462,0.03653,0.13162,0.06203,0.03195,0.07127,0.05616,0.07417,0.17361,0.10552,0.07141,0.15769,0.12946,0.0318,0.16121,0.09698,0.07977,0.15267,0.11826,0.08754,0.13318,0.16784,0.12225,0.1582,0.16358,0.11264,0.14274,0.10626,0.1646,0.12499,0.10507,0.16573,0.10775,0.09432,0.14843,0.12468,0.11594,0.15176,0.09407,0.09275,0.16788,0.1229,0.08759,0.15516,0.06744,0.18092,0.15881,0.12822,0.14747,0.15771,0.12355,0.15528,0.15759,0.10866,0.16633,0.15793,0.11238,0.07244,0.12049,0.09743,0.04789,0.14094,0.09711,0.05894,0.13504,0.17007,0.13561,0.17944,0.15072,0.11431,0.16237,0.13407,0.0375,0.1863,0.17109,0.12549,0.20227,0.18268,0.14493,0.13877,0.0408,0.00572,0.0424,0.03635,0.02827,0.04178,0.16115,0.12979,0.18068,0.12722,0.09202,0.21949,0.16684,0.10537,0.14156,0.11702,0.17286,0.17384,0.12236,0.18403,0.13038,0.15996,0.1914,0.12345,0.17428,0.14387,0.10668,0.16412,0.17227,0.16836,0.13185,0.21113,0.12514,0.18471,0.18463,0.13519,0.1178,0.16417,0.15503,0.17738,0.17046,0.14984,0.13764,0.19865,0.11756,0.17746,0.1853,0.06969,0.18937,0.1536,0.08994,0.1702,0.14348,0.1231,0.08852,0.11792,0.1172,0.15881,0.19988,0.16097,0.11771,0.16529,0.14008,0.08217,0.19893,0.16976,0.10817,0.19101,0.16041,0.06946,0.21022,0.15399,0.13147,0.12156,0.11861,0.04905,0.21561,0.12779,0.06127,0.09679,0.10473,0.13224,0.17145,0.12297,0.09158,0.08816,0.13668,0.15981,0.19648,0.19476,0.15573,0.18581,0.05853,0.01248,0.00419]},\"msg\":\"success\"}",
"failCode": null,
"failMsg": null,
"costTime": 42,
"completeTime": 1795014939000,
"createTime": 1795014897000,
"updateTime": 1795014939000,
"response": {
"code": 200,
"data": {
"alignedWords": [
{
"endS": 6.251,
"palign": 0,
"startS": 5.572,
"success": true,
"word": "[Verse]\nKettle "
},
{
"endS": 6.767,
"palign": 0,
"startS": 6.331,
"success": true,
"word": "starts "
},
{
"endS": 7.048,
"palign": 0,
"startS": 6.858,
"success": true,
"word": "its "
},
{
"endS": 7.412,
"palign": 0,
"startS": 7.10867,
"success": true,
"word": "little "
},
{
"endS": 10.234,
"palign": 0,
"startS": 7.53775,
"success": true,
"word": "song\n"
},
{
"endS": 10.694,
"palign": 0,
"startS": 10.326,
"success": true,
"word": "First "
},
{
"endS": 11.023,
"palign": 0,
"startS": 10.7598,
"success": true,
"word": "light "
},
{
"endS": 11.55,
"palign": 0,
"startS": 11.0665,
"success": true,
"word": "slips "
},
{
"endS": 12.047,
"palign": 0,
"startS": 11.63,
"success": true,
"word": "across "
},
{
"endS": 12.151,
"palign": 0,
"startS": 12.08167,
"success": true,
"word": "the "
},
{
"endS": 14.99,
"palign": 0,
"startS": 12.231,
"success": true,
"word": "floor\n"
},
{
"endS": 15.794,
"palign": 0,
"startS": 15.124,
"success": true,
"word": "Coffee "
},
{
"endS": 16.189,
"palign": 0,
"startS": 15.84767,
"success": true,
"word": "warms "
},
{
"endS": 16.426,
"palign": 0,
"startS": 16.3075,
"success": true,
"word": "my "
},
{
"endS": 16.913,
"palign": 0,
"startS": 16.5234,
"success": true,
"word": "hands "
},
{
"endS": 18.977,
"palign": 0,
"startS": 16.993,
"success": true,
"word": "awake\n"
},
{
"endS": 19.186,
"palign": 0,
"startS": 19.04667,
"success": true,
"word": "And "
},
{
"endS": 19.209,
"palign": 0,
"startS": 19.209,
"success": true,
"word": "I’"
},
{
"endS": 19.3,
"palign": 0,
"startS": 19.3,
"success": true,
"word": "m "
},
{
"endS": 20.596,
"palign": 0,
"startS": 19.3705,
"success": true,
"word": "ready "
},
{
"endS": 21.254,
"palign": 0,
"startS": 20.68733,
"success": true,
"word": "for "
},
{
"endS": 21.657,
"palign": 0,
"startS": 21.33567,
"success": true,
"word": "the "
},
{
"endS": 23.30364,
"palign": 0,
"startS": 21.737,
"success": true,
"word": "day\n\n"
},
{
"endS": 23.572,
"palign": 0,
"startS": 23.32429,
"success": true,
"word": "[Chorus]\nGood "
},
{
"endS": 24.24057,
"palign": 0,
"startS": 23.652,
"success": true,
"word": "morning, "
},
{
"endS": 25.3146,
"palign": 0,
"startS": 24.30914,
"success": true,
"word": "coffee, "
},
{
"endS": 25.58,
"palign": 0,
"startS": 25.3792,
"success": true,
"word": "here "
},
{
"endS": 25.879,
"palign": 0,
"startS": 25.713,
"success": true,
"word": "we "
},
{
"endS": 26.479,
"palign": 0,
"startS": 25.9735,
"success": true,
"word": "go\n"
},
{
"endS": 26.721,
"palign": 0,
"startS": 26.55967,
"success": true,
"word": "One "
},
{
"endS": 27.122,
"palign": 0,
"startS": 26.8012,
"success": true,
"word": "sweet "
},
{
"endS": 27.474,
"palign": 0,
"startS": 27.219,
"success": true,
"word": "sip "
},
{
"endS": 27.648,
"palign": 0,
"startS": 27.532,
"success": true,
"word": "and "
},
{
"endS": 27.754,
"palign": 0,
"startS": 27.68333,
"success": true,
"word": "the "
},
{
"endS": 27.92,
"palign": 0,
"startS": 27.7872,
"success": true,
"word": "whole "
},
{
"endS": 28.127,
"palign": 0,
"startS": 27.9614,
"success": true,
"word": "world "
},
{
"endS": 28.603,
"palign": 0,
"startS": 28.2122,
"success": true,
"word": "slows\n"
},
{
"endS": 28.676,
"palign": 0,
"startS": 28.676,
"success": true,
"word": "A "
},
{
"endS": 28.989,
"palign": 0,
"startS": 28.72817,
"success": true,
"word": "little "
},
{
"endS": 29.755,
"palign": 0,
"startS": 29.069,
"success": true,
"word": "warmth, "
},
{
"endS": 29.821,
"palign": 0,
"startS": 29.814,
"success": true,
"word": "a "
},
{
"endS": 30.155,
"palign": 0,
"startS": 29.87667,
"success": true,
"word": "little "
},
{
"endS": 31.172,
"palign": 0,
"startS": 30.235,
"success": true,
"word": "cheer\n"
},
{
"endS": 31.32,
"palign": 0,
"startS": 31.22133,
"success": true,
"word": "The "
},
{
"endS": 31.682,
"palign": 0,
"startS": 31.4,
"success": true,
"word": "best "
},
{
"endS": 31.978,
"palign": 0,
"startS": 31.756,
"success": true,
"word": "part "
},
{
"endS": 32.212,
"palign": 0,
"startS": 32.095,
"success": true,
"word": "of "
},
{
"endS": 32.375,
"palign": 0,
"startS": 32.26633,
"success": true,
"word": "the "
},
{
"endS": 32.845,
"palign": 0,
"startS": 32.461,
"success": true,
"word": "morning’"
},
{
"endS": 32.966,
"palign": 0,
"startS": 32.845,
"success": true,
"word": "s "
},
{
"endS": 33.44077,
"palign": 0,
"startS": 33.046,
"success": true,
"word": "here\n\n"
},
{
"endS": 33.666,
"palign": 0,
"startS": 33.45954,
"success": true,
"word": "[Outro]\nGood "
},
{
"endS": 35.00886,
"palign": 0,
"startS": 33.80814,
"success": true,
"word": "morning, "
},
{
"endS": 36.003,
"palign": 0,
"startS": 35.12171,
"success": true,
"word": "coffee—"
},
{
"endS": 37.222,
"palign": 0,
"startS": 36.064,
"success": true,
"word": "cheers "
},
{
"endS": 38.233,
"palign": 0,
"startS": 37.33,
"success": true,
"word": "to "
},
{
"endS": 38.633,
"palign": 0,
"startS": 38.283,
"success": true,
"word": "today!\n\n"
}
],
"hootCer": 0.13354037267080746,
"isStreamed": false,
"waveformData": [
0.03921,
0.042,
0.14231,
0.07978,
0.1271,
0.1338,
0.1161,
0.07379,
0.14826,
0.11464,
0.10707,
0.12289,
0.12867,
0.11005,
0.15521,
0.14257,
0.08681,
0.13299,
0.10376,
0.0655,
0.17031,
0.13765,
0.09706,
0.13877,
0.1445,
0.10997,
0.16552,
0.06776,
0.14401,
0.05294,
0.09462,
0.03653,
0.13162,
0.06203,
0.03195,
0.07127,
0.05616,
0.07417,
0.17361,
0.10552,
0.07141,
0.15769,
0.12946,
0.0318,
0.16121,
0.09698,
0.07977,
0.15267,
0.11826,
0.08754,
0.13318,
0.16784,
0.12225,
0.1582,
0.16358,
0.11264,
0.14274,
0.10626,
0.1646,
0.12499,
0.10507,
0.16573,
0.10775,
0.09432,
0.14843,
0.12468,
0.11594,
0.15176,
0.09407,
0.09275,
0.16788,
0.1229,
0.08759,
0.15516,
0.06744,
0.18092,
0.15881,
0.12822,
0.14747,
0.15771,
0.12355,
0.15528,
0.15759,
0.10866,
0.16633,
0.15793,
0.11238,
0.07244,
0.12049,
0.09743,
0.04789,
0.14094,
0.09711,
0.05894,
0.13504,
0.17007,
0.13561,
0.17944,
0.15072,
0.11431,
0.16237,
0.13407,
0.0375,
0.1863,
0.17109,
0.12549,
0.20227,
0.18268,
0.14493,
0.13877,
0.0408,
0.00572,
0.0424,
0.03635,
0.02827,
0.04178,
0.16115,
0.12979,
0.18068,
0.12722,
0.09202,
0.21949,
0.16684,
0.10537,
0.14156,
0.11702,
0.17286,
0.17384,
0.12236,
0.18403,
0.13038,
0.15996,
0.1914,
0.12345,
0.17428,
0.14387,
0.10668,
0.16412,
0.17227,
0.16836,
0.13185,
0.21113,
0.12514,
0.18471,
0.18463,
0.13519,
0.1178,
0.16417,
0.15503,
0.17738,
0.17046,
0.14984,
0.13764,
0.19865,
0.11756,
0.17746,
0.1853,
0.06969,
0.18937,
0.1536,
0.08994,
0.1702,
0.14348,
0.1231,
0.08852,
0.11792,
0.1172,
0.15881,
0.19988,
0.16097,
0.11771,
0.16529,
0.14008,
0.08217,
0.19893,
0.16976,
0.10817,
0.19101,
0.16041,
0.06946,
0.21022,
0.15399,
0.13147,
0.12156,
0.11861,
0.04905,
0.21561,
0.12779,
0.06127,
0.09679,
0.10473,
0.13224,
0.17145,
0.12297,
0.09158,
0.08816,
0.13668,
0.15981,
0.19648,
0.19476,
0.15573,
0.18581,
0.05853,
0.01248,
0.00419
]
},
"msg": "success"
}
}
}Get timestamped lyrics
Get timestamped lyrics: Get task
Returns the state and result of a task by taskId. When data.state is success, read the result from data.response (the same as data.resultJson); when it is fail, data.failCode / data.failMsg give the reason. Poll about every 10 seconds.
GET
/
api
/
v1
/
jobs
/
recordInfo
Get task
curl --request GET \
--url https://api.dreamto.ai/api/v1/jobs/recordInfo \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.dreamto.ai/api/v1/jobs/recordInfo"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.dreamto.ai/api/v1/jobs/recordInfo', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));const url = 'https://api.dreamto.ai/api/v1/jobs/recordInfo';
const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch(url, options)
.then(res => res.json())
.then(json => console.log(json))
.catch(err => console.error(err));package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.dreamto.ai/api/v1/jobs/recordInfo"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.dreamto.ai/api/v1/jobs/recordInfo")
.header("Authorization", "Bearer <token>")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.dreamto.ai/api/v1/jobs/recordInfo",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}require 'uri'
require 'net/http'
url = URI("https://api.dreamto.ai/api/v1/jobs/recordInfo")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_bodyusing RestSharp;
var options = new RestClientOptions("https://api.dreamto.ai/api/v1/jobs/recordInfo");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddHeader("Authorization", "Bearer <token>");
var response = await client.GetAsync(request);
Console.WriteLine("{0}", response.Content);
import Foundation
let url = URL(string: "https://api.dreamto.ai/api/v1/jobs/recordInfo")!
var request = URLRequest(url: url)
request.httpMethod = "GET"
request.timeoutInterval = 10
request.allHTTPHeaderFields = ["Authorization": "Bearer <token>"]
let (data, _) = try await URLSession.shared.data(for: request)
print(String(decoding: data, as: UTF8.self))val client = OkHttpClient()
val request = Request.Builder()
.url("https://api.dreamto.ai/api/v1/jobs/recordInfo")
.get()
.addHeader("Authorization", "Bearer <token>")
.build()
val response = client.newCall(request).execute()false{
"code": 200,
"msg": "success",
"data": {
"taskId": "7d3f0a9c41e85b2f6a1c9e04b8d27f53",
"model": "ai-music-api/timeStamped-lyrics",
"state": "success",
"param": "{\"input\":\"{\\\"task_id\\\":\\\"c2a81e5f09d34b7e8f61a2d4c9b03e75\\\",\\\"audio_id\\\":\\\"f924248f-e765-48fd-9ea9-c64290225e4e\\\"}\",\"model\":\"ai-music-api/timeStamped-lyrics\"}",
"resultJson": "{\"code\":200,\"data\":{\"alignedWords\":[{\"endS\":6.251,\"palign\":0,\"startS\":5.572,\"success\":true,\"word\":\"[Verse]\\nKettle \"},{\"endS\":6.767,\"palign\":0,\"startS\":6.331,\"success\":true,\"word\":\"starts \"},{\"endS\":7.048,\"palign\":0,\"startS\":6.858,\"success\":true,\"word\":\"its \"},{\"endS\":7.412,\"palign\":0,\"startS\":7.10867,\"success\":true,\"word\":\"little \"},{\"endS\":10.234,\"palign\":0,\"startS\":7.53775,\"success\":true,\"word\":\"song\\n\"},{\"endS\":10.694,\"palign\":0,\"startS\":10.326,\"success\":true,\"word\":\"First \"},{\"endS\":11.023,\"palign\":0,\"startS\":10.7598,\"success\":true,\"word\":\"light \"},{\"endS\":11.55,\"palign\":0,\"startS\":11.0665,\"success\":true,\"word\":\"slips \"},{\"endS\":12.047,\"palign\":0,\"startS\":11.63,\"success\":true,\"word\":\"across \"},{\"endS\":12.151,\"palign\":0,\"startS\":12.08167,\"success\":true,\"word\":\"the \"},{\"endS\":14.99,\"palign\":0,\"startS\":12.231,\"success\":true,\"word\":\"floor\\n\"},{\"endS\":15.794,\"palign\":0,\"startS\":15.124,\"success\":true,\"word\":\"Coffee \"},{\"endS\":16.189,\"palign\":0,\"startS\":15.84767,\"success\":true,\"word\":\"warms \"},{\"endS\":16.426,\"palign\":0,\"startS\":16.3075,\"success\":true,\"word\":\"my \"},{\"endS\":16.913,\"palign\":0,\"startS\":16.5234,\"success\":true,\"word\":\"hands \"},{\"endS\":18.977,\"palign\":0,\"startS\":16.993,\"success\":true,\"word\":\"awake\\n\"},{\"endS\":19.186,\"palign\":0,\"startS\":19.04667,\"success\":true,\"word\":\"And \"},{\"endS\":19.209,\"palign\":0,\"startS\":19.209,\"success\":true,\"word\":\"I’\"},{\"endS\":19.3,\"palign\":0,\"startS\":19.3,\"success\":true,\"word\":\"m \"},{\"endS\":20.596,\"palign\":0,\"startS\":19.3705,\"success\":true,\"word\":\"ready \"},{\"endS\":21.254,\"palign\":0,\"startS\":20.68733,\"success\":true,\"word\":\"for \"},{\"endS\":21.657,\"palign\":0,\"startS\":21.33567,\"success\":true,\"word\":\"the \"},{\"endS\":23.30364,\"palign\":0,\"startS\":21.737,\"success\":true,\"word\":\"day\\n\\n\"},{\"endS\":23.572,\"palign\":0,\"startS\":23.32429,\"success\":true,\"word\":\"[Chorus]\\nGood \"},{\"endS\":24.24057,\"palign\":0,\"startS\":23.652,\"success\":true,\"word\":\"morning, \"},{\"endS\":25.3146,\"palign\":0,\"startS\":24.30914,\"success\":true,\"word\":\"coffee, \"},{\"endS\":25.58,\"palign\":0,\"startS\":25.3792,\"success\":true,\"word\":\"here \"},{\"endS\":25.879,\"palign\":0,\"startS\":25.713,\"success\":true,\"word\":\"we \"},{\"endS\":26.479,\"palign\":0,\"startS\":25.9735,\"success\":true,\"word\":\"go\\n\"},{\"endS\":26.721,\"palign\":0,\"startS\":26.55967,\"success\":true,\"word\":\"One \"},{\"endS\":27.122,\"palign\":0,\"startS\":26.8012,\"success\":true,\"word\":\"sweet \"},{\"endS\":27.474,\"palign\":0,\"startS\":27.219,\"success\":true,\"word\":\"sip \"},{\"endS\":27.648,\"palign\":0,\"startS\":27.532,\"success\":true,\"word\":\"and \"},{\"endS\":27.754,\"palign\":0,\"startS\":27.68333,\"success\":true,\"word\":\"the \"},{\"endS\":27.92,\"palign\":0,\"startS\":27.7872,\"success\":true,\"word\":\"whole \"},{\"endS\":28.127,\"palign\":0,\"startS\":27.9614,\"success\":true,\"word\":\"world \"},{\"endS\":28.603,\"palign\":0,\"startS\":28.2122,\"success\":true,\"word\":\"slows\\n\"},{\"endS\":28.676,\"palign\":0,\"startS\":28.676,\"success\":true,\"word\":\"A \"},{\"endS\":28.989,\"palign\":0,\"startS\":28.72817,\"success\":true,\"word\":\"little \"},{\"endS\":29.755,\"palign\":0,\"startS\":29.069,\"success\":true,\"word\":\"warmth, \"},{\"endS\":29.821,\"palign\":0,\"startS\":29.814,\"success\":true,\"word\":\"a \"},{\"endS\":30.155,\"palign\":0,\"startS\":29.87667,\"success\":true,\"word\":\"little \"},{\"endS\":31.172,\"palign\":0,\"startS\":30.235,\"success\":true,\"word\":\"cheer\\n\"},{\"endS\":31.32,\"palign\":0,\"startS\":31.22133,\"success\":true,\"word\":\"The \"},{\"endS\":31.682,\"palign\":0,\"startS\":31.4,\"success\":true,\"word\":\"best \"},{\"endS\":31.978,\"palign\":0,\"startS\":31.756,\"success\":true,\"word\":\"part \"},{\"endS\":32.212,\"palign\":0,\"startS\":32.095,\"success\":true,\"word\":\"of \"},{\"endS\":32.375,\"palign\":0,\"startS\":32.26633,\"success\":true,\"word\":\"the \"},{\"endS\":32.845,\"palign\":0,\"startS\":32.461,\"success\":true,\"word\":\"morning’\"},{\"endS\":32.966,\"palign\":0,\"startS\":32.845,\"success\":true,\"word\":\"s \"},{\"endS\":33.44077,\"palign\":0,\"startS\":33.046,\"success\":true,\"word\":\"here\\n\\n\"},{\"endS\":33.666,\"palign\":0,\"startS\":33.45954,\"success\":true,\"word\":\"[Outro]\\nGood \"},{\"endS\":35.00886,\"palign\":0,\"startS\":33.80814,\"success\":true,\"word\":\"morning, \"},{\"endS\":36.003,\"palign\":0,\"startS\":35.12171,\"success\":true,\"word\":\"coffee—\"},{\"endS\":37.222,\"palign\":0,\"startS\":36.064,\"success\":true,\"word\":\"cheers \"},{\"endS\":38.233,\"palign\":0,\"startS\":37.33,\"success\":true,\"word\":\"to \"},{\"endS\":38.633,\"palign\":0,\"startS\":38.283,\"success\":true,\"word\":\"today!\\n\\n\"}],\"hootCer\":0.13354037267080746,\"isStreamed\":false,\"waveformData\":[0.03921,0.042,0.14231,0.07978,0.1271,0.1338,0.1161,0.07379,0.14826,0.11464,0.10707,0.12289,0.12867,0.11005,0.15521,0.14257,0.08681,0.13299,0.10376,0.0655,0.17031,0.13765,0.09706,0.13877,0.1445,0.10997,0.16552,0.06776,0.14401,0.05294,0.09462,0.03653,0.13162,0.06203,0.03195,0.07127,0.05616,0.07417,0.17361,0.10552,0.07141,0.15769,0.12946,0.0318,0.16121,0.09698,0.07977,0.15267,0.11826,0.08754,0.13318,0.16784,0.12225,0.1582,0.16358,0.11264,0.14274,0.10626,0.1646,0.12499,0.10507,0.16573,0.10775,0.09432,0.14843,0.12468,0.11594,0.15176,0.09407,0.09275,0.16788,0.1229,0.08759,0.15516,0.06744,0.18092,0.15881,0.12822,0.14747,0.15771,0.12355,0.15528,0.15759,0.10866,0.16633,0.15793,0.11238,0.07244,0.12049,0.09743,0.04789,0.14094,0.09711,0.05894,0.13504,0.17007,0.13561,0.17944,0.15072,0.11431,0.16237,0.13407,0.0375,0.1863,0.17109,0.12549,0.20227,0.18268,0.14493,0.13877,0.0408,0.00572,0.0424,0.03635,0.02827,0.04178,0.16115,0.12979,0.18068,0.12722,0.09202,0.21949,0.16684,0.10537,0.14156,0.11702,0.17286,0.17384,0.12236,0.18403,0.13038,0.15996,0.1914,0.12345,0.17428,0.14387,0.10668,0.16412,0.17227,0.16836,0.13185,0.21113,0.12514,0.18471,0.18463,0.13519,0.1178,0.16417,0.15503,0.17738,0.17046,0.14984,0.13764,0.19865,0.11756,0.17746,0.1853,0.06969,0.18937,0.1536,0.08994,0.1702,0.14348,0.1231,0.08852,0.11792,0.1172,0.15881,0.19988,0.16097,0.11771,0.16529,0.14008,0.08217,0.19893,0.16976,0.10817,0.19101,0.16041,0.06946,0.21022,0.15399,0.13147,0.12156,0.11861,0.04905,0.21561,0.12779,0.06127,0.09679,0.10473,0.13224,0.17145,0.12297,0.09158,0.08816,0.13668,0.15981,0.19648,0.19476,0.15573,0.18581,0.05853,0.01248,0.00419]},\"msg\":\"success\"}",
"failCode": null,
"failMsg": null,
"costTime": 42,
"completeTime": 1795014939000,
"createTime": 1795014897000,
"updateTime": 1795014939000,
"response": {
"code": 200,
"data": {
"alignedWords": [
{
"endS": 6.251,
"palign": 0,
"startS": 5.572,
"success": true,
"word": "[Verse]\nKettle "
},
{
"endS": 6.767,
"palign": 0,
"startS": 6.331,
"success": true,
"word": "starts "
},
{
"endS": 7.048,
"palign": 0,
"startS": 6.858,
"success": true,
"word": "its "
},
{
"endS": 7.412,
"palign": 0,
"startS": 7.10867,
"success": true,
"word": "little "
},
{
"endS": 10.234,
"palign": 0,
"startS": 7.53775,
"success": true,
"word": "song\n"
},
{
"endS": 10.694,
"palign": 0,
"startS": 10.326,
"success": true,
"word": "First "
},
{
"endS": 11.023,
"palign": 0,
"startS": 10.7598,
"success": true,
"word": "light "
},
{
"endS": 11.55,
"palign": 0,
"startS": 11.0665,
"success": true,
"word": "slips "
},
{
"endS": 12.047,
"palign": 0,
"startS": 11.63,
"success": true,
"word": "across "
},
{
"endS": 12.151,
"palign": 0,
"startS": 12.08167,
"success": true,
"word": "the "
},
{
"endS": 14.99,
"palign": 0,
"startS": 12.231,
"success": true,
"word": "floor\n"
},
{
"endS": 15.794,
"palign": 0,
"startS": 15.124,
"success": true,
"word": "Coffee "
},
{
"endS": 16.189,
"palign": 0,
"startS": 15.84767,
"success": true,
"word": "warms "
},
{
"endS": 16.426,
"palign": 0,
"startS": 16.3075,
"success": true,
"word": "my "
},
{
"endS": 16.913,
"palign": 0,
"startS": 16.5234,
"success": true,
"word": "hands "
},
{
"endS": 18.977,
"palign": 0,
"startS": 16.993,
"success": true,
"word": "awake\n"
},
{
"endS": 19.186,
"palign": 0,
"startS": 19.04667,
"success": true,
"word": "And "
},
{
"endS": 19.209,
"palign": 0,
"startS": 19.209,
"success": true,
"word": "I’"
},
{
"endS": 19.3,
"palign": 0,
"startS": 19.3,
"success": true,
"word": "m "
},
{
"endS": 20.596,
"palign": 0,
"startS": 19.3705,
"success": true,
"word": "ready "
},
{
"endS": 21.254,
"palign": 0,
"startS": 20.68733,
"success": true,
"word": "for "
},
{
"endS": 21.657,
"palign": 0,
"startS": 21.33567,
"success": true,
"word": "the "
},
{
"endS": 23.30364,
"palign": 0,
"startS": 21.737,
"success": true,
"word": "day\n\n"
},
{
"endS": 23.572,
"palign": 0,
"startS": 23.32429,
"success": true,
"word": "[Chorus]\nGood "
},
{
"endS": 24.24057,
"palign": 0,
"startS": 23.652,
"success": true,
"word": "morning, "
},
{
"endS": 25.3146,
"palign": 0,
"startS": 24.30914,
"success": true,
"word": "coffee, "
},
{
"endS": 25.58,
"palign": 0,
"startS": 25.3792,
"success": true,
"word": "here "
},
{
"endS": 25.879,
"palign": 0,
"startS": 25.713,
"success": true,
"word": "we "
},
{
"endS": 26.479,
"palign": 0,
"startS": 25.9735,
"success": true,
"word": "go\n"
},
{
"endS": 26.721,
"palign": 0,
"startS": 26.55967,
"success": true,
"word": "One "
},
{
"endS": 27.122,
"palign": 0,
"startS": 26.8012,
"success": true,
"word": "sweet "
},
{
"endS": 27.474,
"palign": 0,
"startS": 27.219,
"success": true,
"word": "sip "
},
{
"endS": 27.648,
"palign": 0,
"startS": 27.532,
"success": true,
"word": "and "
},
{
"endS": 27.754,
"palign": 0,
"startS": 27.68333,
"success": true,
"word": "the "
},
{
"endS": 27.92,
"palign": 0,
"startS": 27.7872,
"success": true,
"word": "whole "
},
{
"endS": 28.127,
"palign": 0,
"startS": 27.9614,
"success": true,
"word": "world "
},
{
"endS": 28.603,
"palign": 0,
"startS": 28.2122,
"success": true,
"word": "slows\n"
},
{
"endS": 28.676,
"palign": 0,
"startS": 28.676,
"success": true,
"word": "A "
},
{
"endS": 28.989,
"palign": 0,
"startS": 28.72817,
"success": true,
"word": "little "
},
{
"endS": 29.755,
"palign": 0,
"startS": 29.069,
"success": true,
"word": "warmth, "
},
{
"endS": 29.821,
"palign": 0,
"startS": 29.814,
"success": true,
"word": "a "
},
{
"endS": 30.155,
"palign": 0,
"startS": 29.87667,
"success": true,
"word": "little "
},
{
"endS": 31.172,
"palign": 0,
"startS": 30.235,
"success": true,
"word": "cheer\n"
},
{
"endS": 31.32,
"palign": 0,
"startS": 31.22133,
"success": true,
"word": "The "
},
{
"endS": 31.682,
"palign": 0,
"startS": 31.4,
"success": true,
"word": "best "
},
{
"endS": 31.978,
"palign": 0,
"startS": 31.756,
"success": true,
"word": "part "
},
{
"endS": 32.212,
"palign": 0,
"startS": 32.095,
"success": true,
"word": "of "
},
{
"endS": 32.375,
"palign": 0,
"startS": 32.26633,
"success": true,
"word": "the "
},
{
"endS": 32.845,
"palign": 0,
"startS": 32.461,
"success": true,
"word": "morning’"
},
{
"endS": 32.966,
"palign": 0,
"startS": 32.845,
"success": true,
"word": "s "
},
{
"endS": 33.44077,
"palign": 0,
"startS": 33.046,
"success": true,
"word": "here\n\n"
},
{
"endS": 33.666,
"palign": 0,
"startS": 33.45954,
"success": true,
"word": "[Outro]\nGood "
},
{
"endS": 35.00886,
"palign": 0,
"startS": 33.80814,
"success": true,
"word": "morning, "
},
{
"endS": 36.003,
"palign": 0,
"startS": 35.12171,
"success": true,
"word": "coffee—"
},
{
"endS": 37.222,
"palign": 0,
"startS": 36.064,
"success": true,
"word": "cheers "
},
{
"endS": 38.233,
"palign": 0,
"startS": 37.33,
"success": true,
"word": "to "
},
{
"endS": 38.633,
"palign": 0,
"startS": 38.283,
"success": true,
"word": "today!\n\n"
}
],
"hootCer": 0.13354037267080746,
"isStreamed": false,
"waveformData": [
0.03921,
0.042,
0.14231,
0.07978,
0.1271,
0.1338,
0.1161,
0.07379,
0.14826,
0.11464,
0.10707,
0.12289,
0.12867,
0.11005,
0.15521,
0.14257,
0.08681,
0.13299,
0.10376,
0.0655,
0.17031,
0.13765,
0.09706,
0.13877,
0.1445,
0.10997,
0.16552,
0.06776,
0.14401,
0.05294,
0.09462,
0.03653,
0.13162,
0.06203,
0.03195,
0.07127,
0.05616,
0.07417,
0.17361,
0.10552,
0.07141,
0.15769,
0.12946,
0.0318,
0.16121,
0.09698,
0.07977,
0.15267,
0.11826,
0.08754,
0.13318,
0.16784,
0.12225,
0.1582,
0.16358,
0.11264,
0.14274,
0.10626,
0.1646,
0.12499,
0.10507,
0.16573,
0.10775,
0.09432,
0.14843,
0.12468,
0.11594,
0.15176,
0.09407,
0.09275,
0.16788,
0.1229,
0.08759,
0.15516,
0.06744,
0.18092,
0.15881,
0.12822,
0.14747,
0.15771,
0.12355,
0.15528,
0.15759,
0.10866,
0.16633,
0.15793,
0.11238,
0.07244,
0.12049,
0.09743,
0.04789,
0.14094,
0.09711,
0.05894,
0.13504,
0.17007,
0.13561,
0.17944,
0.15072,
0.11431,
0.16237,
0.13407,
0.0375,
0.1863,
0.17109,
0.12549,
0.20227,
0.18268,
0.14493,
0.13877,
0.0408,
0.00572,
0.0424,
0.03635,
0.02827,
0.04178,
0.16115,
0.12979,
0.18068,
0.12722,
0.09202,
0.21949,
0.16684,
0.10537,
0.14156,
0.11702,
0.17286,
0.17384,
0.12236,
0.18403,
0.13038,
0.15996,
0.1914,
0.12345,
0.17428,
0.14387,
0.10668,
0.16412,
0.17227,
0.16836,
0.13185,
0.21113,
0.12514,
0.18471,
0.18463,
0.13519,
0.1178,
0.16417,
0.15503,
0.17738,
0.17046,
0.14984,
0.13764,
0.19865,
0.11756,
0.17746,
0.1853,
0.06969,
0.18937,
0.1536,
0.08994,
0.1702,
0.14348,
0.1231,
0.08852,
0.11792,
0.1172,
0.15881,
0.19988,
0.16097,
0.11771,
0.16529,
0.14008,
0.08217,
0.19893,
0.16976,
0.10817,
0.19101,
0.16041,
0.06946,
0.21022,
0.15399,
0.13147,
0.12156,
0.11861,
0.04905,
0.21561,
0.12779,
0.06127,
0.09679,
0.10473,
0.13224,
0.17145,
0.12297,
0.09158,
0.08816,
0.13668,
0.15981,
0.19648,
0.19476,
0.15573,
0.18581,
0.05853,
0.01248,
0.00419
]
},
"msg": "success"
}
}
}Authorizations
Query Parameters
Response
200 - application/json
Always HTTP 200. With code 200, data is the task (whether the task succeeded is data.state); any other code is an error with data null.
Response of recordInfo; always HTTP 200.
Result code:
200: found (whether the task succeeded isdata.state)401: missing or invalid API Key405: wrong HTTP method422:taskIdis missing, unknown, belongs to another account or has expired (msgisrecordInfo is null)429: too many requests500: server error; retry later

