cURL
curl --request POST \
--url https://api.eka.care/connect-auth/v1/account/login \
--header 'Content-Type: application/json' \
--data '
{
"client_id": "<string>",
"client_secret": "<string>",
"sharing_key": "<string>"
}
'import requests
url = "https://api.eka.care/connect-auth/v1/account/login"
payload = {
"client_id": "<string>",
"client_secret": "<string>",
"sharing_key": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({client_id: '<string>', client_secret: '<string>', sharing_key: '<string>'})
};
fetch('https://api.eka.care/connect-auth/v1/account/login', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));HttpResponse<String> response = Unirest.post("https://api.eka.care/connect-auth/v1/account/login")
.header("Content-Type", "application/json")
.body("{\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"sharing_key\": \"<string>\"\n}")
.asString();using RestSharp;
var options = new RestClientOptions("https://api.eka.care/connect-auth/v1/account/login");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddJsonBody("{\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"sharing_key\": \"<string>\"\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
require 'uri'
require 'net/http'
url = URI("https://api.eka.care/connect-auth/v1/account/login")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"sharing_key\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"access_token": "<string>",
"expires_in": 123,
"refresh_expires_in": 123,
"refresh_token": "<string>"
}{
"code": 123,
"error": "<string>"
}{
"code": 123,
"error": "<string>"
}APIs
Connect Login
Authorization APIs to get access and refresh token
POST
/
connect-auth
/
v1
/
account
/
login
cURL
curl --request POST \
--url https://api.eka.care/connect-auth/v1/account/login \
--header 'Content-Type: application/json' \
--data '
{
"client_id": "<string>",
"client_secret": "<string>",
"sharing_key": "<string>"
}
'import requests
url = "https://api.eka.care/connect-auth/v1/account/login"
payload = {
"client_id": "<string>",
"client_secret": "<string>",
"sharing_key": "<string>"
}
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({client_id: '<string>', client_secret: '<string>', sharing_key: '<string>'})
};
fetch('https://api.eka.care/connect-auth/v1/account/login', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));HttpResponse<String> response = Unirest.post("https://api.eka.care/connect-auth/v1/account/login")
.header("Content-Type", "application/json")
.body("{\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"sharing_key\": \"<string>\"\n}")
.asString();using RestSharp;
var options = new RestClientOptions("https://api.eka.care/connect-auth/v1/account/login");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddJsonBody("{\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"sharing_key\": \"<string>\"\n}", false);
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
require 'uri'
require 'net/http'
url = URI("https://api.eka.care/connect-auth/v1/account/login")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"client_id\": \"<string>\",\n \"client_secret\": \"<string>\",\n \"sharing_key\": \"<string>\"\n}"
response = http.request(request)
puts response.read_body{
"access_token": "<string>",
"expires_in": 123,
"refresh_expires_in": 123,
"refresh_token": "<string>"
}{
"code": 123,
"error": "<string>"
}{
"code": 123,
"error": "<string>"
}Body
application/json
Was this page helpful?

