HTTPS 規格

HTTPS 是將 ELS 資料從手機傳輸至端點的可用格式之一。HTTPS 通訊協定非常標準,本文不會詳細說明通訊協定本身。端點應接收 POST 訊息,其中包含下列欄位的緊急位置資訊。

請注意,如果資料可用,請盡可能填入多個欄位,尤其是下列欄位:timelocation_latitudelocation_longitudelocation_accuracy。如果沒有這類資料,ELS 訊息就幾乎沒有用處。不過,最終所有欄位都會視為選填。一般來說,端點應能處理缺少/格式錯誤的欄位,且不會發生錯誤。

端點應在成功接收訊息時傳回 2XX 成功代碼。 如果處理訊息時發生問題,或訊息必須因其他原因而捨棄,端點仍應傳回 2XX 成功代碼。您可以使用不同的 2XX 成功代碼,追蹤端點對訊息的具體處理方式。

資料格式依據為最新的 ETSI AML 規格。以下章節最為相關:

內容

欄位規格

金鑰 單位 範例
v 版本 - 1
emergency_number 撥打的緊急電話號碼 - 911
source 啟用來源 (通話、簡訊) - 致電
thunderbird_version thunderbird 模組的版本號碼 - 2800
time 通話開始時間戳記 毫秒 (UNIX 時間) 1438101600123
location_latitude 緯度 度數 37.4217845
location_longitude 經度 度數 -122.0847413
location_time 位置修正的時間戳記 毫秒 (UNIX 時間) 1438102600123
location_altitude 海拔高度 (WGS84) 公尺 4
location_altitude_msl 海拔 (平均海平面) 公尺 4
location_floor 樓層編號 (如電梯按鈕上的樓層編號,可能為非數字) - 2
location_source 位置資訊來源 (GPS、Wi-Fi、行動網路、不明) - gps
location_accuracy 準確率 公尺 20
location_vertical_accuracy 垂直準確度 公尺 2.5
location_vertical_accuracy_msl 垂直準確度 (平均海平面) 公尺 2.5
location_confidence 對定位精確度的信心 百分比 (0-1) 0.6827
location_bearing 方位 度數 156.7
location_speed 速度 公尺/秒 1.2
device_number 裝置電話號碼 (盡量以 E.164 電話號碼格式設定) - +1438101600
device_model 裝置型號 (通常為裝置製造商,後面接著裝置型號名稱) - Motorola Nexus 6
device_imsi IMSI - 310260579377451
device_imei IMEI - 355458061005220
device_iccid ICCID - 89148000001466362977
cell_home_mcc 住家 MCC - 310
cell_home_mnc Home MNC - 260
cell_network_mcc 網路 MCC - 310
cell_network_mnc 網路 MNC - 260
hmac 訊息驗證碼 -

空值位置

裝置號碼

在某些情況下,可能不一定會指定 device_number 欄位。ELS 會嘗試從各種來源取得電話號碼,但可能無法取得。建議您:除了 HTTPS 訊息外,也傳送簡訊,並在收到兩者時,根據 IMEI 和時間 (通話開始的時間戳記) 比對,推斷裝置號碼,或與 MNO 合作,使用 IMEI/IMSI 擷取電話號碼。

我們會盡可能將號碼格式設為 E.164 格式,加上加號和國家/地區撥號代碼前置字元,隨後為訂閱者號碼,不含空格或括號 +1438101600。如果我們無法推斷國家/地區代碼,因此無法格式化號碼,我們會透過來源提供的原始號碼傳送訊息。

海拔高度 (Z 軸)

ELS 會在傳送至 ELS 端點的所有 ELS HTTPS 位置資訊訊息中,回報 Z 軸位置資訊。海拔高度會以高於平均海平面 (MSL) 的公尺數 location_altitude_msl,以及高於 WGS84 參考橢球體的公尺數 location_altitude 回報 (WGS 是 GPS 使用的參考世界大地測量系統)。

ELS 也會回報以公尺為單位的垂直準確度,用於兩種高度測量:location_vertical_accuracylocation_vertical_accuracy_msl。垂直準確度的定義與位置準確度相同,信賴度百分位數則由合作夥伴設定。預設信心水準為 68%。詳情請參閱 getVerticalAccuracyMeters()getMslAltitudeAccuracyMeters() 的 Android 說明文件。

有了使用者高於平均海平面 (MSL) 的海拔高度,現在可以使用伺服器端 API 取得地形海拔高度 MSL,進而推斷使用者高於地面的高度。

其他緊急救援資訊

ELS 支援的欄位不只位置資訊,還包括其他緊急資訊 (AEI)。這些欄位預設不會傳送,且分為四個類別,合作夥伴必須明確選擇加入:

  • 一般 (裝置語言、緊急情況類型、緊急電話觸發資訊,包括車禍和跌倒偵測時間戳記)
  • 醫療資訊
  • 緊急聯絡人
  • 即時監控畫面

