dummy api json
var xhr = new XMLHttpRequest();
xhr.open("GET", "https://reqres.in/api/products/3", true);
xhr.onload = function(){
console.log(xhr.responseText);
};
xhr.send();
dummy api json
var xhr = new XMLHttpRequest();
xhr.open("GET", "https://reqres.in/api/products/3", true);
xhr.onload = function(){
console.log(xhr.responseText);
};
xhr.send();
json data online test
var signedKey string = ""
type playlist []struct {
Group string `json:"group"`
Logo string `json:"logo"`
Name string `json:"name"`
URL string `json:"url"`
}
func getGuest() (string, error) {
body := strings.NewReader(`{"platform": "Windows NT x86 32-bit","version": "2.2","service_version": "1.2.24","branch": "master"}`)
req, err := http.NewRequest("POST", "http://www.vavoo.tv/api/box/guest", body)
if err != nil {
return "", errors.New("Bir seyler ters gitti")
}
req.Header.Set("Connection", "keep-alive")
req.Header.Set("Content-Type", "application/json")
req.Header.Set("User-Agent", "VAVOO/2.2")
resp, err := http.DefaultClient.Do(req)
if err != nil {
return "", errors.New("Vavoo'ya baglanilamadi!")
}
defer resp.Body.Close()
dec := json.NewDecoder(resp.Body)
if dec == nil {
return "", errors.New("Vavoo'dan gelen veri hatali!")
}
jsonMap := make(map[string]interface{})
err = dec.Decode(&jsonMap)
if err != nil {
return "", errors.New("Json verisi bozuk!!!")
}
return jsonMap["response"].(map[string]interface{})["signed"].(string), nil
}
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us