Campaign Analytics
curl --request GET \
--url https://api.kakiyo.com/v1/analytics/campaigns/{campaignId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"campaign": {
"id": "campaign_123",
"name": "Q4 Enterprise Outreach"
},
"metrics": {
"totalProspects": 150,
"conversionRate": 8
}
}{
"error": "validation_error",
"message": "The request parameters failed validation",
"details": [
{
"field": "name",
"message": "The name field is required"
}
]
}{
"error": "validation_error",
"message": "The request parameters failed validation",
"details": [
{
"field": "name",
"message": "The name field is required"
}
]
}Analytics
Campaign Analytics
Get detailed analytics for a specific campaign
GET
/
analytics
/
campaigns
/
{campaignId}
Campaign Analytics
curl --request GET \
--url https://api.kakiyo.com/v1/analytics/campaigns/{campaignId} \
--header 'Authorization: Bearer <token>'import requests
url = "https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.kakiyo.com/v1/analytics/campaigns/{campaignId}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"campaign": {
"id": "campaign_123",
"name": "Q4 Enterprise Outreach"
},
"metrics": {
"totalProspects": 150,
"conversionRate": 8
}
}{
"error": "validation_error",
"message": "The request parameters failed validation",
"details": [
{
"field": "name",
"message": "The name field is required"
}
]
}{
"error": "validation_error",
"message": "The request parameters failed validation",
"details": [
{
"field": "name",
"message": "The name field is required"
}
]
}Overview
Get detailed analytics and performance metrics for a specific campaign. This endpoint provides comprehensive insights into campaign performance, prospect engagement, and conversion metrics.Path Parameters
string
required
The unique identifier of the campaign to analyze
Use Cases
- Campaign Performance Review: Analyze individual campaign effectiveness
- Optimization Insights: Identify areas for campaign improvement
- ROI Analysis: Calculate return on investment for specific campaigns
- A/B Testing: Compare performance between different campaign strategies
Response Structure
Campaign Details
- Basic campaign information and configuration
- Current status and timeline
Performance Metrics
- Prospect engagement statistics
- Message and response metrics
- Qualification and conversion rates
Daily Activity Breakdown
- Day-by-day activity analysis
- Trend identification over time
Status Distribution
- Breakdown of prospects by conversation status
- Qualification status analysis
Example Response
{
"campaign": {
"id": "campaign_123",
"name": "Q4 Enterprise Outreach",
"status": "active",
"createdAt": "2024-01-15T10:30:00Z",
"agent": "agent_456",
"product": "Enterprise Solution"
},
"metrics": {
"totalProspects": 150,
"totalMessages": 420,
"totalQualified": 12,
"totalAnswers": 35,
"totalClosed": 8,
"conversionRate": 8.0,
"responseRate": 23.33,
"qualificationRate": 34.29,
"averageMessagesPerProspect": 2.8
},
"activity": {
"dailyBreakdown": [
{
"date": "2024-01-20",
"messages": 25,
"responses": 4,
"qualified": 1
},
{
"date": "2024-01-19",
"messages": 30,
"responses": 6,
"qualified": 2
}
],
"last7Days": {
"messages": 180,
"responses": 28,
"qualified": 8
}
},
"statusDistribution": {
"pending": 85,
"contacted": 45,
"responded": 35,
"qualified": 12,
"closed": 8
},
"qualificationBreakdown": {
"pending": 123,
"qualified": 12,
"disqualified": 15
}
}
Testing Example
curl -X GET "https://api.kakiyo.com/v1/analytics/campaigns/campaign_123" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json"
// JavaScript/Node.js
const campaignId = 'campaign_123';
const response = await fetch(`https://api.kakiyo.com/v1/analytics/campaigns/${campaignId}`, {
method: 'GET',
headers: {
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
}
});
const analytics = await response.json();
console.log('Campaign Analytics:', analytics);
# Python
import requests
campaign_id = 'campaign_123'
response = requests.get(
f'https://api.kakiyo.com/v1/analytics/campaigns/{campaign_id}',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Content-Type': 'application/json'
}
)
analytics = response.json()
print('Campaign Analytics:', analytics)
Error Responses
Campaign Not Found
{
"error": "not_found",
"message": "Campaign not found"
}
Access Denied
{
"error": "forbidden",
"message": "You do not have access to this campaign"
}
Analytics Insights
Performance Indicators
High-Performing Campaigns:- Response rate > 20%
- Qualification rate > 30%
- Conversion rate > 5%
- Low response rate: Review messaging strategy
- High responses, low qualification: Improve targeting
- High qualification, low closing: Enhance follow-up process
Daily Activity Patterns
Monitor daily breakdowns to identify:- Peak engagement days
- Message volume optimization
- Response timing patterns
Best Practices
- Regular Review: Analyze campaign metrics weekly
- Comparative Analysis: Compare with team averages
- Trend Monitoring: Track performance changes over time
- Data-Driven Decisions: Use metrics to guide campaign adjustments
Last modified on August 29, 2025