如要啟用這些欄位,請提出設定變更要求,如有任何問題,請與 ELS 團隊聯絡

限制與注意事項

這項資料可能不是最新或最準確的資訊。醫療資訊和緊急聯絡人資訊來自使用者裝置上的緊急情況應用程式。這款應用程式是由手機製造商提供,因此他們會決定支援哪些資訊,以及提供格式化或任意形式的資訊。此外,這類資料是由使用者直接輸入,一般而言,這類資料必須經過清理。

如果是任意形式的「字串」欄位,ELS 會直接傳遞資料,不會進行修改,因此無法保證格式和有效性。對於結構化欄位,ELS 會以特定格式傳送值,但不保證這項資料的有效性。範例:

  • 時間戳記:保證為數字,且應包含自 UNIX 紀元時間戳記以來的毫秒數,以符合規格的實作項目為準。對於不符合規格的實作項目,必須能夠妥善處理無效值 (例如 -1)。
  • 日期:請務必採用 ISO 8601 YYYY-MM-DD 格式。如果實作項目不符合規格,必須能夠妥善處理無效日期 (例如 2020-22-22)。

一般

金鑰 單位 範例
adr_carcrash_time 車禍時間戳記 毫秒 (UNIX 時間) 1438101600123
device_languages BCP 47 語言標記 (以半形逗號分隔),依優先順序由高至低排列 - en-US,fr-FR
emergency_type 使用者在輔助緊急撥號期間選取的緊急情況類型 MEDICAL/FIRE/POLICE 其中之一 射擊
fall_detection_time 偵測到跌倒的時間戳記 毫秒 (UNIX 時間) 1438101600124
loss_of_pulse_time 偵測到無脈搏情形的時間戳記 毫秒 (UNIX 時間) 1438101600125

緊急聯絡人

金鑰 單位 範例
econtact_[0-12]_name 第 [0-12]位緊急聯絡人的姓名 - 王大強
econtact_[0-12]_phone_number 第 [0-12]位緊急聯絡人的電話號碼 不保證是有效的電話號碼 +123 456789
econtact_[0-12]_relationship 使用者與第 [0-12]位緊急聯絡人的關係 - 姊妹

醫療資訊

金鑰 單位 範例
med_info_last_updated_time 上次更新醫療資訊的時間戳記 毫秒 (Unix 時間,不保證有效) 1438101600124
med_info_name 使用者名稱 - Alex Smith
med_info_date_of_birth_gregorian 出生日期 ISO 8601 YYYY-MM-DD (不保證為有效日期,例如 2020-22-22) 1990-01-03
med_info_date_of_birth_other 出生日期 (自由格式) - 2000 年 1 月 1 日
med_info_height 高度 - 180 公分
med_info_weight 重量 - 10 英石
med_info_sex 生理性別 (預先定義) UNKNOWN / MALE / FEMALE / INTERSEX / OTHER 其中之一 INTERSEX
med_info_sex_extra 生理性別 (自由形式,可能補充 med_info_sex) - 從「女性」轉換為「男性」
med_info_gender 性別 - 非二元
med_info_home_address 住家地址 - 123 Halifax Avenue,
Alexandria 12345
med_info_blood_type_abo 血型 (預先定義) UNKNOWN / O_POSITIVE / O_NEGATIVE / O_UNKNOWN / A_POSITIVE / A_NEGATIVE / A_UNKNOWN / B_POSITIVE / B_NEGATIVE / B_UNKNOWN / AB_POSITIVE / AB_NEGATIVE / AB_UNKNOWN / H_H B_NEGATIVE
med_info_blood_type_other 血型 (任意格式) - Le(a-b-)
med_info_allergies 過敏 - 乳膠
med_info_medications 藥物 - 阿斯匹靈
med_info_conditions_history 病史 - 高血壓
med_info_devices_mobility_requirements 醫療器材或行動輔具需求 - Pacemaker
med_info_pregnancy_status 懷孕狀態 UNKNOWN / PREGNANT / NOT_PREGNANT 其中之一 懷孕
med_info_pregnancy_due_date 預產期 ISO 8601 YYYY-MM-DD (不保證為有效日期,例如 2020-22-22) 2022-10-10
med_info_pregnancy_info 懷孕資訊 可能補充 med_info_pregnancy_statusmed_info_pregnancy_due_date 預定剖腹產
med_info_organ_donor 器官捐贈者 (預先定義) UNKNOWN / NO / YES 其中之一
med_info_organ_donor_extra 器官捐贈者 (不限格式) 可能與「med_info_organ_donor」互補 僅限心臟和肺部
med_info_advanced_directives 進階指令 - DNS
med_info_physician_info 主要醫師資訊 - John Doe, 34 Rainbow street, +123 456789
med_info_other 其他醫療資訊 - 私人保險,保險證號 123-ABC-987

