Versions in this module Expand all Collapse all v4 v4.1.2 Nov 6, 2020 Changes in this version + func IsInternal(err error) bool + func IsInvalidAPNSCredentials(err error) bool + func IsInvalidArgument(err error) bool + func IsMessageRateExceeded(err error) bool + func IsMismatchedCredential(err error) bool + func IsQuotaExceeded(err error) bool + func IsRegistrationTokenNotRegistered(err error) bool + func IsSenderIDMismatch(err error) bool + func IsServerUnavailable(err error) bool + func IsThirdPartyAuthError(err error) bool + func IsTooManyTopics(err error) bool + func IsUnavailable(err error) bool + func IsUnknown(err error) bool + func IsUnregistered(err error) bool + type APNSConfig struct + FCMOptions *APNSFCMOptions + Headers map[string]string + Payload *APNSPayload + type APNSFCMOptions struct + AnalyticsLabel string + ImageURL string + type APNSPayload struct + Aps *Aps + CustomData map[string]interface{} + func (p *APNSPayload) MarshalJSON() ([]byte, error) + func (p *APNSPayload) UnmarshalJSON(b []byte) error + type AndroidConfig struct + CollapseKey string + Data map[string]string + FCMOptions *AndroidFCMOptions + Notification *AndroidNotification + Priority string + RestrictedPackageName string + TTL *time.Duration + func (a *AndroidConfig) MarshalJSON() ([]byte, error) + func (a *AndroidConfig) UnmarshalJSON(b []byte) error + type AndroidFCMOptions struct + AnalyticsLabel string + type AndroidNotification struct + Body string + BodyLocArgs []string + BodyLocKey string + ChannelID string + ClickAction string + Color string + DefaultLightSettings bool + DefaultSound bool + DefaultVibrateTimings bool + EventTimestamp *time.Time + Icon string + ImageURL string + LightSettings *LightSettings + LocalOnly bool + NotificationCount *int + Priority AndroidNotificationPriority + Sound string + Sticky bool + Tag string + Ticker string + Title string + TitleLocArgs []string + TitleLocKey string + VibrateTimingMillis []int64 + Visibility AndroidNotificationVisibility + func (a *AndroidNotification) MarshalJSON() ([]byte, error) + func (a *AndroidNotification) UnmarshalJSON(b []byte) error + type AndroidNotificationPriority int + const PriorityDefault + const PriorityHigh + const PriorityLow + const PriorityMax + const PriorityMin + type AndroidNotificationVisibility int + const VisibilityPrivate + const VisibilityPublic + const VisibilitySecret + type Aps struct + Alert *ApsAlert + AlertString string + Badge *int + Category string + ContentAvailable bool + CriticalSound *CriticalSound + CustomData map[string]interface{} + MutableContent bool + Sound string + ThreadID string + func (a *Aps) MarshalJSON() ([]byte, error) + func (a *Aps) UnmarshalJSON(b []byte) error + type ApsAlert struct + ActionLocKey string + Body string + LaunchImage string + LocArgs []string + LocKey string + SubTitle string + SubTitleLocArgs []string + SubTitleLocKey string + Title string + TitleLocArgs []string + TitleLocKey string + type BatchResponse struct + FailureCount int + Responses []*SendResponse + SuccessCount int + type Client struct + func NewClient(ctx context.Context, c *internal.MessagingConfig) (*Client, error) + func (c Client) Send(ctx context.Context, message *Message) (string, error) + func (c Client) SendAll(ctx context.Context, messages []*Message) (*BatchResponse, error) + func (c Client) SendAllDryRun(ctx context.Context, messages []*Message) (*BatchResponse, error) + func (c Client) SendDryRun(ctx context.Context, message *Message) (string, error) + func (c Client) SendMulticast(ctx context.Context, message *MulticastMessage) (*BatchResponse, error) + func (c Client) SendMulticastDryRun(ctx context.Context, message *MulticastMessage) (*BatchResponse, error) + func (c Client) SubscribeToTopic(ctx context.Context, tokens []string, topic string) (*TopicManagementResponse, error) + func (c Client) UnsubscribeFromTopic(ctx context.Context, tokens []string, topic string) (*TopicManagementResponse, error) + type CriticalSound struct + Critical bool + Name string + Volume float64 + func (cs *CriticalSound) MarshalJSON() ([]byte, error) + func (cs *CriticalSound) UnmarshalJSON(b []byte) error + type ErrorInfo struct + Index int + Reason string + type FCMOptions struct + AnalyticsLabel string + type LightSettings struct + Color string + LightOffDurationMillis int64 + LightOnDurationMillis int64 + func (l *LightSettings) MarshalJSON() ([]byte, error) + func (l *LightSettings) UnmarshalJSON(b []byte) error + type Message struct + APNS *APNSConfig + Android *AndroidConfig + Condition string + Data map[string]string + FCMOptions *FCMOptions + Notification *Notification + Token string + Topic string + Webpush *WebpushConfig + func (m *Message) MarshalJSON() ([]byte, error) + func (m *Message) UnmarshalJSON(b []byte) error + type MulticastMessage struct + APNS *APNSConfig + Android *AndroidConfig + Data map[string]string + Notification *Notification + Tokens []string + Webpush *WebpushConfig + type Notification struct + Body string + ImageURL string + Title string + type SendResponse struct + Error error + MessageID string + Success bool + type TopicManagementResponse struct + Errors []*ErrorInfo + FailureCount int + SuccessCount int + type WebpushConfig struct + Data map[string]string + FCMOptions *WebpushFCMOptions + Headers map[string]string + Notification *WebpushNotification + type WebpushFCMOptions struct + Link string + type WebpushNotification struct + Actions []*WebpushNotificationAction + Badge string + Body string + CustomData map[string]interface{} + Data interface{} + Direction string + Icon string + Image string + Language string + Renotify bool + RequireInteraction bool + Silent bool + Tag string + TimestampMillis *int64 + Title string + Vibrate []int + func (n *WebpushNotification) MarshalJSON() ([]byte, error) + func (n *WebpushNotification) UnmarshalJSON(b []byte) error + type WebpushNotificationAction struct + Action string + Icon string + Title string Other modules containing this package github.com/sonatard/firebase-admin-go