> ## Documentation Index
> Fetch the complete documentation index at: https://docs.whop.com/llms.txt
> Use this file to discover all available pages before exploring further.

> ## Agent Instructions
> Treat these docs and the Whop MCP server as the source of truth for Whop API behavior. Don't infer endpoint behavior from marketing pages.
> MCP server: connect https://mcp.whop.com/mcp (streamable HTTP, browser sign-in, no API key in the client config) to search these docs and read or change live Whop data. Setup: https://docs.whop.com/developer/guides/ai_and_mcp.md
> Whop CLI: install with `curl -fsSL https://whop.com/install.sh | sh` to scaffold, run, and deploy Whop apps and websites. It acts on production, not the sandbox. Overview: https://docs.whop.com/cli/overview.md Agent mode: https://docs.whop.com/cli/agent-mode.md
> Hosting: Whop serves a site or app from the build `whop apps deploy` uploads, with rollbacks, secrets, and server logs. Guide: https://docs.whop.com/developer/websites/hosting.md
> Plugins: in Claude Code, run `/plugin marketplace add whopio/plugins`, then `/plugin install whop@whop`. Guide: https://docs.whop.com/developer/guides/plugins/claude-code.md Every agent tool: https://docs.whop.com/developer/ai/overview.md
> Environments: build and test in the sandbox (API `https://sandbox-api.whop.com/api/v1`, keys at https://sandbox.whop.com/dashboard/developer, SDK environment `Sandbox`; no real money). Production (API `https://api.whop.com/api/v1`, keys at https://whop.com/dashboard/developer, SDK environment `Production`, the SDK default) moves real money, so use it only at launch. The two share no accounts, keys, products, or webhooks, and their keys look identical: never mix them. Sandbox guide: https://docs.whop.com/developer/guides/sandbox.md Comparison: https://docs.whop.com/developer/quickstart.md
> API: send `Authorization: Bearer <API_KEY>` from your server only, and pin a dated version with the `Api-Version-Date` header. OpenAPI spec: https://api.whop.com/api/v1/openapi.json
> Which API: build on the Current API, whose pages live under https://docs.whop.com/api-reference/ (start at https://docs.whop.com/api-reference/overview.md). Pages under /api-reference/legacy/ are the Legacy API. Use one only when https://docs.whop.com/api-reference/stability.md lists the resource as Legacy-only.

# Anlık bildirimler

> Uygulamanızdaki kullanıcılara deneyime veya hesaba göre kapsamlandırılmış anlık bildirimler gönderin.

Uygulamanızdaki kullanıcılara anlık bildirimler gönderin. Bildirimler Whop mobil uygulamasında ve web arayüzünde görünür.

## Bildirim türünüzü seçin

| | Deneyim bildirimi | Hesap bildirimi |
| - | - | - |
| **Hedef kitle** | Bir deneyime erişimi olan kullanıcılar | Bir hesabın ekip üyeleri |
| **En uygun olduğu durum** | Müşteriye yönelik uygulamalar (uyarılar, sosyal, fitness) | Pano uygulamaları (yönetici işlemleri, raporlar, uyarılar) |
| **Zorunlu anahtar alan** | `experience_id` | `account_id` |
| **Belirli kullanıcılara filtreleme** | `user_ids` (deneyim erişimi olmalı) | `user_ids` (ekip üyesi olmalı) |

> [!NOTE]
>
> Bildirim göndermek için `notification:create` izni gerekir. Bunu [İzinler kılavuzundan](https://docs.whop.com/tr/developer/guides/permissions.md) ekleyin. Deneyim uygulamanıza ait olmalı veya hesapta uygulamanız yüklü olmalıdır.

## Bir deneyimdeki herkese gönderin

Bir deneyime erişimi olan tüm kullanıcılara bildirim gönderin:

```typescript TypeScript theme={null}
const result = await client.notifications.create({
  experience_id: 'exp_xxxxxxxxxxxxxx',
  title: 'New Feature Available',
  subtitle: 'Check it out now',
  content: 'We just released a new feature that helps you track your progress better.',
});

console.log(result.success); // true

```

```python Python theme={null}
result = client.notifications.create(
    experience_id="exp_xxxxxxxxxxxxxx",
    title="New Feature Available",
    subtitle="Check it out now",
    content="We just released a new feature that helps you track your progress better.",
)

print(result.success)  # True
```

```ruby Ruby theme={null}
result = client.notifications.create(
  experience_id: "exp_xxxxxxxxxxxxxx",
  title: "New Feature Available",
  subtitle: "Check it out now",
  content: "We just released a new feature that helps you track your progress better."
)

puts result.success  # true
```

```rust Rust theme={null}
let result = client
    .notifications
    .create(
        &CreateNotificationsRequest {
            experience_id: Some("exp_xxxxxxxxxxxxxx".to_string()),
            title: "New Feature Available".to_string(),
            subtitle: Some("Check it out now".to_string()),
            content: "We just released a new feature that helps you track your progress better."
                .to_string(),
            ..Default::default()
        },
        None,
    )
    .await?;

println!("{}", result.success); // true
```

```go Go theme={null}
result, err := client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    ExperienceID: whopsdk.String("exp_xxxxxxxxxxxxxx"),
    Title:        "New Feature Available",
    Subtitle:     whopsdk.String("Check it out now"),
    Content:      "We just released a new feature that helps you track your progress better.",
})
if err != nil {
    log.Fatal(err)
}

fmt.Println(result.Success) // true
```

> [!NOTE]
>
> **Örnek kullanım senaryosu:** Bir fitness takip uygulaması geliştiriyorsanız,
> yeni bir antrenman programı yayınlandığında herkese bildirim gönderebilirsiniz.
> Ayrıca 7 günlük seriyi tamamlayan kullanıcılara başarılarını kutlamak için
> hedefli bildirimler de gönderebilirsiniz.

## Belirli kullanıcılara gönderin

Bildirimleri yalnızca belirli kullanıcılara göndermek için `user_ids` parametresini kullanın. Bu kullanıcıların da deneyime erişimi olmalıdır.

```typescript TypeScript theme={null}
const result = await client.notifications.create({
  experience_id: 'exp_xxxxxxxxxxxxxx',
  title: 'Complete your daily workout',
  content: 'You\'re 50% of the way to your goal. Finish strong!',
  user_ids: ['user_abc123', 'user_def456'],
});
```

```python Python theme={null}
result = client.notifications.create(
    experience_id="exp_xxxxxxxxxxxxxx",
    title="Complete your daily workout",
    content="You're 50% of the way to your goal. Finish strong!",
    user_ids=["user_abc123", "user_def456"],
)
```

```ruby Ruby theme={null}
result = client.notifications.create(
  experience_id: "exp_xxxxxxxxxxxxxx",
  title: "Complete your daily workout",
  content: "You're 50% of the way to your goal. Finish strong!",
  user_ids: ["user_abc123", "user_def456"]
)
```

```rust Rust theme={null}
client
    .notifications
    .create(
        &CreateNotificationsRequest {
            experience_id: Some("exp_xxxxxxxxxxxxxx".to_string()),
            title: "Complete your daily workout".to_string(),
            content: "You're 50% of the way to your goal. Finish strong!".to_string(),
            user_ids: Some(vec!["user_abc123".to_string(), "user_def456".to_string()]),
            ..Default::default()
        },
        None,
    )
    .await?;
```

```go Go theme={null}
_, err := client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    ExperienceID: whopsdk.String("exp_xxxxxxxxxxxxxx"),
    Title:        "Complete your daily workout",
    Content:      "You're 50% of the way to your goal. Finish strong!",
    UserIDs:      []string{"user_abc123", "user_def456"},
})
if err != nil {
    log.Fatal(err)
}
```

## Hesap ekip üyelerine gönderin

Bir hesabın tüm ekip üyelerine (pano uygulaması kullanıcılarına) bildirim gönderin:

```typescript TypeScript theme={null}
const result = await client.notifications.create({
  account_id: 'biz_xxxxxxxxxxxxxx',
  title: 'Monthly Report Ready',
  subtitle: 'October 2024',
  content: 'Your monthly analytics report has been generated and is ready to view.',
});
```

```python Python theme={null}
result = client.notifications.create(
    account_id="biz_xxxxxxxxxxxxxx",
    title="Monthly Report Ready",
    subtitle="October 2024",
    content="Your monthly analytics report has been generated and is ready to view.",
)
```

```ruby Ruby theme={null}
result = client.notifications.create(
  account_id: "biz_xxxxxxxxxxxxxx",
  title: "Monthly Report Ready",
  subtitle: "October 2024",
  content: "Your monthly analytics report has been generated and is ready to view."
)
```

```rust Rust theme={null}
let result = client
    .notifications
    .create(
        &CreateNotificationsRequest {
            account_id: Some("biz_xxxxxxxxxxxxxx".to_string()),
            title: "Monthly Report Ready".to_string(),
            subtitle: Some("October 2024".to_string()),
            content: "Your monthly analytics report has been generated and is ready to view."
                .to_string(),
            ..Default::default()
        },
        None,
    )
    .await?;
```

```go Go theme={null}
_, err := client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    AccountID: whopsdk.String("biz_xxxxxxxxxxxxxx"),
    Title:     "Monthly Report Ready",
    Subtitle:  whopsdk.String("October 2024"),
    Content:   "Your monthly analytics report has been generated and is ready to view.",
})
if err != nil {
    log.Fatal(err)
}
```

> [!NOTE]
>
> **Örnek kullanım senaryosu:** Bir vergi beyannamesi panosu geliştiriyorsanız,
> bir beyan son tarihi yaklaştığında tüm ekip üyelerine bildirim gönderebilirsiniz.
> Ayrıca beyan sürecindeki adımları hâlâ tamamlaması gereken belirli kullanıcılara
> hedefli hatırlatmalar da gönderebilirsiniz.

## Belirli ekip üyelerine gönderin

Bildirimleri yalnızca belirli ekip üyelerine göndermek için `user_ids` parametresini kullanın. Bu kullanıcıların da hesabın ekip üyesi olması gerekir.

```typescript TypeScript theme={null}
const result = await client.notifications.create({
  account_id: 'biz_xxxxxxxxxxxxxx',
  title: 'Action Required',
  content: 'Please review and approve the pending invoices.',
  user_ids: ['user_manager1', 'user_manager2'],
});
```

```python Python theme={null}
result = client.notifications.create(
    account_id="biz_xxxxxxxxxxxxxx",
    title="Action Required",
    content="Please review and approve the pending invoices.",
    user_ids=["user_manager1", "user_manager2"],
)
```

```ruby Ruby theme={null}
result = client.notifications.create(
  account_id: "biz_xxxxxxxxxxxxxx",
  title: "Action Required",
  content: "Please review and approve the pending invoices.",
  user_ids: ["user_manager1", "user_manager2"]
)
```

```rust Rust theme={null}
client
    .notifications
    .create(
        &CreateNotificationsRequest {
            account_id: Some("biz_xxxxxxxxxxxxxx".to_string()),
            title: "Action Required".to_string(),
            content: "Please review and approve the pending invoices.".to_string(),
            user_ids: Some(vec!["user_manager1".to_string(), "user_manager2".to_string()]),
            ..Default::default()
        },
        None,
    )
    .await?;
```

```go Go theme={null}
_, err := client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    AccountID: whopsdk.String("biz_xxxxxxxxxxxxxx"),
    Title:     "Action Required",
    Content:   "Please review and approve the pending invoices.",
    UserIDs:   []string{"user_manager1", "user_manager2"},
})
if err != nil {
    log.Fatal(err)
}
```

## rest\_path ile derin bağlantı

`rest_path` parametresini kullanarak, kullanıcılar bir bildirime dokunduğunda onları uygulamanızdaki belirli sayfalara yönlendirin.

## Uygulama yolunuzu ayarlama

Önce, dinamik rota parametresini işlemek için panoda uygulama yolunuzu yapılandırın:

1. [Geliştirici panosunda](https://whop.com/dashboard/developer) uygulama ayarlarınıza gidin
2. Barındırma bölümünde "App path" değerinizi `[restPath]` içerecek şekilde güncelleyin

**Deneyim uygulamaları için:**

```
/experiences/[experienceId]/[restPath]
```

**Pano uygulamaları için:**

```
/companies/[companyId]/[restPath]
```

## Derin bağlantılarla bildirim gönderme

Bildiriminize `rest_path` parametresini ekleyin. Whop bunu uygulamanızın temel URL'sine ekler.

```typescript TypeScript theme={null}
// Experience app: Direct to a specific workout
await client.notifications.create({
  experience_id: 'exp_xxxxxxxxxxxxxx',
  title: 'Today\'s Recommended Workout',
  content: 'Based on your progress, we recommend this HIIT session.',
  rest_path: '/workouts/hiit-advanced-1',
});

// Dashboard app: Direct to a specific report
await client.notifications.create({
  account_id: 'biz_xxxxxxxxxxxxxx',
  title: 'Unusual Activity Detected',
  content: 'Review the flagged transactions in your dashboard.',
  rest_path: '/reports/flagged-transactions',
});

```

```python Python theme={null}
# Experience app: Direct to a specific workout
client.notifications.create(
    experience_id="exp_xxxxxxxxxxxxxx",
    title="Today's Recommended Workout",
    content="Based on your progress, we recommend this HIIT session.",
    rest_path="/workouts/hiit-advanced-1",
)

# Dashboard app: Direct to a specific report
client.notifications.create(
    account_id="biz_xxxxxxxxxxxxxx",
    title="Unusual Activity Detected",
    content="Review the flagged transactions in your dashboard.",
    rest_path="/reports/flagged-transactions",
)
```

```ruby Ruby theme={null}
# Experience app: Direct to a specific workout
client.notifications.create(
  experience_id: "exp_xxxxxxxxxxxxxx",
  title: "Today's Recommended Workout",
  content: "Based on your progress, we recommend this HIIT session.",
  rest_path: "/workouts/hiit-advanced-1"
)

# Dashboard app: Direct to a specific report
client.notifications.create(
  account_id: "biz_xxxxxxxxxxxxxx",
  title: "Unusual Activity Detected",
  content: "Review the flagged transactions in your dashboard.",
  rest_path: "/reports/flagged-transactions"
)
```

```rust Rust theme={null}
// Experience app: Direct to a specific workout
client
    .notifications
    .create(
        &CreateNotificationsRequest {
            experience_id: Some("exp_xxxxxxxxxxxxxx".to_string()),
            title: "Today's Recommended Workout".to_string(),
            content: "Based on your progress, we recommend this HIIT session.".to_string(),
            rest_path: Some("/workouts/hiit-advanced-1".to_string()),
            ..Default::default()
        },
        None,
    )
    .await?;

// Dashboard app: Direct to a specific report
client
    .notifications
    .create(
        &CreateNotificationsRequest {
            account_id: Some("biz_xxxxxxxxxxxxxx".to_string()),
            title: "Unusual Activity Detected".to_string(),
            content: "Review the flagged transactions in your dashboard.".to_string(),
            rest_path: Some("/reports/flagged-transactions".to_string()),
            ..Default::default()
        },
        None,
    )
    .await?;
```

```go Go theme={null}
// Experience app: Direct to a specific workout
_, err := client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    ExperienceID: whopsdk.String("exp_xxxxxxxxxxxxxx"),
    Title:        "Today's Recommended Workout",
    Content:      "Based on your progress, we recommend this HIIT session.",
    RestPath:     whopsdk.String("/workouts/hiit-advanced-1"),
})
if err != nil {
    log.Fatal(err)
}

// Dashboard app: Direct to a specific report
_, err = client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    AccountID: whopsdk.String("biz_xxxxxxxxxxxxxx"),
    Title:     "Unusual Activity Detected",
    Content:   "Review the flagged transactions in your dashboard.",
    RestPath:  whopsdk.String("/reports/flagged-transactions"),
})
if err != nil {
    log.Fatal(err)
}
```

## Uygulamanızda rotayı işleme

Bir kullanıcı bildirime dokunduğunda Whop onu, uygulama yolunuz ve `rest_path` ile oluşturulan tam URL'ye yönlendirir.

**Deneyim uygulaması için örnek:**

Uygulamanızı `https://your-app.com` adresinde barındırıyor ve şunu gönderiyorsanız:

```typescript theme={null}
rest_path: "/posts/post_123";
```

Kullanıcının açacağı adres:

```
https://your-app.com/experiences/exp_xxxxxxxxxxxxxx/posts/post_123
```

**Next.js'te** şu konumda bir dosya oluşturun:

```
app/experiences/[experienceId]/posts/[postId]/page.tsx
```

**Express'te** rotayı işleyin:

```typescript theme={null}
app.get("/experiences/:experienceId/posts/:postId", (req, res) => {
	// Handle the notification deep link
});
```

Sorgu parametreleri de kullanabilirsiniz:

```typescript theme={null}
rest_path: "?action=review&id=123";
```

## Özel bildirim simgeleri

Varsayılan olarak bildirimler deneyim avatarınızı, hesap avatarınızı veya her ikisini gösterir. Kullanmak istediğiniz profil resminin Whop kullanıcı kimliğini sağlayarak simgeyi özelleştirin.

```typescript TypeScript theme={null}
await client.notifications.create({
  experience_id: 'exp_xxxxxxxxxxxxxx',
  title: 'New Comment',
  content: 'Sarah replied to your post: "Great progress!"',
  icon_user_id: 'user_xxxxxxxxxxxxx',
  rest_path: '/posts/my-post-123',
});
```

```python Python theme={null}
client.notifications.create(
    experience_id="exp_xxxxxxxxxxxxxx",
    title="New Comment",
    content='Sarah replied to your post: "Great progress!"',
    icon_user_id="user_xxxxxxxxxxxxx",
    rest_path="/posts/my-post-123",
)
```

```ruby Ruby theme={null}
client.notifications.create(
  experience_id: "exp_xxxxxxxxxxxxxx",
  title: "New Comment",
  content: 'Sarah replied to your post: "Great progress!"',
  icon_user_id: "user_xxxxxxxxxxxxx",
  rest_path: "/posts/my-post-123"
)
```

```rust Rust theme={null}
client
    .notifications
    .create(
        &CreateNotificationsRequest {
            experience_id: Some("exp_xxxxxxxxxxxxxx".to_string()),
            title: "New Comment".to_string(),
            content: "Sarah replied to your post: \"Great progress!\"".to_string(),
            icon_user_id: Some("user_sarah123".to_string()),
            rest_path: Some("/posts/my-post-123".to_string()),
            ..Default::default()
        },
        None,
    )
    .await?;
```

```go Go theme={null}
_, err := client.Notifications.Create(context.TODO(), &whopsdk.CreateNotificationsRequest{
    ExperienceID: whopsdk.String("exp_xxxxxxxxxxxxxx"),
    Title:        "New Comment",
    Content:      `Sarah replied to your post: "Great progress!"`,
    IconUserID:   whopsdk.String("user_sarah123"),
    RestPath:     whopsdk.String("/posts/my-post-123"),
})
if err != nil {
    log.Fatal(err)
}
```

Bu, bir işlemi kimin gerçekleştirdiğini (yorum yaptı, beğendi, takip etti vb.) göstermek istediğiniz sosyal özellikler için kullanışlıdır.

## Sonraki adımlar

> [card] [Sohbet botu oluşturun](https://docs.whop.com/tr/developer/guides/chat.md)
>
> Kullanıcıların nerede olurlarsa olsunlar haberdar olması için bildirimleri uygulama içi mesajlarla birleştirin.

> [card] [Webhook'ları dinleyin](https://docs.whop.com/tr/developer/guides/webhooks.md)
>
> Bildirimleri `payment.succeeded`, `membership.activated` ve diğer sunucu olaylarıyla tetikleyin.

> [card] [Forumlar](https://docs.whop.com/tr/developer/guides/forums.md)
>
> Forum deneyiminize yeni gönderiler veya yorumlar geldiğinde kullanıcıları bilgilendirin.

> [card] [İzin isteyin](https://docs.whop.com/tr/developer/guides/permissions.md)
>
> Bildirimlerin başarıyla gönderilmesi için uygulamanızın izin kurulumunu doğrulayın.


## Related topics

- [Topluluklar ve sohbet](https://docs.whop.com/tr/developer/communities/overview.md)
- [ChatElement (Eski)](https://docs.whop.com/tr/sdk/elements/chat-element.md)
- [SearchElement (Eski)](https://docs.whop.com/tr/sdk/elements/search-element.md)
