List links
method
GET
host
strait.
version
/v1
resource
/
GET /v1/links
Auth: secret key as Authorization: Bearer. Server-side only.
Request
Without limit/cursor: every active link as a JSON array (unchanged). With either: one page { links, nextCursor }, newest first; pass nextCursor back as cursor until it is null. status=paused lists paused links instead (turned off with DELETE, PATCH isActive: false or the dashboard; links disabled for abuse are not listed), always as pages.
Parameters
limitinteger query- Page size, 1–100 (larger values are capped at 100). Default 50 when paging.
cursorstring query- Opaque
nextCursorfrom the previous page. status"active" | "paused" queryactive(default) orpaused. Paused links come back as pages; turn one back on with PATCHisActive: true.tagstring query- Only links with this exact tag (works with or without paging). 1–100 characters, no
"or\.
Response
- 200 Links (array), or a page when limit/cursor is given
- 400 Invalid limit, cursor or status
curl -X GET https://strait.link/v1/links \
-H "Authorization: Bearer $SECRET_KEY"const res = await fetch('https://strait.link/v1/links', {
headers: { Authorization: `Bearer ${process.env.SECRET_KEY}` },
});
const data = await res.json();
console.log(res.status, data);import os
import requests
res = requests.get(
"https://strait.link/v1/links",
headers={"Authorization": f"Bearer {os.environ['SECRET_KEY']}"},
)
print(res.status_code, res.json())<?php
// Plain PHP with ext-curl, no packages. In Laravel, Http::withToken($secretKey)->get($url) sends the same request.
$ch = curl_init('https://strait.link/v1/links');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . getenv('SECRET_KEY'),
],
]);
$response = curl_exec($ch);
if ($response === false) {
throw new RuntimeException(curl_error($ch));
}
$status = curl_getinfo($ch, CURLINFO_RESPONSE_CODE);
echo $status, PHP_EOL;
print_r(json_decode($response, true));import java.net.URI;
import java.net.http.HttpClient;
import java.net.http.HttpRequest;
import java.net.http.HttpResponse;
// Java 17+, java.net.http only (no dependencies).
public class Main {
public static void main(String[] args) throws Exception {
HttpRequest request = HttpRequest.newBuilder(URI.create("https://strait.link/v1/links"))
.header("Authorization", "Bearer " + System.getenv("SECRET_KEY"))
.GET()
.build();
HttpResponse<String> res = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());
System.out.println(res.statusCode() + " " + res.body());
}
}package main
import (
"fmt"
"io"
"log"
"net/http"
"os"
)
func main() {
req, err := http.NewRequest(http.MethodGet, "https://strait.link/v1/links", nil)
if err != nil {
log.Fatal(err)
}
req.Header.Set("Authorization", "Bearer "+os.Getenv("SECRET_KEY"))
res, err := http.DefaultClient.Do(req)
if err != nil {
log.Fatal(err)
}
defer res.Body.Close()
data, err := io.ReadAll(res.Body)
if err != nil {
log.Fatal(err)
}
fmt.Println(res.StatusCode, string(data))
}The response, printed
[
{
"id": "lnk_123",
"slug": "summer",
"shortUrl": "https://hilltop.strait.link/summer",
"longUrl": "https://shop.example.com/product/42",
"tenantId": "string",
"isActive": true,
"iosFallbackUrl": "https://shop.example.com/product/42",
"androidFallbackUrl": "https://shop.example.com/product/42",
"desktopUrl": "https://shop.example.com/product/42",
"webTapId": true,
"description": "string",
"imageUrl": "https://shop.example.com/product/42",
"campaign": "string",
"health": {
"status": "ok",
"problems": [
{}
],
"checkedAt": "2026-01-01T00:00:00.000Z"
},
"variants": [
{
"url": "https://shop.example.com/product/42",
"weight": 1
}
],
"passwordProtected": false,
"blockedReason": "string",
"title": "Summer sale",
"tags": [
"spring"
],
"expiresAt": null,
"expiredAction": "page",
"expiredUrl": null,
"startsAt": 1,
"notLiveAction": "page",
"notLiveUrl": null,
"countryRules": [
{
"countries": [
"IN",
"BD"
],
"url": "https://shop.example.com/product/42"
}
],
"legacyHost": "acme.page.link",
"legacyCode": "aBcD",
"referralCode": "string"
}
]{
"links": [
{
"id": "lnk_123",
"slug": "summer",
"shortUrl": "https://hilltop.strait.link/summer",
"longUrl": "https://shop.example.com/product/42",
"tenantId": "string",
"isActive": true,
"iosFallbackUrl": "https://shop.example.com/product/42",
"androidFallbackUrl": "https://shop.example.com/product/42",
"desktopUrl": "https://shop.example.com/product/42",
"webTapId": true,
"description": "string",
"imageUrl": "https://shop.example.com/product/42",
"campaign": "string",
"health": {
"status": "ok",
"problems": [
{}
],
"checkedAt": "2026-01-01T00:00:00.000Z"
},
"variants": [
{
"url": "https://shop.example.com/product/42",
"weight": 1
}
],
"passwordProtected": false,
"blockedReason": "string",
"title": "Summer sale",
"tags": [
"spring"
],
"expiresAt": null,
"expiredAction": "page",
"expiredUrl": null,
"startsAt": 1,
"notLiveAction": "page",
"notLiveUrl": null,
"countryRules": [
{
"countries": [
"IN",
"BD"
],
"url": "https://shop.example.com/product/42"
}
],
"legacyHost": "acme.page.link",
"legacyCode": "aBcD",
"referralCode": "string"
}
],
"nextCursor": "WyIyMDI2LTAxLTAxVDAwOjAwOjAwWiIsImxua18xMjMiXQ"
}