Obtain Access Token
curl --request POST \
--url https://auth.interactsms.com/token \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data username=your_username \
--data password=your_strong_password \
--data client_id=ismstoken \
--data grant_type=passwordimport requests
url = "https://auth.interactsms.com/token"
payload = {
"username": "your_username",
"password": "your_strong_password",
"client_id": "ismstoken",
"grant_type": "password"
}
headers = {"Content-Type": "application/x-www-form-urlencoded"}
response = requests.post(url, data=payload, headers=headers)
print(response.text)using RestSharp;
var options = new RestClientOptions("https://auth.interactsms.com/token");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddParameter("username", "your_username");
request.AddParameter("password", "your_strong_password");
request.AddParameter("client_id", "ismstoken");
request.AddParameter("grant_type", "password");
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.post("https://auth.interactsms.com/token")
.header("Content-Type", "application/x-www-form-urlencoded")
.body("username=your_username&password=your_strong_password&client_id=ismstoken&grant_type=password")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://auth.interactsms.com/token",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "username=your_username&password=your_strong_password&client_id=ismstoken&grant_type=password",
CURLOPT_HTTPHEADER => [
"Content-Type: application/x-www-form-urlencoded"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}const options = {
method: 'POST',
headers: {'Content-Type': 'application/x-www-form-urlencoded'},
body: new URLSearchParams({
username: 'your_username',
password: 'your_strong_password',
client_id: 'ismstoken',
grant_type: 'password'
})
};
fetch('https://auth.interactsms.com/token', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"access_token": "eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJE...",
"expires_in": 120,
"refresh_expires_in": 1200,
"refresh_token": "eyJhbGciOiJIUzUxMiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJh...",
"token_type": "Bearer",
"scope": "email profile client_id"
}{
"error": "invalid_grant",
"error_description": "Invalid user credentials"
}Authentication
Obtain Access Token
Use this request to obtain a JWT access token for authenticating with the API.
Token Endpoint: https://auth.interactsms.com/token
Grant Type: password
Content-Type: application/x-www-form-urlencoded
Request body form fields:
grant_type=passwordusername=your_usernamepassword=your_strong_passwordclient_id=ismstoken
Successful Response will include:
access_token— JWT to be passed inAuthorization: Bearer {token}expires_in— Time in seconds before token expiresrefresh_token— Token used to obtain a new access tokenscope,session_state, etc.
This path is included for documentation only. Make actual requests directly to https://auth.interactsms.com/token.
POST
/
token
Obtain Access Token
curl --request POST \
--url https://auth.interactsms.com/token \
--header 'Content-Type: application/x-www-form-urlencoded' \
--data username=your_username \
--data password=your_strong_password \
--data client_id=ismstoken \
--data grant_type=passwordimport requests
url = "https://auth.interactsms.com/token"
payload = {
"username": "your_username",
"password": "your_strong_password",
"client_id": "ismstoken",
"grant_type": "password"
}
headers = {"Content-Type": "application/x-www-form-urlencoded"}
response = requests.post(url, data=payload, headers=headers)
print(response.text)using RestSharp;
var options = new RestClientOptions("https://auth.interactsms.com/token");
var client = new RestClient(options);
var request = new RestRequest("");
request.AddParameter("username", "your_username");
request.AddParameter("password", "your_strong_password");
request.AddParameter("client_id", "ismstoken");
request.AddParameter("grant_type", "password");
var response = await client.PostAsync(request);
Console.WriteLine("{0}", response.Content);
HttpResponse<String> response = Unirest.post("https://auth.interactsms.com/token")
.header("Content-Type", "application/x-www-form-urlencoded")
.body("username=your_username&password=your_strong_password&client_id=ismstoken&grant_type=password")
.asString();<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://auth.interactsms.com/token",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => "username=your_username&password=your_strong_password&client_id=ismstoken&grant_type=password",
CURLOPT_HTTPHEADER => [
"Content-Type: application/x-www-form-urlencoded"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}const options = {
method: 'POST',
headers: {'Content-Type': 'application/x-www-form-urlencoded'},
body: new URLSearchParams({
username: 'your_username',
password: 'your_strong_password',
client_id: 'ismstoken',
grant_type: 'password'
})
};
fetch('https://auth.interactsms.com/token', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));{
"access_token": "eyJhbGciOiJSUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJE...",
"expires_in": 120,
"refresh_expires_in": 1200,
"refresh_token": "eyJhbGciOiJIUzUxMiIsInR5cCIgOiAiSldUIiwia2lkIiA6ICJh...",
"token_type": "Bearer",
"scope": "email profile client_id"
}{
"error": "invalid_grant",
"error_description": "Invalid user credentials"
}Body
application/x-www-form-urlencoded
Response
JWT Token Response Body
JWT access token to pass in the Authorization header.
Number of seconds before the access token expires.
Token used to obtain a new access token.
Available options:
Bearer Number of seconds before the refresh token expires.
Space-delimited scopes associated with the token.
Last modified on August 31, 2026