Migration
Move From Legacy Endpoints To v1
v1 keeps the same customer jobs while switching to JSON, stable resource IDs, standard envelopes, cursor pagination, request IDs, and idempotent creates.
Endpoint Mapping
| Legacy | v1 | Notes |
|---|---|---|
| GET /link?shortLink=... | GET /v1/links/{linkId} | Use the stable link ID returned by v1 create/list responses. Use GET /v1/links with search filters when you need to discover IDs. |
| POST /link/create | POST /v1/links | Send application/json instead of multipart/form-data. The response uses the standard v1 envelope. |
| GET /deeplink?shortLink=... | GET /v1/deep-links/{linkId} | Use the stable deep-link ID returned by v1 create/list responses. |
| POST /deeplink | POST /v1/deep-links | Send application/json and provide deepLinkAppId or appId for the configured app. |
Before
Legacy multipart create
curl -X POST "https://api.shortify.com/link/create" \
-H "api-key: your_server_api_key" \
-F "url=https://example.com/pricing" \
-F "slug=pricing-2026"After
v1 JSON create
curl -X POST "https://api.shortify.com/v1/links" \
-H "api-key: sk_live_your_server_key" \
-H "Content-Type: application/json" \
-H "Idempotency-Key: pricing-2026-create" \
--data '{"url":"https://example.com/pricing","domain":"go.example.com","key":"pricing-2026"}'Migration Checklist
- Switch request bodies from multipart/form-data to application/json.
- Store the returned resource ID and use it for retrieve, update, archive, and analytics calls.
- Update error handling to read error.code and error.message from the v1 envelope.
- Add Idempotency-Key to create requests that your backend may retry.
- Use cursor pagination for list and raw-event export endpoints.