List SMS templates
curl --request GET \
--url https://apisms.beem.africa/public/v1/sms-templates \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://apisms.beem.africa/public/v1/sms-templates"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://apisms.beem.africa/public/v1/sms-templates', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://apisms.beem.africa/public/v1/sms-templates",
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: Basic <encoded-value>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://apisms.beem.africa/public/v1/sms-templates"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://apisms.beem.africa/public/v1/sms-templates")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://apisms.beem.africa/public/v1/sms-templates")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "<string>",
"sms_title": "<string>",
"message": "<string>",
"created": "<unknown>"
}
],
"pagination": {
"totalItems": 123,
"currentPage": 123,
"pageSize": 123,
"totalPages": 123,
"startPage": 123,
"endPage": 123,
"startIndex": 123,
"endIndex": 123,
"pages": [
123
]
}
}{
"code": 120,
"message": "Invalid Authentication Parameters"
}API Reference
List SMS templates
GET
/
public
/
v1
/
sms-templates
List SMS templates
curl --request GET \
--url https://apisms.beem.africa/public/v1/sms-templates \
--header 'Authorization: Basic <encoded-value>'import requests
url = "https://apisms.beem.africa/public/v1/sms-templates"
headers = {"Authorization": "Basic <encoded-value>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Basic <encoded-value>'}};
fetch('https://apisms.beem.africa/public/v1/sms-templates', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://apisms.beem.africa/public/v1/sms-templates",
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: Basic <encoded-value>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://apisms.beem.africa/public/v1/sms-templates"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Basic <encoded-value>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://apisms.beem.africa/public/v1/sms-templates")
.header("Authorization", "Basic <encoded-value>")
.asString();require 'uri'
require 'net/http'
url = URI("https://apisms.beem.africa/public/v1/sms-templates")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Basic <encoded-value>'
response = http.request(request)
puts response.read_body{
"data": [
{
"id": "<string>",
"sms_title": "<string>",
"message": "<string>",
"created": "<unknown>"
}
],
"pagination": {
"totalItems": 123,
"currentPage": 123,
"pageSize": 123,
"totalPages": 123,
"startPage": 123,
"endPage": 123,
"startIndex": 123,
"endIndex": 123,
"pages": [
123
]
}
}{
"code": 120,
"message": "Invalid Authentication Parameters"
}Authorizations
basicAuthaccessToken
Beem API credentials: API key as username, API secret as password.
Query Parameters
Page number to retrieve (starts at 1).
Required range:
x >= 1Maximum number of items to return per page.
Required range:
x >= 1Field name to sort results by.
Sort direction: ascending or descending.
Available options:
asc, desc, ASC, DESC ⌘I
