A fork of https://github.com/teal-fm/piper
1// Code generated by cmd/lexgen (see Makefile's lexgen); DO NOT EDIT.
2
3package bsky
4
5// schema: app.bsky.notification.getUnreadCount
6
7import (
8 "context"
9
10 "github.com/bluesky-social/indigo/xrpc"
11)
12
13// NotificationGetUnreadCount_Output is the output of a app.bsky.notification.getUnreadCount call.
14type NotificationGetUnreadCount_Output struct {
15 Count int64 `json:"count" cborgen:"count"`
16}
17
18// NotificationGetUnreadCount calls the XRPC method "app.bsky.notification.getUnreadCount".
19func NotificationGetUnreadCount(ctx context.Context, c *xrpc.Client, priority bool, seenAt string) (*NotificationGetUnreadCount_Output, error) {
20 var out NotificationGetUnreadCount_Output
21
22 params := map[string]interface{}{
23 "priority": priority,
24 "seenAt": seenAt,
25 }
26 if err := c.Do(ctx, xrpc.Query, "", "app.bsky.notification.getUnreadCount", params, nil, &out); err != nil {
27 return nil, err
28 }
29
30 return &out, nil
31}