Corporate
Kurumsal kullanıcı yönetimi endpoint'leri.
Kurumsal Başvuruları Getir
Kurumsal hesap başvurularını listeler.
Authentication
x-auth (tenant-id)
HTTP Request
GET /admin/get-corporate-application
Request Parameters
| Field | Type | Required | Default | Desc |
|---|---|---|---|---|
body | object | false | {} | Filtreleme parametreleri |
Response Parameters
| Field | Type | Nullable | Desc |
|---|---|---|---|
id | string | false | Başvuru ID |
companyName | string | false | Şirket adı |
taxNumber | string | false | Vergi numarası |
status | string | false | Başvuru durumu |
createdAt | date | false | Başvuru tarihi |
Kurumsal Kullanıcıları Getir
Kurumsal kullanıcıları listeler.
Authentication
x-auth (tenant-id)
HTTP Request
GET /admin/get-corporate-users
Request Parameters
| Field | Type | Required | Default | Desc |
|---|---|---|---|---|
userId | string | false | - | Kullanıcı ID filtresi |
corporateUserId | string | false | - | Kurumsal kullanıcı ID |
status | string | false | - | Durum filtresi |
Response Parameters
| Field | Type | Nullable | Desc |
|---|---|---|---|
id | string | false | Kayıt ID |
userId | string | false | Kullanıcı ID |
corporateUserId | string | false | Kurumsal entity ID |
role | string | false | Kurumsal rol |
status | string | false | Durum |
email | string | true | E-posta adresi |
Kurumsal Kullanıcı Ekle
Yeni bir kurumsal kullanıcı oluşturur.
Authentication
x-auth (tenant-id)
HTTP Request
POST /admin/insert-corporate-user
Request Parameters
| Field | Type | Required | Default | Desc |
|---|---|---|---|---|
userId | string | false | - | Mevcut kullanıcı ID (yoksa yeni oluşturulur) |
corporateUserId | string | true | - | Kurumsal entity ID |
status | string | true | - | Kullanıcı durumu |
role | string | true | - | Kurumsal rol |
countryCode | string | true | - | Ülke kodu |
phoneNumber | string | true | - | Telefon numarası |
email | string | true | - | E-posta adresi |
Request Body Example
{
"corporateUserId": "corp_123",
"status": "active",
"role": "admin",
"countryCode": "90",
"phoneNumber": "5551234567",
"email": "admin@company.com"
}
Response Parameters
| Field | Type | Nullable | Desc |
|---|---|---|---|
id | string | true | Oluşturulan kurumsal kullanıcı ID |
message | string | true | Hata mesajı |
İşlem Akışı
- Zorunlu alanlar doğrulanır
- userId verilmediyse yeni kullanıcı oluşturulur:
- Varsayılan telefon: "111111111"
- Varsayılan ülke kodu: "90"
- Varsayılan şifre: hashlenmiş "123456"
- Kampanya izinleri: tümü false
- Kullanıcı kurumsal entity'ye bağlanır
Kurumsal Kullanıcı Güncelle
Mevcut kurumsal kullanıcıyı günceller.
Authentication
x-auth (tenant-id)
HTTP Request
POST /admin/update-corporate-user
Request Parameters
| Field | Type | Required | Default | Desc |
|---|---|---|---|---|
id | string | true | - | Kurumsal kullanıcı kayıt ID |
userId | string | false | - | Kullanıcı ID referansı |
corporateUserId | string | false | - | Kurumsal entity ID |
status | string | false | - | Kullanıcı durumu |
role | string | false | - | Kurumsal rol |
countryCode | string | false | - | Ülke kodu |
phoneNumber | string | false | - | Telefon numarası |
email | string | false | - | E-posta adresi |
Request Body Example
{
"id": "corp_user_456",
"status": "inactive",
"role": "viewer"
}
Response Parameters
| Field | Type | Nullable | Desc |
|---|---|---|---|
message | string | true | Hata mesajı |
Notlar
idalanı zorunludur- En az bir güncelleme alanı (corporateUserId, status, role, countryCode, phoneNumber veya email) gereklidir
- Sadece belirtilen alanlar güncellenir (kısmi güncelleme desteklenir)