---
updatedAt: 2025-06-04T21:28:31.000Z
agentTools:
  projectIndex: https://developer.simpplr.com/llms.txt
---

# Content Referral Sources

Use this API to get Content Referral Source Data

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "simpplr-api-gateway",
    "version": "1.0"
  },
  "servers": [
    {
      "url": "https://api.ec.simpplr.com/api"
    }
  ],
  "components": {
    "securitySchemes": {
      "sec0": {
        "type": "oauth2",
        "flows": {}
      }
    }
  },
  "security": [
    {
      "sec0": []
    }
  ],
  "paths": {
    "/analytics/content-referral-sources": {
      "get": {
        "summary": "Content Referral Sources",
        "description": "Use this API to get Content Referral Source Data",
        "operationId": "content-referral-sources",
        "parameters": [
          {
            "name": "from",
            "in": "query",
            "description": "Time from which the Content Referral Source data need to be selected",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2020-12-27"
            }
          },
          {
            "name": "to",
            "in": "query",
            "description": "Time till which the Content Referral Source data need to be selected",
            "required": true,
            "schema": {
              "type": "string",
              "default": "2022-01-26"
            }
          },
          {
            "name": "group-by",
            "in": "query",
            "description": "Group the Result according to group-by value",
            "schema": {
              "type": "string",
              "enum": [
                "day",
                "week",
                "month"
              ],
              "default": "day"
            }
          },
          {
            "name": "x-user-email",
            "in": "header",
            "description": "User's email to login into Salesforce",
            "required": true,
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "200",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"statusCode\": 200,\n    \"status\": \"success\",\n    \"message\": \"\",\n    \"data\": {\n        \"data\": [\n            {\n                \"totalViewsCount\": 2,\n                \"referralsPerItemPercentage\": 50,\n                \"referralsPerItemCount\": 1,\n                \"referralsPercentage\": 50,\n                \"referralsCount\": 1,\n                \"label\": \"My content\",\n                \"contentItemsCount\": 1\n            },\n            {\n                \"totalViewsCount\": 2,\n                \"referralsPerItemPercentage\": 50,\n                \"referralsPerItemCount\": 1,\n                \"referralsPercentage\": 50,\n                \"referralsCount\": 1,\n                \"label\": \"Site feed\",\n                \"contentItemsCount\": 1\n            }\n        ],\n        \"csvUrl\": \"https://ajay-hada-dev-ed--c.visualforce.com/apex/Reports?action=getContentReferralSources&to=2022-01-26&from=2020-12-27\"\n    }\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "statusCode": {
                      "type": "integer",
                      "example": 200,
                      "default": 0
                    },
                    "status": {
                      "type": "string",
                      "example": "success"
                    },
                    "message": {
                      "type": "string",
                      "example": ""
                    },
                    "data": {
                      "type": "object",
                      "properties": {
                        "data": {
                          "type": "array",
                          "items": {
                            "type": "object",
                            "properties": {
                              "totalViewsCount": {
                                "type": "integer",
                                "example": 2,
                                "default": 0
                              },
                              "referralsPerItemPercentage": {
                                "type": "integer",
                                "example": 50,
                                "default": 0
                              },
                              "referralsPerItemCount": {
                                "type": "integer",
                                "example": 1,
                                "default": 0
                              },
                              "referralsPercentage": {
                                "type": "integer",
                                "example": 50,
                                "default": 0
                              },
                              "referralsCount": {
                                "type": "integer",
                                "example": 1,
                                "default": 0
                              },
                              "label": {
                                "type": "string",
                                "example": "My content"
                              },
                              "contentItemsCount": {
                                "type": "integer",
                                "example": 1,
                                "default": 0
                              }
                            }
                          }
                        },
                        "csvUrl": {
                          "type": "string",
                          "example": "https://ajay-hada-dev-ed--c.visualforce.com/apex/Reports?action=getContentReferralSources&to=2022-01-26&from=2020-12-27"
                        }
                      }
                    }
                  }
                }
              }
            }
          },
          "401": {
            "description": "401",
            "content": {
              "application/json": {
                "examples": {
                  "Result": {
                    "value": "{\n    \"statusCode\": 401,\n    \"status\": \"error\",\n    \"message\": \"SESSION_TIMEOUT\",\n    \"data\": {}\n}"
                  }
                },
                "schema": {
                  "type": "object",
                  "properties": {
                    "statusCode": {
                      "type": "integer",
                      "example": 401,
                      "default": 0
                    },
                    "status": {
                      "type": "string",
                      "example": "error"
                    },
                    "message": {
                      "type": "string",
                      "example": "SESSION_TIMEOUT"
                    },
                    "data": {
                      "type": "object",
                      "properties": {}
                    }
                  }
                }
              }
            }
          }
        },
        "deprecated": false
      }
    }
  },
  "x-readme": {
    "headers": [],
    "explorer-enabled": true,
    "proxy-enabled": true
  },
  "x-readme-fauxas": true
}
```