The Player endpoints provide information about all the people available such as fotball players,
coaches, referees, assistants and directors.
null
The endpoint /v2/players/:id
returns the details of one Player.
curl -G 'https://football.elenasport.io/v2/players/:id'
--header 'Authorization: ***Authorization***'
OkHttpClient client = new OkHttpClient();
Request request = new Request.Builder()
.url("https://football.elenasport.io/v2/players/:id?")
.get()
.addHeader("Authorization", "***Authorization***")
.build();
Response response = client.newCall(request).execute();
//Install "request" first: https://www.npmjs.com/package/request
var request = require("request");
var options = {
method: 'GET',
url: 'https://football.elenasport.io/v2/players/:id',
qs: {
},
headers: {
Authorization: '***Authorization***'
}
};
request(options, function(error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://football.elenasport.io/v2/players/:id?"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "***Authorization***")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}