URL/api/v1/configure_measuring_point
Configure a measuring point.
- Parameters:
- measuring_point_id:
- The ID of the measuring point which you'd like to configure. If omitted it will create a new measuring point.
Expects the body of the request to be a JSON dictionary.
Note that all values passed are expected to be in the user profiles unit of distance.
Also note that it will be removed from a project if coupled to one when using the API.
The following can be set using the API
- Body options:
- name:
- Name for the measuring point
- sensor_name:
- six letter name which is located on the front sticker, can be blank for no Swarm connected
- postal_code (optional):
- Postal code
- house_number (optional):
- House number
- street_name (optional):
- Street name
- city (optional):
- City
- disable_led:
- true or false, setting it to true will turn of the led on the front of the Swarm
when there is an active connection to the server.
- log_flush_interval:
- Interval in seconds, when there are measurements which didn't cause an alarm they will
be send at this interval.
- timezone:
- The timezone in which the Swarm is. One of: Indian/Mahe, Africa/Freetown, America/Goose_Bay, Africa/Khartoum, Asia/Yerevan, America/Kentucky/Louisville, Africa/Ceuta, Africa/Banjul, Etc/GMT-10, Africa/Accra, US/East-Indiana, Europe/Ulyanovsk, Europe/Belgrade, America/Metlakatla, Atlantic/Stanley, EST5EDT, Pacific/Tongatapu, US/Hawaii, Pacific/Niue, Pacific/Efate, Canada/Atlantic, America/Knox_IN, America/Pangnirtung, Canada/Pacific, Asia/Vladivostok, America/Rio_Branco, MST7MDT, America/Vancouver, Europe/Zurich, America/Merida, Canada/Mountain, America/Mendoza, America/North_Dakota/New_Salem, HST, Antarctica/Davis, Asia/Vientiane, Asia/Ho_Chi_Minh, Asia/Novokuznetsk, Asia/Samarkand, Brazil/East, Antarctica/Vostok, Africa/Luanda, ROK, America/Martinique, Canada/Central, Australia/Hobart, Singapore, Pacific/Midway, GMT, America/Recife, Europe/Malta, Africa/Kigali, America/Montreal, America/Port_of_Spain, Etc/GMT-11, Europe/Simferopol, Cuba, Asia/Kuching, UCT, Europe/Busingen, America/Fort_Wayne, America/Belize, America/Shiprock, Asia/Phnom_Penh, America/Atikokan, Canada/Saskatchewan, America/Bahia, US/Alaska, America/Argentina/San_Luis, Hongkong, America/Panama, NZ, America/Hermosillo, Europe/Isle_of_Man, Pacific/Norfolk, Atlantic/Faroe, Europe/Vilnius, Africa/Cairo, Africa/Libreville, Pacific/Auckland, Pacific/Ponape, Asia/Ashkhabad, Etc/GMT+8, Etc/Zulu, MST, America/Toronto, America/Argentina/Jujuy, Atlantic/St_Helena, Egypt, America/Whitehorse, Asia/Harbin, Europe/Skopje, Etc/GMT-4, Africa/Timbuktu, America/Edmonton, Indian/Reunion, Asia/Chongqing, Asia/Ujung_Pandang, Pacific/Marquesas, America/Coral_Harbour, America/Chihuahua, Asia/Beirut, Antarctica/DumontDUrville, America/Moncton, Antarctica/Syowa, America/Fortaleza, America/Godthab, Etc/GMT, Pacific/Noumea, Asia/Urumqi, Asia/Tokyo, Pacific/Kwajalein, America/Santarem, America/Thunder_Bay, Europe/Helsinki, Europe/Luxembourg, America/Cordoba, Indian/Mayotte, America/Manaus, Europe/Budapest, America/Grenada, Asia/Choibalsan, Asia/Colombo, America/Argentina/Salta, Africa/Johannesburg, America/Sao_Paulo, Etc/GMT+6, Etc/GMT-8, Africa/Gaborone, Asia/Riyadh, Europe/Tallinn, Asia/Qostanay, Asia/Hovd, America/Cancun, Australia/Adelaide, America/Swift_Current, Asia/Famagusta, America/Boa_Vista, Brazil/Acre, Atlantic/Reykjavik, Europe/Nicosia, Africa/Lome, Indian/Chagos, Asia/Kolkata, Asia/Aqtobe, Pacific/Honolulu, Africa/Ndjamena, Asia/Bahrain, Europe/Kirov, America/Noronha, Asia/Dushanbe, Asia/Kashgar, Africa/Lagos, Europe/Guernsey, America/Argentina/Ushuaia, Europe/Chisinau, Africa/Asmara, Africa/Monrovia, Europe/Volgograd, America/Mazatlan, Asia/Chita, America/Dominica, America/Port-au-Prince, Australia/Yancowinna, Africa/Douala, Australia/Victoria, Australia/Canberra, Asia/Novosibirsk, Europe/Gibraltar, Australia/South, America/Monterrey, Etc/GMT+5, America/St_Barthelemy, America/St_Vincent, America/Araguaina, Asia/Dacca, Africa/Kinshasa, Africa/Tunis, Australia/Sydney, Africa/Bujumbura, Pacific/Pago_Pago, America/Buenos_Aires, America/Rosario, America/Resolute, Asia/Baghdad, Asia/Katmandu, America/Lower_Princes, Pacific/Pitcairn, America/Argentina/Rio_Gallegos, America/Boise, Africa/Bamako, America/Costa_Rica, America/Nuuk, Asia/Dubai, Zulu, Etc/GMT-7, Pacific/Enderbury, America/Jujuy, Australia/Tasmania, Atlantic/Bermuda, America/Los_Angeles, Asia/Irkutsk, America/Porto_Acre, America/Adak, Atlantic/Azores, Indian/Mauritius, Asia/Kamchatka, Europe/London, Antarctica/Troll, US/Michigan, Africa/El_Aaiun, CST6CDT, Africa/Nairobi, America/Halifax, America/Asuncion, Europe/Vaduz, Asia/Baku, Africa/Asmera, Africa/Harare, Europe/Minsk, US/Mountain, NZ-CHAT, Pacific/Tahiti, Asia/Pyongyang, Asia/Krasnoyarsk, America/Havana, America/Maceio, Jamaica, America/Indiana/Petersburg, GB-Eire, America/Cambridge_Bay, Asia/Sakhalin, Africa/Lubumbashi, Pacific/Gambier, America/Yakutat, Indian/Cocos, America/Miquelon, Europe/Mariehamn, Europe/Samara, Etc/UCT, Europe/Kaliningrad, Europe/Bucharest, Navajo, America/Indiana/Vevay, Asia/Aqtau, W-SU, Pacific/Yap, Atlantic/Madeira, America/Punta_Arenas, Africa/Juba, Europe/Jersey, Europe/Berlin, Etc/GMT-5, Pacific/Fiji, Europe/Astrakhan, Etc/GMT-3, Africa/Brazzaville, Africa/Dakar, Asia/Istanbul, Asia/Macao, Etc/GMT+4, America/Thule, PST8PDT, Asia/Barnaul, Australia/LHI, Asia/Jerusalem, Australia/Brisbane, Iceland, Canada/Eastern, Africa/Niamey, America/Nassau, America/Rankin_Inlet, Europe/Tirane, Pacific/Guam, America/Eirunepe, Asia/Calcutta, Africa/Windhoek, Australia/West, Canada/Newfoundland, America/Argentina/Tucuman, Pacific/Johnston, Pacific/Apia, Pacific/Palau, Pacific/Port_Moresby, America/Scoresbysund, Antarctica/Macquarie, Asia/Yakutsk, Asia/Pontianak, Pacific/Saipan, Etc/GMT-1, Asia/Ulaanbaatar, Etc/GMT-9, Pacific/Fakaofo, Asia/Gaza, Asia/Saigon, ROC, America/Denver, Pacific/Kanton, America/Blanc-Sablon, Europe/Rome, Australia/Eucla, Asia/Ust-Nera, Africa/Bangui, Etc/UTC, Etc/Greenwich, America/Argentina/Buenos_Aires, America/Santiago, Asia/Makassar, America/Anguilla, America/Puerto_Rico, MET, Etc/GMT+11, Europe/Moscow, Pacific/Samoa, Europe/Vatican, Europe/Copenhagen, GB, America/Juneau, Asia/Kathmandu, America/Guyana, Greenwich, America/Atka, Pacific/Kosrae, Etc/GMT-13, Australia/Darwin, Asia/Tomsk, Etc/GMT+0, Africa/Mogadishu, Etc/GMT+9, Atlantic/Cape_Verde, Africa/Abidjan, America/Danmarkshavn, Australia/Broken_Hill, Etc/GMT-2, America/Creston, Europe/Prague, America/Nome, Asia/Anadyr, Australia/North, US/Indiana-Starke, America/Indianapolis, Asia/Kabul, America/North_Dakota/Center, America/Porto_Velho, Atlantic/Jan_Mayen, Africa/Mbabane, Antarctica/Casey, Antarctica/Mawson, Asia/Karachi, Europe/San_Marino, America/Argentina/Mendoza, Portugal, Europe/Ljubljana, America/Belem, America/Chicago, Indian/Antananarivo, Europe/Saratov, America/Bahia_Banderas, America/Guayaquil, Africa/Conakry, Asia/Amman, Africa/Blantyre, America/Ojinaga, America/Bogota, America/Aruba, America/Montserrat, America/Santo_Domingo, Atlantic/Faeroe, Pacific/Chuuk, Asia/Brunei, Etc/GMT+12, America/Tijuana, America/North_Dakota/Beulah, America/Paramaribo, Asia/Thimbu, Australia/NSW, America/Jamaica, America/Nipigon, Arctic/Longyearbyen, Asia/Omsk, Asia/Seoul, America/Guatemala, America/Indiana/Indianapolis, Australia/ACT, Asia/Kuala_Lumpur, Canada/Yukon, US/Samoa, Asia/Muscat, America/Dawson, GMT-0, Asia/Hebron, CET, Europe/Madrid, Africa/Kampala, America/New_York, Etc/GMT-0, Africa/Malabo, Eire, Pacific/Tarawa, Asia/Tashkent, US/Pacific, America/Cuiaba, America/Montevideo, Europe/Andorra, Asia/Bangkok, Europe/Zagreb, PRC, America/Argentina/ComodRivadavia, Asia/Nicosia, America/Indiana/Knox, Asia/Yangon, Asia/Hong_Kong, Asia/Tehran, America/Iqaluit, Australia/Currie, Brazil/West, Asia/Tbilisi, America/Campo_Grande, America/Inuvik, Antarctica/Rothera, US/Aleutian, Australia/Lindeman, Africa/Maputo, Pacific/Bougainville, Asia/Taipei, Asia/Tel_Aviv, Europe/Uzhgorod, Asia/Almaty, Australia/Lord_Howe, Etc/GMT+7, Europe/Sofia, Pacific/Rarotonga, Pacific/Guadalcanal, Etc/GMT+10, Africa/Casablanca, Turkey, Asia/Magadan, Europe/Belfast, Asia/Thimphu, Etc/GMT0, UTC, America/La_Paz, America/St_Lucia, America/Detroit, Africa/Dar_es_Salaam, America/Indiana/Winamac, Africa/Addis_Ababa, Etc/GMT+1, America/Marigot, Asia/Singapore, Australia/Queensland, Universal, Etc/Universal, America/Glace_Bay, Europe/Paris, Japan, Europe/Stockholm, Mexico/General, Europe/Podgorica, America/Argentina/Cordoba, Indian/Kerguelen, Indian/Maldives, US/Central, Asia/Bishkek, America/Mexico_City, America/Caracas, America/Santa_Isabel, Asia/Rangoon, Etc/GMT+2, America/Cayenne, Asia/Ulan_Bator, Africa/Djibouti, Asia/Kuwait, Mexico/BajaSur, Asia/Manila, Africa/Tripoli, America/Argentina/San_Juan, Asia/Oral, Asia/Shanghai, Australia/Perth, America/Dawson_Creek, Iran, Asia/Qatar, Libya, America/Louisville, Pacific/Wake, America/Menominee, Chile/EasterIsland, America/Indiana/Vincennes, Europe/Dublin, America/Rainy_River, Africa/Algiers, America/Indiana/Tell_City, America/Virgin, America/Matamoros, Europe/Warsaw, Antarctica/South_Pole, America/Barbados, Africa/Lusaka, Europe/Bratislava, Africa/Maseru, Europe/Oslo, Poland, Pacific/Galapagos, Brazil/DeNoronha, WET, Pacific/Funafuti, Europe/Vienna, Europe/Amsterdam, America/Guadeloupe, America/El_Salvador, America/Winnipeg, America/St_Kitts, Pacific/Easter, America/St_Thomas, EET, Asia/Qyzylorda, America/Anchorage, Africa/Ouagadougou, America/St_Johns, Pacific/Wallis, Pacific/Pohnpei, America/Curacao, GMT+0, America/Sitka, Europe/Lisbon, Etc/GMT-14, Africa/Bissau, America/Kralendijk, Chile/Continental, Asia/Jayapura, GMT0, Antarctica/Palmer, Pacific/Truk, Asia/Damascus, Europe/Athens, America/Argentina/Catamarca, Asia/Chungking, America/Cayman, Asia/Srednekolymsk, Africa/Nouakchott, Pacific/Kiritimati, Asia/Jakarta, Pacific/Majuro, Asia/Atyrau, America/Lima, Africa/Sao_Tome, America/Antigua, Asia/Macau, Asia/Ashgabat, Etc/GMT-6, Israel, Antarctica/McMurdo, Indian/Comoro, Asia/Dili, US/Eastern, America/Phoenix, Pacific/Nauru, Etc/GMT+3, Atlantic/Canary, Europe/Riga, America/Yellowknife, Europe/Kiev, America/Kentucky/Monticello, Europe/Brussels, America/Tortola, America/Ensenada, America/Indiana/Marengo, Europe/Monaco, Europe/Zaporozhye, Mexico/BajaNorte, Europe/Tiraspol, America/Fort_Nelson, Indian/Christmas, America/Grand_Turk, Africa/Porto-Novo, America/Argentina/La_Rioja, Australia/Melbourne, Kwajalein, America/Managua, Asia/Yekaterinburg, Europe/Sarajevo, Asia/Aden, Pacific/Chatham, Etc/GMT-12, Asia/Khandyga, America/Tegucigalpa, Atlantic/South_Georgia, EST, US/Arizona, America/Catamarca, Asia/Dhaka, Europe/Istanbul, America/Regina
- guide_line:
- One of: SBR_A_2010, SN640312a, ONORM_S_9020, UNE_22_381_93, SBR_A_2017, SBR_B_2002, SS_4604861, Circulaire86, DIN4150_3_80Hz, IN1226, SS_025211, DIN4150_2, BS7385_250Hz, ISEE_250Hz
- category (optional):
- One of: CAT3, CAT2, CAT1
- building_level:
- One of: floorSlabs, highestFloor, structure, pipeline, unspecified, buildingClass5, freshConcrete, undergroundCavities, guidelineValues, USBM_RI8507_drywall, buildingClass3, dinFoundation, buildingClass1, buildingClass2, USBM_RI8507_plaster, lowerLevel, selfDefined, OSMRE_1983, foundation, buildingClass4
- flat_level:
- Only available when the building_level is set to unspecified.
This will be an absolute value as alarm level.
- vector_enabled:
- On, Off, setting it to On will store the PVS (peak vector sum)
and also trigger (non frequency dependend) alarms based on PVS.
- vdv_enabled:
- On, Off, setting it to On will calculate and store VDV (vibration dose value)
- atop_enabled:
- On, Off, setting it to On will calculate and store PPA (peak particle acceleration)
- vtop_enabled:
- On, Off, setting it to Off will prevent calculating and storing PPV (peak particle acceleration)
- vdv_period:
- Will be used as the measurement duration for calculating VDV
- vdv_x:
- One of: BS6841_Wf, ISO2631_Wf, ISO2631_Wm, ISO8041_Wh, ISO2631_Wc, ISO2631_Wk, ISO2631_Wj, BS6841_Wd, BS6841_Wc, BS6841_Wg, ISO5349_Wh, ISO2631_We, BS6841_We, ISO2631_Wd, BS6841_Wb
- vdv_y:
- One of: BS6841_Wf, ISO2631_Wf, ISO2631_Wm, ISO8041_Wh, ISO2631_Wc, ISO2631_Wk, ISO2631_Wj, BS6841_Wd, BS6841_Wc, BS6841_Wg, ISO5349_Wh, ISO2631_We, BS6841_We, ISO2631_Wd, BS6841_Wb
- vdv_z:
- One of: BS6841_Wf, ISO2631_Wf, ISO2631_Wm, ISO8041_Wh, ISO2631_Wc, ISO2631_Wk, ISO2631_Wj, BS6841_Wd, BS6841_Wc, BS6841_Wg, ISO5349_Wh, ISO2631_We, BS6841_We, ISO2631_Wd, BS6841_Wb
- measuring_type:
- Needed with SBR, DIN 4150-3 and Circulaire86 measurements. One of extensive, limited, indicative
- concrete_setting_level
- Used with IN 1226. One of moreThan15MPa, lessThan2hours, lessThan10MPa, rc10MPaTo15MPa
- vibration_source
- Used with IN 1226. One of blasting, mechanicalDevices, pilingSheetingExcavation, compaction
- vibration_type:
- Needed with SBR, DIN 4150-3 and Circulaire86 measurements. One of peak, repeated, continually, continuous, shortTerm, longTerm, momentarily, impulsive
- building_state:
- Needed with SBR 2017. One of normal, sensitive
- zet_gev_laagdikte:
- Needed with SBR 2017 when the category is foundation. One of H_5m, H_6m, H_3m, H_4m, H_8m, H_2m, H_1m, H_7m
- lining_material:
- One of: materialClass1, masonry, reinforcedConcreteAndTubing, concreteAndStone, materialClass3, materialClass4, materialClass2
- construction_type:
- One of: structureType1, verySensitiveConstruction, sensitiveConstruction, designClass2, resistantConstruction, structureType3, structureType2, designClass1, platformAndCatenaryPost, designClass3
- pipeline_type:
- One of: brickworkAndPlastic, weldedSteel, concreteAndSteel
- data_save_level:
- float number in mm/s, threshold for storing measurement samples
- measurement_duration:
- Interval in seconds, at this interval samples will be taken
- trace_save_level:
- float number in mm/s, threshold for storing traces
- trace_pre_trigger:
- float number in seconds: when trace_save_level was passed how many seconds before are
included in the trace
- trace_post_trigger:
- float number in seconds: when trace_save_level was passed how many seconds after are
included in the trace
- alarm_level_1:
- int number in percentage: percentage of the guideline which will cause an alarm for group 1
- alarm_level_2:
- int number in percentage: percentage of the guideline which will cause an alarm for group 2
- alarm_level_3:
- int number in percentage: percentage of the guideline which will cause an alarm for group 3
- email_delay:
- int number in seconds: how much time will there be between two e-mails
- alarm_recipients:
- a list of lists containing 3 strings: where the first element is the type,
the second element the value for the type and the last element which alarm level
should trigger sending the notification.
- webhook_recipient (optional):
- an extra recipient that sends alarm notifications to a webhook.
The webhook will send POST requests with a UTF-8-encoded JSON body containing
the notification info. The secret provided combined with the request body will be hashed using
HMAC sha-256. The hash will be placed inside of the http-header: X-Omnidots-Notifier-Signature.
Make sure to calculate the hash on the receiving end as well and to compare these hashes.
- There will be some variation between the different types and categories of notifications but
all of them will atleast contain the following information:
{
"measuring_point_id": 1337,
"category": "sensor_went_online",
"level": "success",
"created_at": 1618488056.925577,
"data": { "sensor": "HOSEVE", "datetime": 1618488056.922907 },
"text": "Your Swarm HOSEVE went online on April 15, 2021, 2:00:56 p.m. CEST."
}
- enable_time_[0-6]:
- Scheduled start time of the Swarm, note that 0 is Sunday
- disable_time_[0-6]:
- Scheduled end time of the Swarm, note that 0 is Sunday
Example body:
{
"name": "Test 123",
"sensor_name": "BANANA"
"postal_code": "1234 AB",
"house_number": 56,
"street_name": "Test road",
"city": "Awesome town",
"disable_led": true,
"log_flush_interval": 60,
"timezone": "Europe/Amsterdam",
"guide_line": "SBR_A",
"category": "CAT1",
"measuring_type": "Extensive",
"vibration_type": "Repeated",
"data_save_level": 0.2,
"measurement_duration": 2.0,
"trace_save_level": 10.0,
"trace_pre_trigger": 3.0,
"trace_post_trigger": 3.0,
"alarm_level_1": 90,
"alarm_level_2": 100,
"alarm_level_3": 100,
"email_delay": 120,
"alarm_recipients": [
["phone_number", "+31850070336", "alarm_level_3"],
["phone_number", "+31850070336", "measuring_point_administrator"],
["email", "info@omnidots.com", "alarm_level_1"]
],
"webhook_recipient": {
"url": "https://your-web-address.domain/webhook",
"secret": "high-entropy-secret-0l25a9df7d8afd5ec",
"alarm_level_1": false,
"alarm_level_2": false,
"alarm_level_3": false,
"measuring_point_administrator": true
},
"enable_time_0": "00:00:00",
"disable_time_0": "23:59:59",
"enable_time_1": "00:08:00",
"disable_time_1": "18:00:00",
"enable_time_2": "00:00:00",
"disable_time_2": "23:59:59",
"enable_time_3": "00:00:00",
"disable_time_3": "23:59:59",
"enable_time_4": "00:00:00",
"disable_time_4": "23:59:59",
"enable_time_5": "00:00:00",
"disable_time_5": "23:59:59",
"enable_time_6": "00:00:00",
"disable_time_6": "23:59:59",
}
Available API endpoints: