feat(FN-343): remove lingering iyzico references after Stripe migration (+1 more)
Commits merged: - chore(FN-343): remove lingering iyzico references from docs, config, and scripts - feat(FN-343): remove lingering iyzico references after Stripe migration Files changed: CLAUDE.md | 10 +++++----- README.md | 2 +- apps/api/src/database/schema/core.ts | 1 + apps/web/src/messages/en.json | 1 - apps/web/src/messages/tr.json | 1 - apps/web/src/routes/dashboard/billing.tsx | 6 +++--- docker-compose.coolify.yml | 5 ++--- docs/INDEX.md | 27 ++++++++++++------------- knowledge.md | 30 ++++++++++++++-------------- packages/shared/src/constants/error-codes.ts | 1 - packages/shared/src/index.ts | 1 - packages/shared/src/types/payment.ts | 12 +---------- scripts/fn342-pw-verify.mjs | 2 +- scripts/validate-env.sh | 3 +-- 14 files changed, 43 insertions(+), 59 deletions(-) Fusion-Task-Id: FN-343
This commit is contained in:
10
CLAUDE.md
10
CLAUDE.md
@@ -15,7 +15,7 @@
|
||||
| **Frontend** | Vite 6.3, React 19, TanStack Router 1.120, TanStack Query 5 |
|
||||
| **Styling** | Tailwind CSS 4, shadcn/ui (Radix primitives) |
|
||||
| **State** | Zustand 5 |
|
||||
| **Payments** | Iyzico (card) + EFT (bank transfer) |
|
||||
| **Payments** | Stripe (card) + EFT (bank transfer) |
|
||||
| **Email** | Postal (transactional) |
|
||||
| **Storage** | MinIO (S3-compatible) |
|
||||
| **Analytics** | PostHog (product analytics) |
|
||||
@@ -106,7 +106,7 @@ pnpm --filter web exec tsr generate
|
||||
| **BrandsModule** | Brand CRUD (cached, admin-managed) |
|
||||
| **PlansModule** | Pricing plan CRUD (cached, admin-managed) |
|
||||
| **SubscriptionsModule** | Create, activate, cancel, resume, extend subscriptions |
|
||||
| **PaymentsModule** | Iyzico card + EFT with receipt upload + admin approval |
|
||||
| **PaymentsModule** | Stripe card + EFT with receipt upload + admin approval |
|
||||
| **ReferralsModule** | Referral code generation, tier-based rewards |
|
||||
| **VehiclesModule** | VIN decode (multi-source fallback), vehicle history, brand access check |
|
||||
| **CategoriesModule** | Hierarchical category tree, schema pictures |
|
||||
@@ -186,7 +186,7 @@ Our PL24 account (tr-903645) supports **VAG group only** for VIN-less catalog. O
|
||||
- `brands`, `plans` — Catalog of available brands/plans (admin-managed)
|
||||
- `userSubscriptions` — status: pending/active/trial/cancelled/expired
|
||||
- `userBrands` — junction table controlling brand access per subscription
|
||||
- `payments` — Iyzico or EFT, status tracking
|
||||
- `payments` — Stripe or EFT, status tracking
|
||||
- `vehicles` — one per unique VIN, shared across users via `userVehicles`
|
||||
- `userVehicles` — junction (userId + vehicleId unique), tracks lastAccessedAt
|
||||
- `categories` — parent-child hierarchy; has both `vehicleId` (VIN-based) and `catalogVehicleId` (VIN-less) FKs (nullable for the other mode)
|
||||
@@ -218,7 +218,7 @@ Our PL24 account (tr-903645) supports **VAG group only** for VIN-less catalog. O
|
||||
- `/dashboard/search` — VIN decode input
|
||||
- `/dashboard/history` — Past VIN searches
|
||||
- `/dashboard/subscription` — Plan/brand selection
|
||||
- `/dashboard/subscription/pay` — Payment (Iyzico or EFT)
|
||||
- `/dashboard/subscription/pay` — Payment (Stripe or EFT)
|
||||
- `/dashboard/billing` — Payment history
|
||||
- `/dashboard/settings` — Profile, Security, Connections, Referral tabs
|
||||
- `/dashboard/vehicles/$id` — Vehicle details
|
||||
@@ -252,7 +252,7 @@ Our PL24 account (tr-903645) supports **VAG group only** for VIN-less catalog. O
|
||||
**Optional (grouped):**
|
||||
- `PORT` (4000), `REDIS_HOST` (127.0.0.1), `REDIS_PORT` (6379), `MINIO_BUCKET_NAME` (sase-schemas), `MINIO_USE_SSL` (false)
|
||||
- `GOOGLE_CLIENT_ID/SECRET` — Google OAuth
|
||||
- `IYZICO_API_KEY/SECRET_KEY/BASE_URL` — Payment processing
|
||||
- `STRIPE_SECRET_KEY/PUBLISHABLE_KEY` — Payment processing
|
||||
- `PL24_BASE_URL/COMPANY_CODE/USERNAME/PASSWORD` — PL24 catalog API
|
||||
- `EMEX_USERNAME/PASSWORD` — EMEX scraper
|
||||
- `PCAT_USE_PROXY` (true), `PCAT_PROXY_HOST` (gw.dataimpulse.com), `PCAT_PROXY_USER/PASS` — PartsCatalogs proxy
|
||||
|
||||
@@ -16,7 +16,7 @@ VIN/şase numarası sorgulama ve otomotiv yedek parça katalog platformu (Türki
|
||||
| Auth | Better Auth (cookie session) |
|
||||
| Frontend | Vite 6, React 19, TanStack Router + Query |
|
||||
| UI | Tailwind v4, shadcn/ui (Radix) |
|
||||
| Ödeme | Iyzico (kart) + EFT |
|
||||
| Ödeme | Stripe (kart) + EFT |
|
||||
| Email | Postal |
|
||||
| Storage | MinIO (S3) |
|
||||
| Analitik | PostHog |
|
||||
|
||||
@@ -199,6 +199,7 @@ export const payments = pgTable(
|
||||
currency: varchar("currency", { length: 3 }).default("TRY").notNull(),
|
||||
method: varchar("method", { length: 20 }).notNull(),
|
||||
status: varchar("status", { length: 20 }).default("pending").notNull(),
|
||||
/** @deprecated Replaced by stripeSessionId/stripePaymentIntentId after Stripe migration (May 2026). Kept for historical data. */
|
||||
iyzicoPaymentId: text("iyzico_payment_id"),
|
||||
stripeSessionId: text("stripe_session_id"),
|
||||
stripePaymentIntentId: text("stripe_payment_intent_id"),
|
||||
|
||||
@@ -361,7 +361,6 @@
|
||||
"refunded": "Refunded"
|
||||
},
|
||||
"methodLabels": {
|
||||
"iyzico": "Credit Card",
|
||||
"stripe": "Credit Card",
|
||||
"eft": "EFT/Wire"
|
||||
}
|
||||
|
||||
@@ -361,7 +361,6 @@
|
||||
"refunded": "İade"
|
||||
},
|
||||
"methodLabels": {
|
||||
"iyzico": "Kredi Kartı",
|
||||
"stripe": "Kredi Kartı",
|
||||
"eft": "EFT/Havale"
|
||||
}
|
||||
|
||||
@@ -18,7 +18,7 @@ export const Route = createFileRoute("/dashboard/billing")({
|
||||
interface Payment {
|
||||
id: string;
|
||||
amount: number;
|
||||
method: "iyzico" | "eft";
|
||||
method: "stripe" | "eft";
|
||||
status: "completed" | "pending" | "failed" | "refunded";
|
||||
planName?: string;
|
||||
receiptUrl?: string;
|
||||
@@ -77,7 +77,7 @@ function BillingPage() {
|
||||
|
||||
{/* Method Filter */}
|
||||
<div className="flex gap-1">
|
||||
{["all", "iyzico", "eft"].map((method) => (
|
||||
{["all", "stripe", "eft"].map((method) => (
|
||||
<Button
|
||||
key={method}
|
||||
variant={methodFilter === method ? "default" : "outline"}
|
||||
@@ -149,7 +149,7 @@ function BillingPage() {
|
||||
|
||||
{/* Method */}
|
||||
<div className="text-center">
|
||||
<Badge variant={payment.method === "iyzico" ? "secondary" : "outline"}>
|
||||
<Badge variant={payment.method === "stripe" ? "secondary" : "outline"}>
|
||||
{t(`billing.methodLabels.${payment.method}`)}
|
||||
</Badge>
|
||||
</div>
|
||||
|
||||
@@ -25,9 +25,8 @@ services:
|
||||
- MINIO_PUBLIC_URL=${MINIO_PUBLIC_URL}
|
||||
- MINIO_USE_SSL=false
|
||||
- CORS_ORIGIN=${CORS_ORIGIN}
|
||||
- IYZICO_API_KEY=${IYZICO_API_KEY:-}
|
||||
- IYZICO_SECRET_KEY=${IYZICO_SECRET_KEY:-}
|
||||
- IYZICO_BASE_URL=${IYZICO_BASE_URL:-}
|
||||
- STRIPE_SECRET_KEY=${STRIPE_SECRET_KEY:-}
|
||||
- STRIPE_PUBLISHABLE_KEY=${STRIPE_PUBLISHABLE_KEY:-}
|
||||
- PL24_BASE_URL=${PL24_BASE_URL:-https://www.partslink24.com}
|
||||
- PL24_COMPANY_CODE=${PL24_COMPANY_CODE:-}
|
||||
- PL24_USERNAME=${PL24_USERNAME:-}
|
||||
|
||||
@@ -74,7 +74,7 @@ Generated: 2026-03-02
|
||||
| **Database** | PostgreSQL 17, Drizzle ORM 0.41 |
|
||||
| **Cache** | Redis 7.4, ioredis |
|
||||
| **Auth** | Better Auth 1.2 (email/password + Google OAuth) |
|
||||
| **Payments** | Iyzico (card), EFT (bank transfer with receipt upload) |
|
||||
| **Payments** | Stripe (card), EFT (bank transfer with receipt upload) |
|
||||
| **Storage** | MinIO (S3-compatible) |
|
||||
| **Jobs** | BullMQ (Redis-backed queues) |
|
||||
| **Email** | Postal (transactional email) |
|
||||
@@ -103,7 +103,7 @@ sase.tr/
|
||||
│ │ │ ├── brands/ # Brand CRUD
|
||||
│ │ │ ├── plans/ # Pricing plan CRUD
|
||||
│ │ │ ├── subscriptions/ # Subscription lifecycle
|
||||
│ │ │ ├── payments/ # Iyzico + EFT payment processing
|
||||
│ │ │ ├── payments/ # Stripe + EFT payment processing
|
||||
│ │ │ ├── referrals/ # Referral program
|
||||
│ │ │ ├── vehicles/ # VIN decoding + vehicle history
|
||||
│ │ │ ├── categories/ # Parts category tree
|
||||
@@ -192,7 +192,7 @@ sase.tr/
|
||||
| **BrandsModule** | module, service, controller, spec | Brand CRUD (cached, admin-managed) |
|
||||
| **PlansModule** | module, service, controller, spec | Pricing plan CRUD (cached, admin-managed) |
|
||||
| **SubscriptionsModule** | module, service, controller, spec | Create, activate, cancel, resume, extend subscriptions |
|
||||
| **PaymentsModule** | module, service, controller, spec | Iyzico card payments, EFT with receipt upload, admin approval |
|
||||
| **PaymentsModule** | module, service, controller, spec | Stripe card payments, EFT with receipt upload, admin approval |
|
||||
| **ReferralsModule** | module, service, controller, spec | Referral code generation, application, tier-based rewards |
|
||||
| **VehiclesModule** | module, service, controller, spec | VIN decode (multi-source fallback), vehicle history, brand access check |
|
||||
| **CategoriesModule** | module, service, controller, spec | Hierarchical category tree, schema pictures |
|
||||
@@ -244,7 +244,7 @@ sase.tr/
|
||||
| **PartsCatalogs** | REST API | `parts-catalogs/` | Multi-brand catalog API. Files: service, auth-service, module, types. Supports fetchGroups, fetchParts with parameterized car queries |
|
||||
| **EMEX** | Browser scraper | `emex/` | Playwright-based (emexdwc.ae), async via BullMQ. Files: service, browser, mapper, types |
|
||||
| **VIN-API** | REST API | `vin-api/` | NHTSA VIN decoder (last-resort fallback) |
|
||||
| **Iyzico** | Payment API | — | Turkish payment processor for card payments |
|
||||
| **Stripe** | Payment API | — | Global payment processor for card payments |
|
||||
| **MinIO** | S3 API | — | Receipt uploads, schema images |
|
||||
|
||||
### Database Schema
|
||||
@@ -291,8 +291,8 @@ userBrands (junction)
|
||||
|
||||
payments
|
||||
├── id (uuid, PK), userId → users, subscriptionId → userSubscriptions
|
||||
├── amount, currency, method (iyzico/eft), status (pending/completed/failed/refunded)
|
||||
├── iyzicoPaymentId, eftReceiptUrl, adminNote
|
||||
├── amount, currency, method (stripe/eft), status (pending/completed/failed/refunded)
|
||||
├── stripePaymentIntentId, eftReceiptUrl, adminNote
|
||||
└── Indexes: userId, status
|
||||
|
||||
vehicles
|
||||
@@ -467,8 +467,8 @@ Instrumentation: Express, HTTP, ioredis, NestJS Core, BullMQ, Drizzle ORM
|
||||
#### Payments
|
||||
| Method | Path | Auth | Description |
|
||||
|--------|------|------|-------------|
|
||||
| `POST` | `/api/payments/iyzico/initialize` | User | Start Iyzico card payment |
|
||||
| `POST` | `/api/payments/iyzico/callback` | Public | Iyzico webhook callback |
|
||||
| `POST` | `/api/payments/stripe/checkout` | User | Start Stripe card payment |
|
||||
| `POST` | `/api/payments/stripe/webhook` | Public | Stripe webhook callback |
|
||||
| `POST` | `/api/payments/eft` | User | Create EFT payment |
|
||||
| `POST` | `/api/payments/eft/:id/receipt` | User | Upload EFT receipt (PNG/JPG/PDF, 5MB max) |
|
||||
| `PATCH` | `/api/payments/eft/:id/approve` | Admin | Approve EFT payment |
|
||||
@@ -601,7 +601,7 @@ Flow:
|
||||
| `/dashboard/search` | `routes/dashboard/search.tsx` | VIN Search — main VIN decoder input |
|
||||
| `/dashboard/history` | `routes/dashboard/history.tsx` | Past VIN decode searches |
|
||||
| `/dashboard/subscription` | `routes/dashboard/subscription/index.tsx` | Plan selection & brand picker |
|
||||
| `/dashboard/subscription/pay` | `routes/dashboard/subscription/pay.tsx` | Card (Iyzico) or EFT payment |
|
||||
| `/dashboard/subscription/pay` | `routes/dashboard/subscription/pay.tsx` | Card (Stripe) or EFT payment |
|
||||
| `/dashboard/billing` | `routes/dashboard/billing.tsx` | Payment history & receipts |
|
||||
| `/dashboard/settings` | `routes/dashboard/settings.tsx` | Profile, Security, Connections, Referral, Account, Changelog tabs |
|
||||
| `/dashboard/vehicles/$id` | `routes/dashboard/vehicles_/$id/index.tsx` | Vehicle details |
|
||||
@@ -705,7 +705,7 @@ Flow:
|
||||
|
||||
| Directory | Exports |
|
||||
|-----------|---------|
|
||||
| `types/` | User, UserProfile, UserSubscriptionSummary, Vehicle, VinDecodeResult, CategoryNode, VehicleSource, Brand, Plan, Subscription, UserBrand, CreateSubscriptionInput, SubscriptionStatus, Payment, PaymentMethod, PaymentStatus, IyzicoInitializeInput, EftPaymentInput, Part, PartSource, PartSearchResult, Category, CategoryWithSchema, SchemaPic, Hotspot, ApiResponse, ApiError, PaginationMeta, PaginationInput, PaginatedResult, ChangelogEntry, CreateChangelogEntry, UpdateChangelogEntry, ChangelogChangeType |
|
||||
| `types/` | User, UserProfile, UserSubscriptionSummary, Vehicle, VinDecodeResult, CategoryNode, VehicleSource, Brand, Plan, Subscription, UserBrand, CreateSubscriptionInput, SubscriptionStatus, Payment, PaymentMethod, PaymentStatus, EftPaymentInput, Part, PartSource, PartSearchResult, Category, CategoryWithSchema, SchemaPic, Hotspot, ApiResponse, ApiError, PaginationMeta, PaginationInput, PaginatedResult, ChangelogEntry, CreateChangelogEntry, UpdateChangelogEntry, ChangelogChangeType |
|
||||
| `schemas/` | loginSchema, registerSchema, forgotPasswordSchema, resetPasswordSchema, vinSchema, paginationSchema, changelogEntrySchema, createChangelogEntrySchema, updateChangelogEntrySchema, changelogChangeTypeEnum (Zod) |
|
||||
| `constants/` | ERROR_CODES (30+, prefixed AUTH/VIN/SUB/PAY), PLANS (Single/Double/Triple/Full), REFERRAL_REWARDS (Tier 1: 3→7d, Tier 2: 5→30d), VIN_REGEX, EMAIL_REGEX, OEM_CODE_REGEX, CURRENCY |
|
||||
| `utils/` | VIN validator (check digit, WMI extraction, model year decode), currency (formatTRY, kurus↔lira), formatters (VIN, date, datetime, Turkish slug, referral code) |
|
||||
@@ -715,7 +715,7 @@ Flow:
|
||||
### @sase/config (`packages/config/src/index.ts`)
|
||||
|
||||
Zod env schema exporting `envSchema`, `Env` type, `validateEnv()`.
|
||||
Groups: DATABASE_URL, REDIS_*, BETTER_AUTH_*, GOOGLE_*, MINIO_*, CORS_ORIGIN, IYZICO_*, PL24_*, EMEX_*, ML_PREDICTION_ENABLED, POSTAL_*, OTEL_*
|
||||
Groups: DATABASE_URL, REDIS_*, BETTER_AUTH_*, GOOGLE_*, MINIO_*, CORS_ORIGIN, STRIPE_*, PL24_*, EMEX_*, ML_PREDICTION_ENABLED, POSTAL_*, OTEL_*
|
||||
|
||||
### @sase/ui (`packages/ui/src/`)
|
||||
|
||||
@@ -827,9 +827,8 @@ Dependencies: Radix UI (accordion, dialog, dropdown-menu, label, popover, select
|
||||
| `MINIO_USE_SSL` | false | HTTPS for MinIO |
|
||||
| `GOOGLE_CLIENT_ID` | — | Google OAuth client ID |
|
||||
| `GOOGLE_CLIENT_SECRET` | — | Google OAuth secret |
|
||||
| `IYZICO_API_KEY` | — | Iyzico payment API key |
|
||||
| `IYZICO_SECRET_KEY` | — | Iyzico payment secret |
|
||||
| `IYZICO_BASE_URL` | — | Iyzico API base URL |
|
||||
| `STRIPE_SECRET_KEY` | — | Stripe payment secret key |
|
||||
| `STRIPE_PUBLISHABLE_KEY` | — | Stripe publishable key |
|
||||
| `PL24_BASE_URL` | — | PL24 catalog API URL |
|
||||
| `PL24_COMPANY_CODE` | — | PL24 company code |
|
||||
| `PL24_USERNAME` | — | PL24 credentials |
|
||||
|
||||
30
knowledge.md
30
knowledge.md
@@ -15,7 +15,7 @@ SASE v2, araç sahiplerinin VIN numarasını girerek aracın markasını, modeli
|
||||
- OEM kod arama ve kopyalama
|
||||
- VIN-less katalog tarayıcısı (marka → model → kategori)
|
||||
- Abonelik yönetimi: marka bazlı erişim kontrolü
|
||||
- Iyzico kart + EFT ödeme yöntemleri
|
||||
- Stripe kart + EFT ödeme yöntemleri
|
||||
- Referral sistemi
|
||||
|
||||
---
|
||||
@@ -37,7 +37,7 @@ SASE v2, araç sahiplerinin VIN numarasını girerek aracın markasını, modeli
|
||||
| Auth | Better Auth | 1.2 |
|
||||
| Dosya Depolama | MinIO (S3) | — |
|
||||
| E-posta | Postal | — |
|
||||
| Ödeme | Iyzico | — |
|
||||
| Ödeme | Stripe | — |
|
||||
| Browser Otomasyon | Playwright | 1.50 |
|
||||
| HTTP İstemci | undici | 7.22 |
|
||||
| Rate Limiting | @nestjs/throttler | 6.3 |
|
||||
@@ -89,7 +89,7 @@ ss/ (repo root)
|
||||
│ │ ├── brands/ # Marka CRUD
|
||||
│ │ ├── plans/ # Fiyat planları CRUD
|
||||
│ │ ├── subscriptions/ # Abonelik yaşam döngüsü
|
||||
│ │ ├── payments/ # Iyzico + EFT ödeme
|
||||
│ │ ├── payments/ # Stripe + EFT ödeme
|
||||
│ │ ├── referrals/ # Referral programı
|
||||
│ │ ├── vehicles/ # VIN decode + araç geçmişi
|
||||
│ │ ├── categories/ # Parça kategorisi ağacı
|
||||
@@ -281,9 +281,9 @@ ss/ (repo root)
|
||||
| subscriptionId | uuid | NOT NULL, FK → userSubscriptions.id |
|
||||
| amount | integer | NOT NULL (kuruş) |
|
||||
| currency | varchar(3) | default "TRY" |
|
||||
| method | varchar(20) | NOT NULL → "iyzico" \| "eft" |
|
||||
| method | varchar(20) | NOT NULL → "stripe" \| "eft" |
|
||||
| status | varchar(20) | default "pending" → "pending" \| "completed" \| "failed" \| "refunded" |
|
||||
| iyzicoPaymentId | text | nullable |
|
||||
| stripePaymentIntentId | text | nullable |
|
||||
| eftReceiptUrl | text | nullable |
|
||||
| adminNote | text | nullable |
|
||||
| createdAt | timestamptz | default now() |
|
||||
@@ -631,8 +631,8 @@ Better Auth dahili route'ları: `POST /api/auth/sign-in/email`, `POST /api/auth/
|
||||
|
||||
| Method | Path | Auth | Açıklama | Body |
|
||||
|--------|------|------|---------|------|
|
||||
| `POST` | `/payments/iyzico/initialize` | Protected | Iyzico ödeme başlat | `{ planKey, billingPeriod, brandIds[] }` |
|
||||
| `POST` | `/payments/iyzico/callback` | Public | Iyzico webhook | `{ paymentId, iyzicoPaymentId, status }` |
|
||||
| `POST` | `/payments/stripe/checkout` | Protected | Stripe ödeme başlat | `{ planKey, billingPeriod, brandIds[] }` |
|
||||
| `POST` | `/payments/stripe/webhook` | Public | Stripe webhook | `{ type, data }` |
|
||||
| `POST` | `/payments/eft` | Protected | EFT ödeme oluştur | `{ planKey, billingPeriod, brandIds[] }` |
|
||||
| `POST` | `/payments/eft/:id/receipt` | Protected | EFT makbuz yükle (multipart, PNG/JPG/PDF max 5MB) | `file` |
|
||||
| `PATCH` | `/payments/eft/:id/approve` | Admin | EFT ödeme onayla | `{ adminNote? }` |
|
||||
@@ -817,7 +817,7 @@ Better Auth dahili route'ları: `POST /api/auth/sign-in/email`, `POST /api/auth/
|
||||
| SUB_003 | Abonelik | Geçersiz marka sayısı |
|
||||
| SUB_004 | Abonelik | Abonelik zaten aktif |
|
||||
| PAY_001 | Ödeme | Ödeme başarısız |
|
||||
| PAY_002 | Ödeme | Iyzico hatası |
|
||||
| PAY_002 | Ödeme | Stripe hatası |
|
||||
| PAY_003 | Ödeme | EFT makbuzu gerekli |
|
||||
| PAY_004 | Ödeme | Ödeme zaten işlenmiş |
|
||||
| GEN_001 | Genel | Bulunamadı |
|
||||
@@ -864,10 +864,10 @@ cancelled → (yeniden başlatma, süre içinde) → active
|
||||
|
||||
### Ödeme Akışı
|
||||
|
||||
**Iyzico (Kart):**
|
||||
1. `POST /payments/iyzico/initialize` → Iyzico token alınır
|
||||
2. Kullanıcı iyzico formunda ödeme yapar
|
||||
3. `POST /payments/iyzico/callback` webhook'u aboneliği aktifleştirir
|
||||
**Stripe (Kart):**
|
||||
1. `POST /payments/stripe/checkout` → Stripe Checkout Session oluşturulur
|
||||
2. Kullanıcı Stripe ödeme sayfasına yönlendirilir
|
||||
3. `POST /payments/stripe/webhook` webhook'u aboneliği aktifleştirir
|
||||
|
||||
**EFT (Havale):**
|
||||
1. `POST /payments/eft` → EFT kaydı oluşturulur, banka bilgileri gösterilir
|
||||
@@ -1229,8 +1229,8 @@ Plan { id, name, brandCount, priceMonthly, priceYearly, isActive, createdAt }
|
||||
Subscription { id, userId, planId, status, startDate, endDate, cancelledAt, createdAt }
|
||||
SubscriptionStatus = "pending" | "active" | "cancelled" | "expired"
|
||||
UserBrand { id, userId, subscriptionId, brandId, createdAt }
|
||||
Payment { id, userId, subscriptionId, amount, currency, method, status, iyzicoPaymentId, eftReceiptUrl, adminNote, createdAt }
|
||||
PaymentMethod = "iyzico" | "eft"
|
||||
Payment { id, userId, subscriptionId, amount, currency, method, status, stripePaymentIntentId, eftReceiptUrl, adminNote, createdAt }
|
||||
PaymentMethod = "stripe" | "eft"
|
||||
PaymentStatus = "pending" | "completed" | "failed" | "refunded"
|
||||
CreateSubscriptionInput { planId, brandIds: string[], billingPeriod }
|
||||
|
||||
@@ -1356,7 +1356,7 @@ shadcn/Radix tabanlı bileşen kütüphanesi.
|
||||
| Değişken | Grup | Açıklama |
|
||||
|---------|------|---------|
|
||||
| `GOOGLE_CLIENT_ID`, `GOOGLE_CLIENT_SECRET` | OAuth | Google OAuth |
|
||||
| `IYZICO_API_KEY`, `IYZICO_SECRET_KEY`, `IYZICO_BASE_URL` | Ödeme | Iyzico entegrasyonu |
|
||||
| `STRIPE_SECRET_KEY`, `STRIPE_PUBLISHABLE_KEY` | Ödeme | Stripe entegrasyonu |
|
||||
| `PL24_BASE_URL`, `PL24_COMPANY_CODE`, `PL24_USERNAME`, `PL24_PASSWORD` | PL24 | PL24 katalog API |
|
||||
| `EMEX_USERNAME`, `EMEX_PASSWORD` | EMEX | EMEX scraper |
|
||||
| `PCAT_PROXY_USER`, `PCAT_PROXY_PASS` | PartsCatalogs | Playwright proxy |
|
||||
|
||||
@@ -19,7 +19,6 @@ export const ERROR_CODES = {
|
||||
|
||||
// Payment
|
||||
PAYMENT_FAILED: "PAY_001",
|
||||
IYZICO_ERROR: "PAY_002",
|
||||
EFT_RECEIPT_REQUIRED: "PAY_003",
|
||||
PAYMENT_ALREADY_PROCESSED: "PAY_004",
|
||||
|
||||
|
||||
@@ -15,7 +15,6 @@ export type {
|
||||
Payment,
|
||||
PaymentMethod,
|
||||
PaymentStatus,
|
||||
IyzicoInitializeInput,
|
||||
EftPaymentInput,
|
||||
} from "./types/payment.js";
|
||||
export type { ApiResponse, ApiError, PaginationMeta } from "./types/api-response.js";
|
||||
|
||||
@@ -6,25 +6,15 @@ export interface Payment {
|
||||
currency: string;
|
||||
method: PaymentMethod;
|
||||
status: PaymentStatus;
|
||||
iyzicoPaymentId: string | null;
|
||||
eftReceiptUrl: string | null;
|
||||
adminNote: string | null;
|
||||
createdAt: Date;
|
||||
updatedAt: Date;
|
||||
}
|
||||
|
||||
export type PaymentMethod = "iyzico" | "eft";
|
||||
export type PaymentMethod = "stripe" | "eft";
|
||||
export type PaymentStatus = "pending" | "completed" | "failed" | "refunded";
|
||||
|
||||
export interface IyzicoInitializeInput {
|
||||
subscriptionId: string;
|
||||
cardHolderName: string;
|
||||
cardNumber: string;
|
||||
expireMonth: string;
|
||||
expireYear: string;
|
||||
cvc: string;
|
||||
}
|
||||
|
||||
export interface EftPaymentInput {
|
||||
subscriptionId: string;
|
||||
}
|
||||
|
||||
@@ -232,7 +232,7 @@ async function verifyP0_7_TrustCopy(page) {
|
||||
// Check for trust indicators
|
||||
const trustChecks = [
|
||||
{ key: "SSL", text: /256-bit SSL|SSL/i },
|
||||
{ key: "Provider", text: /Iyzico|iyzico|altyapı/i },
|
||||
{ key: "Provider", text: /Stripe|stripe|altyapı/i },
|
||||
{ key: "KVKK", text: /KVKK/i },
|
||||
];
|
||||
|
||||
|
||||
@@ -97,8 +97,7 @@ echo ""
|
||||
# ── Optional variables (warn if missing) ──
|
||||
log "Checking optional variables (warnings only)..."
|
||||
|
||||
for var in IYZICO_API_KEY IYZICO_SECRET_KEY IYZICO_BASE_URL \
|
||||
PL24_API_URL PL24_USERNAME PL24_PASSWORD \
|
||||
for var in PL24_API_URL PL24_USERNAME PL24_PASSWORD \
|
||||
EMEX_USERNAME EMEX_PASSWORD; do
|
||||
if [ -z "${!var:-}" ]; then
|
||||
log "WARNING: $var is not set (optional)"
|
||||
|
||||
Reference in New Issue
Block a user