Skip to main content

Overview

Change the status of your dynamic links to control their availability and behavior. You can activate, pause, or archive links to manage your campaigns effectively without losing analytics data.

Endpoint

PATCH https://api.bit2connect.com/1.0/links/{code}/status

Parameters

For detailed information about path and request parameters, see the Update Link Status API Reference.

Example Request

curl -X PATCH "https://api.bit2connect.com/1.0/links/summer-sale/status" \
  -H "X-API-KEY: b2co_your_api_key_here" \
  -H "Content-Type: application/json" \
  -d '{
    "status": "PAUSED"
  }'

Response

Success Response

{
  "success": true,
  "data": {
    "id": "clp123abc456",
    "code": "summer-sale",
    "shortUrl": "https://b2co.link/summer-sale",
    "originalUrl": "https://example.com/products/summer-sale",
    "name": "Summer Sale Campaign",
    "status": "PAUSED",
    "qrCode": "https://b2co.link/summer-sale/qr",
    "createdAt": "2024-01-15T10:30:00Z",
    "updatedAt": "2024-01-15T11:45:00Z",
    "expiresAt": "2024-12-31T23:59:59Z",
    "clickCount": 127
  },
  "timestamp": "2024-01-15T11:45:00Z"
}

Error Response

{
  "success": false,
  "error": {
    "code": "LINK_NOT_FOUND",
    "message": "Link with the specified code was not found"
  }
}
For detailed response fields, error codes, status behavior, and use cases, see the Update Link Status API Reference.

Next Steps