Dyqan Online për mbushje elektronike
https://www.rimbushe.com/api/sms
Invoke-WebRequest -Method POST `
-Headers @{"Authorization" = "Bearer ***************************d0c1e"} `
-ContentType "application/json" `
-Uri https://www.rimbushe.com/api/sms/send `
-Body '{
"from": "Kompaniajuaj",
"to": "38349123456" ,
"body": "Ky është mesazh testues nga Rimbushe.com"
}'
curl -X POST \
-H "Authorization: Bearer ***************************akop1" \
-H "Content-Type: application/json" -d '
{
"from": "Kompaniajuaj",
"to": 38349123456,
"message": "Ky është mesazh testues nga Rimbushe.com"
}' \
"https://www.rimbushe.com/api/sms/send"
using (var client = new WebClient()){
client.Headers[HttpRequestHeader.Authorization] = $"Bearer ***************************akop1";
client.Headers[HttpRequestHeader.ContentType] = "application/json";
//Deklaroje nje anonymous object sa për test - rekomandohet ta keni një klasë të veçantë për SMS Message
var smsMsg = new { from = "Kompaniajuaj", to = 38349123456, message = "Ky është mesazh testues nga Rimbushe.com" };
//Mund ta përdorni Newtonsoft JsonConvert për ta konvertuar klasën e sipërme ne json
var payload = JsonConvert.SerializeObject(smsMsg);
//Mesazhi dërgohet në këtë mënyrë
var result = client.UploadString(new Uri("https://www.rimbushe.com/api/sms/send"), "POST", payload);
}
Invoke-WebRequest -Method POST `
-ContentType "application/json" `
-Uri https://www.rimbushe.com/users/authenticate `
-Body '{
"apikey": "61d12baa-ddde-41a4-b29c-08cbd821ef88",
"secret": "b8b25aaecce4649a"
}'
curl -X POST \
-H "Content-Type: application/json" -d '
{
"apikey": "61d12baa-ddde-41a4-b29c-08cbd821ef88",
"secret": b8b25aaecce4649a
}' \
"https://www.rimbushe.com/users/authenticate"
using (var client = new WebClient()){
client.Headers[HttpRequestHeader.ContentType] = "application/json";
//Deklaroje nje anonymous object sa për test - rekomandohet ta keni një klasë të veçantë për Authentikim
var smsMsg = new { apikey = "61d12baa-ddde-41a4-b29c-08cbd821ef88", secret = b8b25aaecce4649a};
//Mund ta përdorni Newtonsoft JsonConvert për ta konvertuar klasën e sipërme ne json
var payload = JsonConvert.SerializeObject(smsMsg);
//Payloadi dërgohet në këtë mënyrë
var result = client.UploadString(new Uri("https://www.rimbushe.com/users/authenticate"), "POST", payload);
}
{
"token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpZCI6IjEiLCJjbGFpbXMiOlsic2VuZHNtcyIsImJyb3dzZXVzZXJzIl0sImp0aSI6IjRlOTVjMWQyLWQyMjctNDMyMS05MzFlLTIwYjcyNjIzYWFiMSIsImV4cCI6MTYyMDA3MzE2MSwiaXNzIjoiUmltYnVzaGUuY29tIiwiYXVkIjoiUmltYnVzaGUuY29tIn0.Eq93TLomOBwBgu8sgaSN4f1jWEENcMLB32eQYwVNY8A",
"type": "bearer",
"expiresAt": "2021-05-03T20:19:21.9686253Z",
"description": "Expire Time is in UTC."
}