Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/NaySoftware/go-fcm
/ functions
Functions
57 in github.com/NaySoftware/go-fcm
⨍
Functions
57
◇
Types & classes
10
↓ 6 callers
Method
apiKeyHeader
apiKeyHeader generates the value of the Authorization key
fcm.go:152
↓ 5 callers
Function
NewFcmClient
NewFcmClient init and create fcm client
fcm.go:93
↓ 5 callers
Method
Send
Send to fcm
fcm.go:201
↓ 5 callers
Function
chgUrl
(ts *httptest.Server)
fcm_test.go:162
↓ 4 callers
Function
extractTopicName
extractTopicName extract topic name for valid topic name input
instanceid.go:354
↓ 4 callers
Function
parseGetInfo
parseGetInfo parses response to InstanceIdInfoResponse
instanceid.go:142
↓ 3 callers
Method
ToByte
ToByte converts ApnsBatchRequest to a byte
instanceid.go:423
↓ 2 callers
Method
NewFcmMsgTo
NewFcmMsgTo sets the targeted token/topic and the data payload
fcm.go:109
↓ 2 callers
Method
NewFcmTopicMsg
NewFcmTopicMsg sets the targeted token/topic and the data payload
fcm.go:101
↓ 2 callers
Method
SetMsgData
SetMsgData sets data payload
fcm.go:117
↓ 2 callers
Function
generateBatchRequest
generateBatchRequest based on tokens and topic
instanceid.go:343
↓ 2 callers
Function
generateBatchResponse
generateBatchResponse converts a byte response to BatchResponse
instanceid.go:367
↓ 2 callers
Function
generateGetInfoUrl
generateGetInfoUrl generate based on with details and the instance token
instanceid.go:176
↓ 2 callers
Function
generateSubToTopicUrl
generateSubToTopicUrl generates a url based on the instnace id and topic name
instanceid.go:238
↓ 2 callers
Method
newDevicesList
newDevicesList init the devices list
fcm.go:135
↓ 1 callers
Method
AppendDevices
AppendDevices adds more devices/tokens to the Fcm request
fcm.go:144
↓ 1 callers
Method
NewFcmRegIdsMsg
NewFcmRegIdsMsg gets a list of devices with data payload
fcm.go:126
↓ 1 callers
Function
parseApnsBatchResponse
parseApnsBatchResponse converts apns byte response to ApnsBatchResponse
instanceid.go:433
↓ 1 callers
Method
parseStatusBody
parseStatusBody parse FCM response body
fcm.go:214
↓ 1 callers
Function
parseSubscribeResponse
parseSubscribeResponse converts a byte response to a SubscribeResponse
instanceid.go:213
↓ 1 callers
Method
sendOnce
sendOnce send a single request to fcm
fcm.go:157
↓ 1 callers
Method
toJsonByte
toJsonByte converts FcmMsg to a json byte
fcm.go:207
Method
ApnsBatchImportRequest
ApnsBatchImportRequest apns import requst
instanceid.go:379
Method
BatchSubscribeToTopic
BatchSubscribeToTopic subscribes (many) devices/tokens to a given topic
instanceid.go:248
Method
BatchUnsubscribeFromTopic
BatchUnsubscribeFromTopic unsubscribes (many) devices/tokens from a given topic
instanceid.go:289
Method
GetInfo
GetInfo gets the instance id info
instanceid.go:104
Method
GetRetryAfterTime
GetRetryAfterTime converts the retrey after response header to a time.Duration
fcm.go:366
Method
IsTimeout
IsTimeout check whether the response timeout based on http response status code and if any error is retryable
fcm.go:348
Method
PrintResults
PrintResults prints InstanceIdInfoResponse, for faster debugging
instanceid.go:155
Method
PrintResults
PrintResults prints SubscribeResponse, for faster debugging
instanceid.go:227
Method
PrintResults
PrintResults prints BatchResponse, for faster debugging
instanceid.go:331
Method
PrintResults
PrintResults prints ApnsBatchResponse, for faster debugging
instanceid.go:445
Method
PrintResults
PrintResults prints the FcmResponseStatus results for fast using and debugging
fcm.go:331
Method
SetCollapseKey
SetCollapseKey This parameter identifies a group of messages (e.g., with collapse_key: "Updates Available") that can be collapsed, so that only the la
fcm.go:241
Method
SetCondition
SetCondition to set a logical expression of conditions that determine the message target
fcm.go:372
Method
SetContentAvailable
SetContentAvailable On iOS, use this field to represent content-available in the APNS payload. When a notification or message is sent and this is set
fcm.go:261
Method
SetDelayWhileIdle
SetDelayWhileIdle When this parameter is set to true, it indicates that the message should not be sent until the device becomes active. The default va
fcm.go:271
Method
SetDryRun
SetDryRun This parameter, when set to true, allows developers to test a request without actually sending a message. The default value is false
fcm.go:310
Method
SetMutableContent
SetMutableContent Currently for iOS 10+ devices only. On iOS, use this field to represent mutable-content in the APNs payload. When a notification is
fcm.go:323
Method
SetNotificationPayload
SetNotificationPayload sets the notification payload based on the specs https://firebase.google.com/docs/cloud-messaging/http-server-ref
fcm.go:250
Method
SetPriority
SetPriority Sets the priority of the message. Priority_HIGH or Priority_NORMAL
fcm.go:225
Method
SetRestrictedPackageName
SetRestrictedPackageName This parameter specifies the package name of the application where the registration tokens must match in order to receive the
fcm.go:300
Method
SetTimeToLive
SetTimeToLive This parameter specifies how long (in seconds) the message should be kept in FCM storage if the device is offline. The maximum time to l
fcm.go:283
Method
SubscribeToTopic
SubscribeToTopic subscribes a single device/token to a topic
instanceid.go:181
Function
TestExtractTopicName
(t *testing.T)
instanceid_test.go:108
Function
TestGenInfoResult1
(t *testing.T)
instanceid_test.go:16
Function
TestGenInfoResult2
(t *testing.T)
instanceid_test.go:30
Function
TestGenInfoResult3
(t *testing.T)
instanceid_test.go:60
Function
TestGenTopicUrl
(t *testing.T)
instanceid_test.go:7
Function
TestParseApnsBatchToByte
(t *testing.T)
instanceid_test.go:73
Function
TestRegIdHandle_1
(t *testing.T)
fcm_test.go:87
Function
TestRegIdHandle_2
(t *testing.T)
fcm_test.go:121
Function
TestTopicHandle_1
(t *testing.T)
fcm_test.go:10
Function
TestTopicHandle_2
(t *testing.T)
fcm_test.go:34
Function
TestTopicHandle_3
(t *testing.T)
fcm_test.go:58
Function
regIdHandle
(w http.ResponseWriter, r *http.Request)
fcm_test.go:172
Function
topicHandle
(w http.ResponseWriter, r *http.Request)
fcm_test.go:166