Messenjer API
Panel ulangan Telegram, WhatsApp yoki Instagram akkaunt bilan qila oladigan hamma narsa — REST orqali: bitta kalit, bitta javob formati, bo'limma-bo'lim.
Segmentlar, kampaniyalar, vazifalar
Kontakt kartochkasi bo'yicha auditoriyalar, A/B qadamli drip-kampaniyalar va jamoa uchun eslatmalar.
Base URL: https://chatvendor.net/api/v1 · har javob {"success": true, "data": …}
GET
/segments
Saved audiences (segments) with rules and the cached size
channels:read
Ruxsat: channels:read
Javob 200
OK
curl https://chatvendor.net/api/v1/segments \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
POST
/segments/preview
Count contacts for ad-hoc rules (tags_any, tags_none, vars, active_days, silent_days, purchased, min_points, has_phone, networks, lead_status…)
channels:read
Ruxsat: channels:read
So'rov tanasi (application/json)
rulesobjectJavob 200
OK
curl -X POST https://chatvendor.net/api/v1/segments/preview \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
-H "Content-Type: application/json" \
-d '{"rules":{"tags_any":"vip","active_days":30}}'
GET
/segments/{id}/contacts
Members of a segment (channel_id, peer_id, title, phone, tags, points); ?limit=&offset=
channels:read
Ruxsat: channels:read
Parametrlar
idpath · integermajburiySegment id
Javob 200
OK
curl https://chatvendor.net/api/v1/segments/1/contacts \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
GET
/campaigns
Drip campaigns (entry rule, steps, enrolled)
channels:read
Ruxsat: channels:read
Javob 200
OK
curl https://chatvendor.net/api/v1/campaigns \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
GET
/campaigns/{id}
A campaign with per-step / per-variant stats (sent, replied, converted) and enrolment counts
channels:read
Ruxsat: channels:read
Parametrlar
idpath · integermajburiyCampaign id
Javob 200
OK
curl https://chatvendor.net/api/v1/campaigns/1 \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
POST
/campaigns/{id}/enrol
Put a contact into the campaign now (the first step follows its day/hour rule)
channels:write
Ruxsat: channels:write
Parametrlar
idpath · integermajburiyCampaign id
So'rov tanasi (application/json)
channel_idstringpeer_idstringJavob 200
OK
curl -X POST https://chatvendor.net/api/v1/campaigns/1/enrol \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
-H "Content-Type: application/json" \
-d '{"channel_id":"wa_12","peer_id":"998901234567"}'
GET
/tasks
Open reminders of the team (?done=1 for finished, ?all=1 for both)
channels:read
Ruxsat: channels:read
Javob 200
OK
curl https://chatvendor.net/api/v1/tasks \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
POST
/tasks
Create a reminder; channel_id + peer_id tie it to a chat, user_id assigns it
channels:write
Ruxsat: channels:write
So'rov tanasi (application/json)
titlestringdue_atstringnotestringuser_idintegerchannel_idstringpeer_idstringJavob 200
OK
curl -X POST https://chatvendor.net/api/v1/tasks \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"
-H "Content-Type: application/json" \
-d '[]'
POST
/tasks/{id}/done
Mark a reminder done (undo=true reopens)
channels:write
Ruxsat: channels:write
Parametrlar
idpath · integermajburiyTask id
Javob 200
OK
curl -X POST https://chatvendor.net/api/v1/tasks/1/done \
-H "Authorization: Bearer cv_live_xxxxxxxxxxxx"