Oops! Facing network problem. Unable to load this page. Refresh

Please Wait...

Hello Guest

logo

Bulk Shortening with Nested Route (DLT-Compliant SMS)

Bulk Shortening with Nested Route (DLT-Compliant SMS) api document

Shorten Link
APIs

Bulk Shortening with Nested Route (DLT-Compliant SMS)

POST /url/bulk-url-shortener-nested-route

If you send SMS campaigns at scale in India, ensuring compliance with DLT (Distributed Ledger Technology) is crucial. The Bulk Shortening with Nested Route API by SPRL helps you create multiple short URLs in one request, while aligning with TRAI’s DLT framework.

This API is ideal for bulk SMS dispatch where every message may include a shortened URL, such as OTP links, tracking URLs, campaign CTAs, or custom user journeys, all fully compliant with DLT-registered templates, sender headers, and routes.

Request Information

MethodPOST
Request URLhttps://insprl.com/api/url/bulk-url-shortener-nested-route
AuthenticationRequired How to Generate API keys?
ParameterTypeDescription
AuthorizationStringUse your "CLIENT KEY" for this Parameter
ParameterTypeValidateDescription
client_idStringRequiredUse your "CLIENT ID" for this Parameter
urlsArrayRequiredAdd multiple urls (Up to 1000) which you want to get shorter.
nested_pathStringRequired,
Max 50 chars,
Pattern: ^[a-zA-Z0-9\-_]+$
Nested route to append to the short URL. Only letters, numbers, hyphens, and underscores are allowed.
slug_prefixStringOptionalAllowed only alpha-numeric characters, underscores, and dashes.
domainStringOptionalSpecify if you want to use custom domain
expiry_dateDateOptionalDate format: dd-mm-yyyy
response_modeStringOptional"plain" (Default) or "along" (Pass the reference key to receive in response)
ParameterTypeDescription
codeNumericFind the code information below under "API Codes"
messageString / ArrayAs per the request handler
short_urlsArrayList of Shorten URLs
CodeModeTypeDescription
100successStringOn Success
101failedStringAuthorization Error
102failedArrayParameter Validation Error
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,"https://insprl.com/api/url/bulk-url-shortener-nested-route");
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_HTTPHEADER, array(
   'Authorization: {CLIENT_KEY}'
)); curl_setopt($ch, CURLOPT_POSTFIELDS,
http_build_query(
array(
   'client_id' => '{CLIENT_ID}',
   'urls' => ["https://www.google.com","https://www.sunprograms.com"],
   //'urls' => {"A1":"https://www.google.com","A2":"https://www.sunprograms.com"}, /*Response Mode: "along" */
   'nested_path' => 'ABCDEF',
   'slug_prefix' => 'b1-',
   'domain' => 'mydomain.com',
   'expiry_date' => '11-02-2020'
   'response_mode' => 'plain'
)
));
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true); $response = curl_exec($ch); curl_close ($ch);
With "response_mode" : "plain"
{
"code": 100,
"message": "success",
"data": {
   "short_urls": ["https://mydomain.com/ABCDEF/sUJIrI","https://mydomain.com/ABCDEF/hg6IrI"],
}
}

With "response_mode" : "along"
{
"code": 100,
"message": "success",
"data": {
   "short_urls": {"A1": "https://mydomain.com/ABCDEF/sUJIrI","A2": "https://mydomain.com/ABCDEF/hg6IrI"},
}
}

HTTP API INTEGRATION

If you'd like to use our REST API into your application, Feel free to contact us.

8088 948 172 or Contact Us

Latest From Blog

Read our latest posts from our blog

image
Bulk URL generators the NEXT BIG thing in Digital Marketing

If you are into marketing, you must have heard of Bulk URL shortening. They are saying Bulk URL shortening is the new ..

03 May, 2022 SRPL Shortener
image
How Best Indian URL Shorteners can help your business grow?

Every profit driven business enterprise is adopting and incorporating URL Shortening as a part of best business ..

24 Apr, 2022 SRPL Shortener
image
Email Marketing Do's and Don'ts

If your company or business isn’t using email promoting, ought to they? The solution is affirmative, as email is ..

01 Mar, 2021 Email Marketing

This website uses cookies in order to offer you the most relevant information. We may place cookies on your computer for functional, marketing and tracking purposes to improve our site and to show personalised content. You can read more about our cookies here: Cookie Policy. Please accept cookies for optimal performance.

Yes, I accept Cookies.