---
title: "Get campaign link activity"
slug: "get-campaign-link-activity"
abstract: "Describes the request and response details of this Sitecore Send API endpoint to get campaign link activity."
---
# Get campaign link activity

`GET /campaigns/{CampaignID}/stats/links.{Format}`

Retrieves a list of all the links in a specific campaign and the number of unique or total link clicks made by campaign recipients.

## Request

| Parameter | In | Type | Required | Description |
| --- | --- | --- | --- | --- |
| CampaignID | path | string | true | The ID of the campaign that you want to get link activity by location of. |
| Format | path | string | true | The supported file format for getting a response.Possible values: json and xml. |
| apikey | query | string | true | The API key of your account. |

```http
GET https://{hostname}/v3/campaigns/{CampaignID}/stats/links.{Format}?apikey=
```

```curl
curl --include \\
     --header "Content-Type: application/json" \\
     --header "Accept: application/json" \\
     'https://{hostname}/v3/campaigns/{CampaignID}/stats/links.{Format}?apikey='
```

## Response

| Status | Description | Headers | Schema |
| --- | --- | --- | --- |
| 200 OK | The request is successful. | Content-Type:application/jsonAccept:application/json | N/A |

```json
{
  "Code": 0,
  "Error": null,
  "Context": {
    "Paging": {
      "PageSize": 0,
      "CurrentPage": 1,
      "TotalResults": 0,
      "TotalPageCount": 0,
      "SortExpression": null,
      "SortIsAscending": false
    },
    "Analytics": \[
      {
        "Context": "http://someUrl.com/",
        "ContextName": null,
        "TotalCount": 1,
        "UniqueCount": 1,
        "ContextDescription": null,
        "Timestamp": null
      },
      {
        "Context": "http://someUrl.com/product1/",
        "ContextName": null,
        "TotalCount": 1,
        "UniqueCount": 1,
        "ContextDescription": null,
        "Timestamp": null
      },
      {
        "Context": "http://someUrl.com/product2/",
        "ContextName": null,
        "TotalCount": 1,
        "UniqueCount": 1,
        "ContextDescription": null,
        "Timestamp": null
      },
      {
        "Context": "https://twitter.com/myCompany",
        "ContextName": null,
        "TotalCount": 1,
        "UniqueCount": 1,
        "ContextDescription": null,
        "Timestamp": null
      }
    \]
  }
}
```

-   `Code` - the response code. This is `0` if successful.
    
-   `Error` - the response error message. This is `null` if successful.
    
-   `Context` - an object that contains all the `Paging` and `Analytics` information for the campaign:
    
    -   `Paging` - an object that contains the following information:
        
        -   `PageSize` - the page size of the results. This is `0` if not defined.
            
        -   `CurrentPage` - the number of the result page. This is `1` if not defined.
            
        -   `Totalresults` - the number of results that are included in the response.
            
        -   `TotalPageCount` - the total number of pages in your account.
            
        -   `SortExpression` - the sort expression associated with the column or columns being sorted.
            
        -   `SortIsAscending` - this is `false` if the results are not displayed in ascending order based on the sort expression.

    -   `Analytics` - a list of links in your campaign containing the following information for each link:
        
        -   `Context` - the URL of the link.
            
        -   `ContextName` - this is `null` for this case.
            
        -   `TotalCount` - the total number of link clicks. Deprecated
            
        -   `UniqueCount` - the total number of unique link clicks. Deprecated
            
        -   `ContextDescription` : This is `null` for this case.
            
        -   `Timestamp` - the time the action is added in the response.