即時影像

ELS 支援即時影像,可從使用者裝置啟動影像串流。 啟用後,如果使用者手機支援這項功能 (Android 8 以上版本),您就會在 HTTPS ELS 訊息中收到 live_video_token 欄位。詳情請參閱即時影片

金鑰 單位 範例
live_video_token 6 個隨機大寫英數字元 - ABC123

範例

沒有位置資訊,但有裝置號碼 (例如 164 格式):

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643650654147&location_latitude=%2B00.00000&location_longitude=%2B000.00000&location_time=1643650654147&location_altitude=0&location_accuracy=0&location_confidence=0&location_source=unknown&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15

沒有位置資訊,也沒有裝置號碼:

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643650654147&location_latitude=%2B00.00000&location_longitude=%2B000.00000&location_time=1643650654147&location_altitude=0&location_accuracy=0&location_confidence=0&location_source=unknown&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15

計算位置資訊,並提供裝置號碼 (例如 164 格式):

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15

已計算位置資訊,但裝置號碼 (非 E. 164 格式):

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=01234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15

已計算位置,但沒有裝置號碼:

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15

系統會計算位置資訊,並提供一般額外緊急資訊:

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15&adr_carcrash_time=1643648829100&fall_detection_time=1643648829200&loss_of_pulse_time=1643648829201&emergency_type=MEDICAL

系統會根據即時影像計算位置:

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15&live_video_token=ABC123

計算位置,並提供醫療資訊和緊急聯絡人 (假設緊急應用程式運作正常,可提供結構化資料):

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15&med_info_name=Alex+Smith&med_info_date_of_birth_gregorian=1990-01-03&med_info_height=6+ft&med_info_weight=100+kg&med_info_home_address=Test+Street+5%2C+80636+Munich&med_info_blood_type_abo=H_H&med_info_allergies=Peanuts&med_info_medications=Zestril&med_info_pregnancy_status=PREGNANT&med_info_pregnancy_due_date=2023-10-31&med_info_organ_donor=YES&med_info_other=Insurance+id%3A+12345

計算位置資訊,並提供醫療資訊和緊急聯絡人 (假設緊急應用程式運作正常,可提供非結構化資料並設定所有可能欄位):

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15&med_info_last_updated_time=1438101600000&med_info_name=Alex+Smith&med_info_date_of_birth_other=On+the+first+day+of+year+2000&med_info_height=180+cm&med_info_weight=10+stones&med_info_sex=INTERSEX&med_info_sex_extra=Transitioning+from+FEMALE+to+MALE&med_info_gender=non-binary&med_info_home_address=123+Halifax+Avenue%2C+Alexandria+12345&med_info_blood_type_other=Le%28a-b-%29&med_info_allergies=Latex&med_info_medications=Aspirin&med_info_conditions_history=ADHD&med_info_devices_mobility_requirements=Pacemaker&med_info_pregnancy_status=PREGNANT&med_info_pregnancy_due_date=2022-10-10&med_info_pregnancy_info=Planned+c-section&med_info_organ_donor=YES&med_info_organ_donor_extra=Only+heart+and+lungs&med_info_advanced_directives=DNS&med_info_physician_info=John+Doe%2C+34+Rainbow+street%2C+%2B123+456789&med_info_other=Privately+insured%2C+insurance+ID+123-ABC-987&econtact_0_name=John+Doe&econtact_0_phone_number=000+000&econtact_0_relationship=Father&econtact_1_name=Jane+Doe&econtact_1_phone_number=111+111&econtact_1_relationship=Mother&econtact_2_name=Alice+Smith&econtact_2_phone_number=222+222&econtact_2_relationship=Sister&econtact_3_name=Bob+Smith&econtact_3_phone_number=333+333&econtact_3_relationship=Brother&econtact_4_name=Charlie+Smith&econtact_4_phone_number=444+444&econtact_4_relationship=Brother&econtact_5_name=Dan+Smith&econtact_5_phone_number=555+555&econtact_5_relationship=Cousin&econtact_6_name=Eve+Smith&econtact_6_phone_number=666+666&econtact_6_relationship=Grandmother&econtact_7_name=Mallory+Smith&econtact_7_phone_number=777+777&econtact_7_relationship=Aunt&econtact_8_name=Trent+Smith&econtact_8_phone_number=888+888&econtact_8_relationship=Uncle&econtact_9_name=Xenia+Smith&econtact_9_phone_number=999+999&econtact_9_relationship=Sister&econtact_10_name=Yara+Smith&econtact_10_phone_number=10+10+10&econtact_10_relationship=Cousin&econtact_11_name=Zane+Smith&econtact_11_phone_number=11+11+11&econtact_11_relationship=Cousin&econtact_12_name=%28truncated%29

