The via.deals API
Shorten links programmatically, or import the ready-made shortener into the Deals.Group community extension.
Create a short link
POST https://via.deals/api/links — no authentication required.
Request body (JSON)
- url — the destination URL (required, http/https, safety-checked).
Response
The short URL is returned at shortUrl:
{ "shortUrl": "https://via.deals/ab12cd", "slug": "ab12cd" }
Example (cURL)
curl -X POST "https://via.deals/api/links" \
-H "Content-Type: application/json" \
-d '{"url":"https://example.com/very/long/path","domain":"via.deals"}'
# -> { "shortUrl": "https://via.deals/ab12cd", "slug": "ab12cd" }
Errors: 400 invalid URL / unknown domain · 409 alias taken ·
422 destination flagged unsafe.
Import into Deals.Group
Add via.deals as a shortener in the Deals.Group Affiliate Engine extension.
In the extension: Shorteners → Import (or paste into a new shortener),
then drop in the preset below. The extension's Shorten step will then route links through via.deals.
It reads the short link from responsePath: "shortUrl".
{
"name": "via.deals",
"endpoint": "https://via.deals/api/links",
"method": "POST",
"requestHeaders": {
"Content-Type": "application/json"
},
"requestBody": {
"url": "[DG-FULL_URL]",
"domain": "via.deals"
},
"responsePath": "shortUrl",
"encode": false,
"enabled": true,
"priority": 1
}
[DG-FULL_URL] is a Deals.Group token — the extension replaces it with the converted URL at runtime.