Endpoint
PUT/link/:link_id/mobile
APIs that can be used to work with State programmatically
This API method updates only ios and android fields in a short link for the authenticated team.
Authorization required.
| Parameter | Description |
|---|---|
| link_id | Required |
| Parameter | Description |
|---|---|
| ios | The iOS destination URL for the short link; takes priority on iOS devices |
| android | The Android destination URL for the short link; takes priority on Android devices |
curl -X 'PUT' https://state.sk/api/link/link42/mobile \
-H 'x-api-key: state_xxxxxxxxxx' \
-d '{
"ios": "https://apps.apple.com/app/cloomba/id6670720223",
"domain": "https://play.google.com/store/apps/details?id=com.allwhitetown.cloomba"
}'
The updated link
{
"id": "link42",
"org_id": "org-1",
"user_id": "user-1",
"folder_id": null,
"domain_id": 1,
"domain": "state.sk",
"slug": "somethingrandom",
"url": "https://google.com",
"title": "Google",
"expires_at": null,
"expires_after": 0,
"expire_url": null,
"utm_source": null,
"utm_medium": null,
"utm_campaign": null,
"utm_term": null,
"utm_content": null,
"utm_reference": null,
"created_at": "2025-10-07T13:12:01.761Z",
"updated_at": "2025-10-07T13:12:01.761Z",
"ios": "https://apps.apple.com/app/cloomba/id6670720223",
"domain": "https://play.google.com/store/apps/details?id=com.allwhitetown.cloomba",
"redirect_code": null,
"has_password": false,
"short_url": "https://state.sk/somethingrandom",
"clicks": 3,
"clicked_at": "2025-10-15T13:12:01.761Z",
"folder": null,
"tags": [],
"ab": [],
"geo": []
}
Detailed information about the link fields in the Link article.