Overview
This node provides URL shortening functionality by interacting with an external URL shortening API. It allows users to convert long URLs into shorter, more manageable links. This is useful for sharing links in a compact form, tracking clicks, or customizing the appearance of URLs.
Common scenarios include:
- Sharing shortened URLs on social media or messaging platforms.
- Creating branded short links with custom aliases.
- Protecting shortened URLs with passwords.
- Setting expiration dates for temporary links.
For example, a user can input a long URL and optionally specify a custom alias, password protection, and expiry date. The node then returns a shortened URL that respects these settings.
Properties
| Name | Meaning |
|---|---|
| URL Para Encurtar | The original long URL that you want to shorten. |
| Alias Personalizado | Optional custom alias for the shortened URL (e.g., a memorable keyword). |
| Senha | Optional password to protect access to the shortened link. |
| Data De Expiração | Optional expiration date/time after which the shortened URL will no longer be valid. |
Output
The node outputs an array of JSON objects, each containing:
shortenedUrl: The resulting shortened URL string returned from the API.
If multiple input items are processed, the output array contains one corresponding shortened URL object per input item.
No binary data is produced by this node.
Example output JSON structure:
{
"shortenedUrl": "https://short.url/abc123"
}
Dependencies
- Requires an API key credential for authentication with the external URL shortening service.
- Makes HTTP POST requests to
https://link.clientes.online/api/url/addwith JSON payload. - The node expects the API key to be provided via n8n credentials configuration.
Troubleshooting
- Invalid API Key or Authentication Failure: Ensure the API key credential is correctly configured and active.
- API Request Errors: Network issues or invalid parameters may cause request failures. Verify URL format and optional fields.
- Custom Alias Conflicts: If a custom alias is already taken, the API might return an error. Try using a different alias or leave it blank.
- Expiry Date Format: The expiry date should follow the expected format (
YYYY-MM-DD HH:mm:ss). Incorrect formatting may cause errors. - Password Protection Issues: Passwords should be properly set if used; otherwise, omit this field.
If the node is set to continue on failure, errors for individual items will be included in the output alongside the original input data.
Links and References
- URL Shortening API Documentation (assumed based on endpoint)
- General information about URL shortening services and best practices.