curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/ads/snapchat/history?adId=c3a1e2d4-0000-4000-8000-0000000000ad&startDate=2026-11-20&endDate=2026-11-22"
{
"status": "success",
"history": [
{
"accountId": "5a0d0000-0000-4000-8000-000000000003",
"adId": "c3a1e2d4-0000-4000-8000-0000000000ad",
"adName": "Acme - Snap - 2026-11-20T15:04",
"budgetDaily": 20,
"budgetType": "",
"currency": "USD",
"deliveryStatus": null,
"goal": { "type": "brand_awareness" },
"isActive": true,
"isComplete": false,
"metrics": {
"clicks": 42,
"cpc": 0.43,
"cpp": 0,
"cpm": 4.5,
"ctr": 1.05,
"frequency": 0,
"impressions": 4000,
"reach": 0
},
"network": "snapchat",
"postId": "DE6gpw8kxlonHy6eb7L1",
"snapchatSnapId": "6f1c2d3e-0000-4000-8000-00000000000a",
"socialPostId": "6f1c2d3e-0000-4000-8000-00000000000a",
"spend": 18,
"spendDate": "2026-11-21T00:00:00.000Z",
"spendUsd": 18,
"status": "ACTIVE"
}
],
"dateRange": {
"start": "2026-11-20T00:00:00.000Z",
"end": "2026-11-22T00:00:00.000Z",
"adId": "c3a1e2d4-0000-4000-8000-0000000000ad"
},
"metrics": {
"totalSpend": null,
"totalSpendByCurrency": { "USD": 18 },
"totalClicks": 42,
"totalImpressions": 4000,
"totalReach": 0,
"averageCTR": 1.05,
"averageFrequency": 0,
"cpm": 4.5,
"cpp": 0,
"cpc": 0.43,
"costPerResult": 0.43,
"byGoalType": {
"brand_awareness": {
"spend": 18,
"impressions": 4000,
"clicks": 42,
"reach": 0,
"count": 1,
"ctr": 1.05,
"cpm": 4.5,
"cpp": 0,
"cpc": 0.42857142857142855
}
},
"byGoalTitle": {},
"goalPerformance": {
"bestPerformingGoalType": { "type": "brand_awareness", "clicks": 42, "spend": 18, "ctr": 1.05 },
"mostEfficientGoalType": { "type": "brand_awareness", "cpc": 0.43, "spend": 18 }
},
"count": 1,
"firstDay": "2026-11-21T00:00:00.000Z",
"lastDay": "2026-11-21T00:00:00.000Z"
}
}
{
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
"details": "Invalid date format. Please use ISO 8601 format (YYYY-MM-DD)."
}
Snapchat Ads
السجل
احصل على الإنفاق والأداء اليومي لإعلانات Snapchat التي عززتها عبر Ayrshare، مع إجماليات لكل عملة وعوامل تصفية للتاريخ.
GET
/
ads
/
snapchat
/
history
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/ads/snapchat/history?adId=c3a1e2d4-0000-4000-8000-0000000000ad&startDate=2026-11-20&endDate=2026-11-22"
{
"status": "success",
"history": [
{
"accountId": "5a0d0000-0000-4000-8000-000000000003",
"adId": "c3a1e2d4-0000-4000-8000-0000000000ad",
"adName": "Acme - Snap - 2026-11-20T15:04",
"budgetDaily": 20,
"budgetType": "",
"currency": "USD",
"deliveryStatus": null,
"goal": { "type": "brand_awareness" },
"isActive": true,
"isComplete": false,
"metrics": {
"clicks": 42,
"cpc": 0.43,
"cpp": 0,
"cpm": 4.5,
"ctr": 1.05,
"frequency": 0,
"impressions": 4000,
"reach": 0
},
"network": "snapchat",
"postId": "DE6gpw8kxlonHy6eb7L1",
"snapchatSnapId": "6f1c2d3e-0000-4000-8000-00000000000a",
"socialPostId": "6f1c2d3e-0000-4000-8000-00000000000a",
"spend": 18,
"spendDate": "2026-11-21T00:00:00.000Z",
"spendUsd": 18,
"status": "ACTIVE"
}
],
"dateRange": {
"start": "2026-11-20T00:00:00.000Z",
"end": "2026-11-22T00:00:00.000Z",
"adId": "c3a1e2d4-0000-4000-8000-0000000000ad"
},
"metrics": {
"totalSpend": null,
"totalSpendByCurrency": { "USD": 18 },
"totalClicks": 42,
"totalImpressions": 4000,
"totalReach": 0,
"averageCTR": 1.05,
"averageFrequency": 0,
"cpm": 4.5,
"cpp": 0,
"cpc": 0.43,
"costPerResult": 0.43,
"byGoalType": {
"brand_awareness": {
"spend": 18,
"impressions": 4000,
"clicks": 42,
"reach": 0,
"count": 1,
"ctr": 1.05,
"cpm": 4.5,
"cpp": 0,
"cpc": 0.42857142857142855
}
},
"byGoalTitle": {},
"goalPerformance": {
"bestPerformingGoalType": { "type": "brand_awareness", "clicks": 42, "spend": 18, "ctr": 1.05 },
"mostEfficientGoalType": { "type": "brand_awareness", "cpc": 0.43, "spend": 18 }
},
"count": 1,
"firstDay": "2026-11-21T00:00:00.000Z",
"lastDay": "2026-11-21T00:00:00.000Z"
}
}
{
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
"details": "Invalid date format. Please use ISO 8601 format (YYYY-MM-DD)."
}
احصل على سجل الإنفاق اليومي لإعلانات Snapchat التي أنشأتها عبر تعزيز المنشور. كل إدخال في
history هو إعلان واحد في يوم واحد.
- السجل هو سجل Ayrshare اليومي لإنفاقك، لذا قد لا يظهر إنفاق اليوم بعد. للأرقام المباشرة، استخدم الرؤى.
- يظهر الإعلان في كل يوم يُبلغ فيه Snapchat عن إحصاءات له. لا تُدرج الإعلانات المُنشأة في Snapchat Ads Manager.
- عندما لا يُعثر على أي أيام في النطاق الزمني، تظل الاستجابة ناجحة: يكون
historyفارغًا ويحتويwarningsعلى إدخال واحد بالرمز401. - يكون
spendلكل يوم بعملة الحساب الإعلاني، الظاهرة فيcurrency. يعطيtotalSpendByCurrencyالإجمالي بكل عملة. إذا كانت حساباتك الإعلانية تستخدم عملات مختلفة، فصفِّ حسبaccountId. - يحسب
clicksعدد مرات السحب لأعلى (swipe-ups). لا يُبلغ Snapchat عن الوصول اليومي، لذا تكونreachوfrequencyوcppمساوية لـ0. spendUsdهوspendلليوم عندما تكون العملة USD، وnullبخلاف ذلك. يكونtotalSpendدائمًاnull: استخدمtotalSpendByCurrency.- يجمّع
byGoalTypeوgoalPerformanceالأرقام حسب هدف التعزيز:brand_awarenessأوvideo_viewsأوtraffic.
معاملات الترويسة
معاملات الاستعلام
أرسل واحدًا على الأكثر منadId وpostId وaccountId وsocialPostId. إذا أرسلت أكثر من واحد، يُستخدم الأول بهذا الترتيب. احذفها جميعًا للحصول على كل إعلانات Snapchat.
الإعلانات المُعزَّزة من معرّف المنشور هذا في Ayrshare فقط.
الإعلانات المُعزَّزة من هذا الـ Snap فقط: قيمة
mediaId في نتيجة Snapchat للمنشور. يُقبل snapchatSnapId كالمعامل نفسه.الحد الأقصى لعدد الإدخالات اليومية المُعادة، الأحدث أولًا. الحد الأقصى 300؛ تُقيَّد القيم الأعلى عند 300.
curl \
-H "Authorization: Bearer API_KEY" \
-X GET "https://api.ayrshare.com/api/ads/snapchat/history?adId=c3a1e2d4-0000-4000-8000-0000000000ad&startDate=2026-11-20&endDate=2026-11-22"
{
"status": "success",
"history": [
{
"accountId": "5a0d0000-0000-4000-8000-000000000003",
"adId": "c3a1e2d4-0000-4000-8000-0000000000ad",
"adName": "Acme - Snap - 2026-11-20T15:04",
"budgetDaily": 20,
"budgetType": "",
"currency": "USD",
"deliveryStatus": null,
"goal": { "type": "brand_awareness" },
"isActive": true,
"isComplete": false,
"metrics": {
"clicks": 42,
"cpc": 0.43,
"cpp": 0,
"cpm": 4.5,
"ctr": 1.05,
"frequency": 0,
"impressions": 4000,
"reach": 0
},
"network": "snapchat",
"postId": "DE6gpw8kxlonHy6eb7L1",
"snapchatSnapId": "6f1c2d3e-0000-4000-8000-00000000000a",
"socialPostId": "6f1c2d3e-0000-4000-8000-00000000000a",
"spend": 18,
"spendDate": "2026-11-21T00:00:00.000Z",
"spendUsd": 18,
"status": "ACTIVE"
}
],
"dateRange": {
"start": "2026-11-20T00:00:00.000Z",
"end": "2026-11-22T00:00:00.000Z",
"adId": "c3a1e2d4-0000-4000-8000-0000000000ad"
},
"metrics": {
"totalSpend": null,
"totalSpendByCurrency": { "USD": 18 },
"totalClicks": 42,
"totalImpressions": 4000,
"totalReach": 0,
"averageCTR": 1.05,
"averageFrequency": 0,
"cpm": 4.5,
"cpp": 0,
"cpc": 0.43,
"costPerResult": 0.43,
"byGoalType": {
"brand_awareness": {
"spend": 18,
"impressions": 4000,
"clicks": 42,
"reach": 0,
"count": 1,
"ctr": 1.05,
"cpm": 4.5,
"cpp": 0,
"cpc": 0.42857142857142855
}
},
"byGoalTitle": {},
"goalPerformance": {
"bestPerformingGoalType": { "type": "brand_awareness", "clicks": 42, "spend": 18, "ctr": 1.05 },
"mostEfficientGoalType": { "type": "brand_awareness", "cpc": 0.43, "spend": 18 }
},
"count": 1,
"firstDay": "2026-11-21T00:00:00.000Z",
"lastDay": "2026-11-21T00:00:00.000Z"
}
}
{
"action": "request",
"status": "error",
"code": 101,
"message": "Missing or incorrect parameters. Please verify with the docs. https://www.ayrshare.com/docs/apis",
"details": "Invalid date format. Please use ISO 8601 format (YYYY-MM-DD)."
}