CRM

customers

31 uç · /api/crm/v1/customers

İstek örnekleri ucun GERÇEK metodu ve yolundan üretilir. 31 ucun elle doğrulanmış gövde örneği henüz yok; o uçlarda iskelet gövdesizdir — uydurma bir alan yazmıyoruz.

GET/api/crm/v1/customers

bedesk CustomersController::index — PaginateCustomers (tip filtresi + sayfalama).

Oturum
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers

POST /api/crm/v1/customers — panelden ELLE müşteri ekle (IAM-41).

Oturum

Eski panel formu (havuzun CreateUserDialogı) PAROLA soruyordu ve arkasındaki uç **hiç yoktu** — form 404 alıyordu (ölçüldü 2026-08-24). Uç artık var ve parola ALMIYOR: müşterinin portal erişimi paroladan değil sihirli bağlantıdan gelir.

İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}

bedesk CustomerProfileController::show — LoadCustomerProfile (users.update yetkisi gate'i

OturumYol parametresi: userId

require_crm_access + RBAC ile; detaylı izin CF5). Müşteri yoksa 404.

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
PUT/api/crm/v1/customers/{userId}

bedesk CustomerProfileController::update — profil detay/not/tag/email/temel alanları günceller.

OturumYol parametresi: userId
İstek
curl -X PUT "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
DELETE/api/crm/v1/customers/{userId}

bedesk CustomersController::destroy — müşteriyi sil (tüm CRM izi).

OturumYol parametresi: userId
İstek
curl -X DELETE "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/activity-summary

Activity summary

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/activity-summary" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
PATCH/api/crm/v1/customers/{userId}/attributes

Update attributes

OturumYol parametresi: userId
İstek
curl -X PATCH "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/attributes" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers/{userId}/ban

Ban

OturumYol parametresi: userId
İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/ban" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
DELETE/api/crm/v1/customers/{userId}/ban

Unban

OturumYol parametresi: userId
İstek
curl -X DELETE "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/ban" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/channel-profiles

GET me/push-devices — {available: {ios, android}, devices: [...]}. Mobil, bildirim

OturumYol parametresi: userId

anahtarını availablea bakarak çizer (hazır değilse "yakında" DEĞİL, hiç çizmez).

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/channel-profiles" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers/{userId}/channel-profiles/refresh

Kişinin TÜM kimliklerini 24 saat kuralını yok sayarak tazele.

OturumYol parametresi: userId

Bir kimliğin hatası ötekileri DURDURMAZ; her hata yanıtta kimliğiyle birlikte döner (sessizce "tazelendi" demek, düzeltilmesi gereken bir izin sorununu gizlerdi).

İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/channel-profiles/refresh" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/channels

GET /customers/{userId}/channels — yeni görüşmenin ilk mesajı hangi kanallardan

OturumYol parametresi: userId