計算位置,並提供醫療資訊 (假設緊急應用程式提供無效、無界限和非結構化資料,屬於最糟的情況):

v=1&thunderbird_version=220512054&emergency_number=911&source=CALL&time=1643648829301&location_latitude=51.5332125&location_longitude=-0.1260139&location_time=1643648838875&location_altitude=77.5999985&location_altitude_msl=67.5999985&location_vertical_accuracy=0.9868233&location_vertical_accuracy_msl=0.8868233&location_accuracy=14.9460001&location_bearing=306.3276367&location_speed=0.0783991&location_confidence=0.6826895&location_source=wifi&device_number=%2B1234567890&device_model=Google+Pixel+6+Pro&device_imei=123456789012345&device_imsi=234159876543210&device_iccid=12345678901234567890&cell_home_mcc=234&cell_home_mnc=15&cell_network_mcc=234&cell_network_mnc=15&med_info_last_updated_time=-1000&med_info_date_of_birth_gregorian=0000-00-00&med_info_sex_extra=Transitioning+from+FEMALE+to+MALE&med_info_blood_type_other=Le%28a-b-%29&med_info_pregnancy_due_date=3000-22-22&med_info_organ_donor_extra=Only+heart+and+lungs&med_info_other=Lorem+ipsum+dolor+sit+amet%2C+consetetur+sadipscing+elitr%2C+sed+diam+nonumy+eirmod+tempor+invidunt+ut+labore+et+dolore+magna+aliquyam+erat%2C+sed+diam+voluptua.+At+vero+eos+et+accusam+et+justo+duo+dolores+et+ea+rebum.+Stet+clita+kasd+gubergren%2C+no+sea+takimata+sanctus+est+Lorem+ipsum+dolor+sit+amet.+Lorem+ipsum+dolor+sit+amet%2C+consetetur+sadipscing+elitr%2C+sed+diam+nonumy+eirmod+tempor+invidunt+ut+labore+et+dolore+magna+aliquyam+erat%2C+sed+diam+voluptua.+At+vero+eos+et+accusam+et+justo+duo+dolores+et+ea+rebum.+Stet+clita+kasd+gubergren%2C+no+sea+takimata+sanctus+est+Lorem+ipsum+dolor+sit+amet.+Lorem+ipsum+dolor+sit+amet%2C+consetetur+sadipscing+elitr%2C+sed+diam+nonumy+eirmod+tempor+invidunt+ut+labore+et+dolore+magna+aliquyam+erat%2C+sed+diam+voluptua.+At+vero+eos+et+accusam+et+justo+duo+dolores+et+ea+rebum.+Stet+clita+kasd+gubergren%2C+no+sea+takimata+sanctus+est+Lorem+ipsum+dolor+sit+amet.+%0A%0ADuis+autem+vel+eum+iriure+dolor+in+hendrerit+in+vulputate+velit+esse+molestie+consequat%2C+vel+illum+dolore+eu+feugiat+nulla+facilisis+at+vero+eros+et+accumsan+et+iusto+odio+dignissim+qui+blandit+praesent+luptatum+zzril+delenit+augue+duis+dolore+te+feugait+nulla+facilisi.+Lorem+ipsum+dolor+sit+amet%2C+consectetuer+adipiscing+elit%2C+sed+diam+nonummy+nibh+euismod+tincidunt+ut+laoreet+dolore+magna+aliquam+erat+volutpat.+%0A%0AUt+wisi+enim+ad+minim+veniam%2C+quis+nostrud+exerci+tation+ullamcorper+suscipit+lobortis+nisl+ut+aliquip+ex+ea+commodo+consequat.+Duis+autem+vel+eum+iriure+dolor+in+hendrerit+in+vulputate+velit+esse+molestie+consequat%2C+vel+illum+dolore+eu+feugiat+nulla+facilisis+at+vero+eros+et+accumsan+et+iusto+odio+dignissim+qui+blandit+praesent+luptatum+zzril+delenit+augue+duis+dolore+te+feugait+nulla+facilisi.+%0A%0ANam+liber+tempor+cum+soluta+nobis+eleifend+option+congue+nihil+imperdiet+doming+id+quod+mazim+placerat+facer+possim+assum.+Lorem+ipsum+dolor+sit+amet%2C+consectetuer+adipiscing+elit%2C+sed+diam+nonummy+nibh+euismod+tincidunt+ut+laoreet+dolore+magna+aliquam+erat+volutpat.+Ut+wisi+enim+ad+minim+v%28truncated%29