curl --request POST \
--url https://api.onexaura.com/v1/pins/{pinId}/resend \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"channels": [
"whatsapp"
],
"templateParams": {
"1": "Jane Doe",
"2": "ORD-1234"
}
}
'import requests
url = "https://api.onexaura.com/v1/pins/{pinId}/resend"
payload = {
"channels": ["whatsapp"],
"templateParams": {
"1": "Jane Doe",
"2": "ORD-1234"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({channels: ['whatsapp'], templateParams: {'1': 'Jane Doe', '2': 'ORD-1234'}})
};
fetch('https://api.onexaura.com/v1/pins/{pinId}/resend', 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://api.onexaura.com/v1/pins/{pinId}/resend",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'channels' => [
'whatsapp'
],
'templateParams' => [
'1' => 'Jane Doe',
'2' => 'ORD-1234'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.onexaura.com/v1/pins/{pinId}/resend"
payload := strings.NewReader("{\n \"channels\": [\n \"whatsapp\"\n ],\n \"templateParams\": {\n \"1\": \"Jane Doe\",\n \"2\": \"ORD-1234\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.onexaura.com/v1/pins/{pinId}/resend")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"channels\": [\n \"whatsapp\"\n ],\n \"templateParams\": {\n \"1\": \"Jane Doe\",\n \"2\": \"ORD-1234\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.onexaura.com/v1/pins/{pinId}/resend")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"channels\": [\n \"whatsapp\"\n ],\n \"templateParams\": {\n \"1\": \"Jane Doe\",\n \"2\": \"ORD-1234\"\n }\n}"
response = http.request(request)
puts response.read_body{
"pinId": "pin_x9k2m1qz",
"status": "PENDING",
"expiresAt": "2026-08-04T10:22:03.221Z",
"attemptsRemaining": 3,
"channels": [
{
"channel": "sms",
"status": "accepted",
"providerMessageId": "<string>",
"errorCode": "<string>",
"errorMessage": "<string>"
}
]
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}Resend a PIN
Issue a fresh PIN on an existing pinId, optionally on a different channel.
curl --request POST \
--url https://api.onexaura.com/v1/pins/{pinId}/resend \
--header 'Authorization: Bearer <token>' \
--header 'Content-Type: application/json' \
--data '
{
"channels": [
"whatsapp"
],
"templateParams": {
"1": "Jane Doe",
"2": "ORD-1234"
}
}
'import requests
url = "https://api.onexaura.com/v1/pins/{pinId}/resend"
payload = {
"channels": ["whatsapp"],
"templateParams": {
"1": "Jane Doe",
"2": "ORD-1234"
}
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({channels: ['whatsapp'], templateParams: {'1': 'Jane Doe', '2': 'ORD-1234'}})
};
fetch('https://api.onexaura.com/v1/pins/{pinId}/resend', 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://api.onexaura.com/v1/pins/{pinId}/resend",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'channels' => [
'whatsapp'
],
'templateParams' => [
'1' => 'Jane Doe',
'2' => 'ORD-1234'
]
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.onexaura.com/v1/pins/{pinId}/resend"
payload := strings.NewReader("{\n \"channels\": [\n \"whatsapp\"\n ],\n \"templateParams\": {\n \"1\": \"Jane Doe\",\n \"2\": \"ORD-1234\"\n }\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.onexaura.com/v1/pins/{pinId}/resend")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"channels\": [\n \"whatsapp\"\n ],\n \"templateParams\": {\n \"1\": \"Jane Doe\",\n \"2\": \"ORD-1234\"\n }\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.onexaura.com/v1/pins/{pinId}/resend")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"channels\": [\n \"whatsapp\"\n ],\n \"templateParams\": {\n \"1\": \"Jane Doe\",\n \"2\": \"ORD-1234\"\n }\n}"
response = http.request(request)
puts response.read_body{
"pinId": "pin_x9k2m1qz",
"status": "PENDING",
"expiresAt": "2026-08-04T10:22:03.221Z",
"attemptsRemaining": 3,
"channels": [
{
"channel": "sms",
"status": "accepted",
"providerMessageId": "<string>",
"errorCode": "<string>",
"errorMessage": "<string>"
}
]
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}{
"error": {
"code": "pin_expired",
"message": "<string>",
"requestId": "req_9f3a2c",
"details": {}
}
}Switching channel
The most useful thing about a resend is that it does not have to use the channel the original went out on. If SMS was rejected, resend on WhatsApp against the samepinId:
{
"channels": ["whatsapp"]
}
channels to reuse the original send’s channels.
Cooldown
Each template sets aresendCooldown. A resend inside that window is rejected with
resend_cooldown (429) — surface a “try again in a moment” state rather than retrying
automatically. Read the current value off
List templates.
The PIN must also still be resendable: a PIN that is already verified returns
pin_already_verified, and one whose attempts are exhausted returns pin_blocked. Both are
409 — start a new send instead.Authorizations
An API key from the OneXtel portal, Developers → API Keys, sent as Authorization: Bearer <key>.
Headers
Protects a send/resend against duplicate dispatch on retry. Replaying the same key + body within 24h returns the original response verbatim; the same key with a different body is rejected (idempotency_key_reuse); a concurrent request with the same key still in flight is rejected (idempotency_in_progress).
Path Parameters
"pin_x9k2m1qz"
Body
Channels to resend on. Omit to reuse the channels of the original send.
1sms, whatsapp, email ["whatsapp"]
Per-send override for a WhatsApp template's non-OTP placeholders, by position. Omitted positions fall back to the template's stored default.
Show child attributes
Show child attributes
{ "1": "Jane Doe", "2": "ORD-1234" }
Response
At least one channel accepted the message.
Was this page helpful?

