各プッシュサービスへ送信するメッセージのオプションを、プロパティファイル形式(定義名=指定値)で設定できるファイルです。
定義ファイル(impush.properties)のテンプレートファイルの格納先ディレクトリ(fj_push_template_file_dir)で、テンプレートファイルの格納先を指定します。
リクエストボディの変数名"templateFile"に、格納先にあるファイル名を指定します。
UTF-8で指定します。
6.6.1 共通メッセージ送信アプリケーションの開発を参照してください。
HttpClientBuilder httpclient = HttpClientBuilder.create();
String b64_authval = "1234567890abcdefghijklmnop==";
String url = "https://ホスト名:ポート/pushidmng/notifyCommon";
StringBuilder sb = new StringBuilder();
sb.append("{");
sb.append(" \"message\": \"テストメッセージです。\",");
sb.append(" \"templateFile\": \"templateEmployer001\",");
sb.append(" \"regIDs\": [");
sb.append(" \"1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef\"");
sb.append(" ]"); sb.append("}");
HttpPost httpPost = new HttpPost(url);
httpPost.setHeader("IMAPS-Authorization", "Basic " + b64_authval);
httpPost.setHeader("Content-Type", "application/json; charset=UTF-8");
httpPost.setEntity(new StringEntity(sb.toString(),"UTF-8"));
im_response = httpclient.build().execute(httpPost);