gidebilir (CHAN-09'un kişi hâli; reply-channels konuşmanınkidir, satır şekli AYNI). options[].is_current = sunucunun channel_account_id verilmezse seçeceği kanal; default aynı kararın tamamı (kanal · e-posta · yok). Seçici ile gönderim AYNI fonksiyondan okur (outbound::pick_person_route).

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/channels" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/commerce

GET /customers/{userId}/commerce — müşteri profilinin ticari künyesi.

OturumYol parametresi: userId

Konuşma ucuyla AYNI karar (commerce::snapshots_for_customer → tek kapı) ve AYNI sahip-muafiyetsiz izin gerekçesi; kişiyi görebilen temsilci (crm.contacts.view) ONUN siparişlerini de görür — konuşmanın sağ paneliyle aynı bilgi.

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/commerce" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/company

Contact company

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/company" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
PUT/api/crm/v1/customers/{userId}/company

Set contact company

OturumYol parametresi: userId
İstek
curl -X PUT "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/company" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
PATCH/api/crm/v1/customers/{userId}/contact-identity

Update identity

OturumYol parametresi: userId
İstek
curl -X PATCH "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/contact-identity" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/conversations

bedesk CustomerProfileController::conversations — müşterinin konuşmaları (simplePagination).

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/conversations" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/duplicate-candidates

CHAN-08 — kişinin olası kopyaları (telefon son-9 hane · gerçek e-posta).

OturumYol parametresi: userId

🔴 Yalnız ÖNERİR. Birleştirme temsilcinin kararıdır (POST /customers/merge): ortak aile/şirket numarası iki farklı insanı aynı kişi gibi gösterebilir.

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/duplicate-candidates" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
DELETE/api/crm/v1/customers/{userId}/emails

Remove email

OturumYol parametresi: userId
İstek
curl -X DELETE "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/emails" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/identity-suggestions

Suggestions

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/identity-suggestions" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/notes

List notes

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/notes" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers/{userId}/notes

Create note

OturumYol parametresi: userId
İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/notes" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
DELETE/api/crm/v1/customers/{userId}/notes/{noteId}

Delete note

OturumYol parametresi: userIdnoteId
İstek
curl -X DELETE "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/notes/<noteId>" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/page-visits

Page visits

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/page-visits" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers/{userId}/phones

Add phone

OturumYol parametresi: userId
İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/phones" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
DELETE/api/crm/v1/customers/{userId}/phones

Remove phone

OturumYol parametresi: userId
İstek
curl -X DELETE "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/phones" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers/{userId}/portal-link

POST /api/crm/v1/customers/{userId}/portal-link — ajan, müşteriye portal giriş

OturumYol parametresi: userId

bağlantısı gönderir. Müşteri bağlantıyı /hcden kendisi de isteyebilir; bu uç destek ekibinin *"portalına giremiyorum"* diyen müşteriye telefonda yardım edebilmesi içindir. 🔴 Bağlantı EKRANDA GÖSTERİLMEZ, yalnız müşterinin e-postasına gider: ekrana basılan bir giriş bağlantısı, o adrese sahip olmayan birinin de portala girebilmesi demekti.

İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/portal-link" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/segments

For contact

OturumYol parametresi: userId
İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/segments" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/wa-templates

GET /customers/{userId}/wa-templates?account= — YENİ görüşmenin şablon seçicisi.

OturumYol parametresi: userId

conversations/{id}/wa-templatesin kişi hâli (yanıt şekli AYNI, aynı yardımcıdan): yeni görüşmede henüz konuşma yoktur, ve öbür iki liste (channels/templates · wa-campaigns/templates) ayar/kampanya izni ister — sıradan temsilci pencere kapalı WhatsApp müşterisine ilk mesajı atamıyordu (mobil 3. tur §1). İzin new-as-agent ile AYNIDIR: şablonu seçebilen onu gönderebilir de. account verilmezse hesap new-as-agentin şablonlu gönderimde seçeceği hesaptır (pick_person_route, şablon kipi) — seçici "şunu göndeririz" deyip gönderim başka hesaba gitmesin. Kişinin o hesapta kimliği yoksa **422** (CRM-OUT-0005), hesap kaldırılmış/bağlı değilse 422 (0008/0006); WhatsApp dışı hesap boş liste döner.

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/wa-templates" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
GET/api/crm/v1/customers/{userId}/web-activity

Bir müşterinin sayfa ziyaretleri (bedesk visits/{userId}) — sidebar paneli.

OturumYol parametresi: userId

GET /api/crm/v1/customers/{userId}/web-activity — widget oturum sayısı, ilk ve son oturum (cihaz · dil · saat dilimi · ilk giriş sayfası · dış referrer · utm) ve ziyaret sayısı. Sağ panelin "Cihaz ve kaynak" bölümünün tek veri kaynağı.

İstek
curl -X GET "https://{slug}.crm.blesyum.app/api/crm/v1/customers/<userId>/web-activity" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
POST/api/crm/v1/customers/merge

bedesk MergeCustomersController — iki müşteriyi birleştir (mergee → target).

Oturum
İstek
curl -X POST "https://{slug}.crm.blesyum.app/api/crm/v1/customers/merge" \
  -H "Authorization: Bearer <oturum-token>" \
  -H "Accept: application/json"
Yanıt
{
  "data": "…",
  "trace_id": "01JC…"
}
Bu sayfa işine yaradı mı?