1
這是我的樣品紅寶石POST請求到FCM雲信息,我需要調度推送通知的交貨時間我怎樣才能在火力計劃從Rails的POST請求
require 'httparty'
require 'json'
result = HTTParty.post('http://fcm.googleapis.com/fcm/send',
:body => { "to" => "< Sample FCM token>",
"priority" => "high",
"notification" => {
"title" => 'Hello World',
"body" => "Test Message !"
}}.to_json,
:headers => { 'Content-Type' => 'application/json', 'Authorization' => 'key=<FCM Key>' })