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

Please Wait...

Hello Guest

logo

FAQs

Help
Center

Developer API

Create Short Links using API

Generate branded short URLs programmatically.

Overview

The Short Link API allows developers to create short URLs programmatically without logging into the SPRL dashboard. It is ideal for websites, mobile applications, CRM systems, ERP software, marketing platforms, automation tools, and custom business applications.

After authenticating your application using a valid API Key, you can send requests to the Short Link API and receive a shortened URL instantly.


Prerequisites

Before using the Short Link API, ensure you have:

Requirement Description
SPRL Account An active SPRL account.
API Credentials A valid Client ID and Client Key.
HTTPS All API requests must be sent over HTTPS.
API Access The URL Shortener API must be enabled for your account.

How the API Works

Step Action
1 Authenticate your request using your API credentials.
2 Submit the destination URL to the Short Link API.
3 The API validates the request.
4 A unique short URL is generated.
5 The API returns the newly created short link.

Typical Request Data

Depending on the endpoint and your account features, a request may include one or more of the following:

Parameter Description
Destination URL The original URL to shorten.
Custom Alias Optional custom short code, if supported.
Custom Domain Optional branded domain for the generated short link.
Tags Optional labels used for organisation and reporting.
Expiration Settings Optional expiry rules for temporary links.

API Response

A successful response typically includes information about the newly created short link.

Response Item Description
Short URL The generated shortened link.
Original URL The destination URL provided in the request.
Reference ID Unique identifier for the created link.
Status Indicates whether the request completed successfully.

Common Use Cases

  • Automatically shorten links before sending emails.
  • Create links from CRM or ERP systems.
  • Generate branded URLs for marketing campaigns.
  • Create links from mobile applications.
  • Integrate URL shortening into internal business software.
  • Automate link creation using workflows and third-party platforms.

Best Practices

  • Validate destination URLs before sending requests.
  • Use HTTPS for every API request.
  • Protect your Client Key and never expose it publicly.
  • Reuse existing links where appropriate instead of creating duplicates.
  • Monitor API usage to stay within your rate limits.

Troubleshooting

Issue Possible Solution
Authentication failed Verify your Client ID and Client Key.
Invalid URL Ensure the destination URL is valid and publicly accessible.
Permission denied Confirm that the URL Shortener API is enabled for your account.
Rate limit exceeded Reduce the request frequency and retry later.
Unexpected API response Review the endpoint documentation and verify the request format.

Frequently Asked Questions

Can I create branded short links?

Yes. If your account is configured with a custom domain, you can generate branded short URLs using the API.

Can I automate link creation?

Yes. The API is designed for automated integrations with websites, applications, and business systems.

Does the API return the generated short URL?

Yes. A successful request returns the newly created short link along with other response information.

Can I use the API in mobile applications?

Yes. However, API credentials should always be stored securely on your server rather than inside the mobile application.


Learn More
Continue with the QR Code API guide to learn how to generate QR Codes programmatically, or explore the complete API documentation for available endpoints, request parameters, and response formats.
Tip
Use Test API Keys while developing your integration and switch to Live API Keys only after your application has been fully tested. Always validate destination URLs before submitting them to the API to reduce request failures.

Need more help?

Our support team is always happy to assist you.

×

We use cookies to improve your experience, analyse traffic, and personalise content. By clicking “Accept”, you consent to the use of cookies as described in our Cookie Policy .

Accept cookies Read our Cookie Policy