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: Canada/Pacific, Canada/Atlantic, GMT, Asia/Harbin, Etc/UTC, Pacific/Kosrae, Etc/GMT-10, America/Boa_Vista, Europe/Zaporozhye, Australia/Tasmania, Indian/Christmas, America/Fortaleza, Pacific/Fiji, Europe/Vienna, America/Knox_IN, America/Tijuana, America/Bahia_Banderas, Asia/Tel_Aviv, ROC, America/Grenada, Africa/Kampala, America/Boise, America/Guadeloupe, Pacific/Ponape, Asia/Tbilisi, UTC, Europe/Podgorica, Antarctica/Rothera, Pacific/Palau, America/Indiana/Winamac, America/Merida, America/Hermosillo, Europe/Monaco, Europe/Nicosia, Africa/Blantyre, Africa/Ceuta, America/Guyana, America/Scoresbysund, Asia/Novosibirsk, Europe/Budapest, Singapore, Africa/Cairo, America/Yakutat, Asia/Baghdad, Europe/Kiev, America/Porto_Velho, Africa/Douala, Asia/Yangon, Asia/Samarkand, Pacific/Funafuti, America/Montreal, Europe/Rome, Europe/Sofia, Africa/Malabo, NZ, Navajo, Asia/Choibalsan, America/Coral_Harbour, Etc/GMT-2, Europe/Belfast, America/Sitka, Europe/Belgrade, Pacific/Kiritimati, Asia/Macao, Pacific/Tongatapu, Antarctica/Mawson, CST6CDT, Europe/Andorra, Europe/San_Marino, America/Argentina/Salta, Africa/Harare, Asia/Amman, Asia/Bahrain, Mexico/BajaNorte, Etc/GMT+3, Africa/Dar_es_Salaam, Etc/GMT-5, Australia/Darwin, Zulu, America/El_Salvador, Europe/Paris, Africa/Porto-Novo, Pacific/Saipan, Asia/Chongqing, Pacific/Fakaofo, Australia/Adelaide, WET, Canada/Mountain, Asia/Hong_Kong, America/Belem, Africa/Accra, Asia/Phnom_Penh, Africa/Timbuktu, Pacific/Efate, Pacific/Johnston, Antarctica/Vostok, Australia/ACT, America/Dawson, Etc/GMT+0, Etc/GMT+9, America/Havana, America/Vancouver, America/North_Dakota/Center, Asia/Atyrau, US/Aleutian, Australia/Melbourne, Africa/Monrovia, America/Nome, Pacific/Auckland, America/Argentina/San_Juan, Etc/Universal, America/Chihuahua, America/Swift_Current, America/Guayaquil, America/Montevideo, Asia/Ust-Nera, Asia/Tokyo, MST7MDT, Indian/Maldives, Etc/GMT-7, America/Punta_Arenas, Australia/Broken_Hill, Asia/Khandyga, America/Port_of_Spain, America/Argentina/San_Luis, Cuba, Etc/GMT-4, America/North_Dakota/New_Salem, Asia/Urumqi, Indian/Mahe, Europe/Amsterdam, Greenwich, Asia/Aden, Egypt, Atlantic/Cape_Verde, Etc/GMT-3, ROK, America/Yellowknife, Indian/Mayotte, Pacific/Nauru, Etc/GMT, Asia/Beirut, Australia/Perth, Africa/Ouagadougou, Canada/Saskatchewan, Etc/Zulu, Indian/Antananarivo, Etc/GMT+11, Brazil/East, America/Moncton, Asia/Anadyr, America/Antigua, Indian/Reunion, Asia/Baku, Pacific/Wallis, Africa/Niamey, Europe/Vaduz, Asia/Makassar, US/Arizona, Africa/Sao_Tome, America/Nuuk, Europe/Dublin, Asia/Saigon, Chile/EasterIsland, US/East-Indiana, Australia/Brisbane, America/Inuvik, America/Atka, Asia/Ujung_Pandang, Europe/Ljubljana, America/Aruba, Asia/Shanghai, Etc/GMT-14, America/Fort_Nelson, America/Ojinaga, Atlantic/St_Helena, Asia/Almaty, Europe/Kaliningrad, America/Maceio, Asia/Pyongyang, HST, Australia/Canberra, Europe/Mariehamn, Europe/Simferopol, Pacific/Enderbury, Europe/Stockholm, Asia/Hovd, Africa/Kigali, Asia/Barnaul, America/Cordoba, Pacific/Kanton, Mexico/BajaSur, Europe/Uzhgorod, America/Danmarkshavn, Etc/GMT-6, America/Argentina/Catamarca, Asia/Seoul, Africa/Windhoek, Africa/Asmera, America/Anchorage, America/Nassau, Asia/Muscat, America/Panama, America/Cancun, GMT+0, Europe/Ulyanovsk, Asia/Tashkent, EST5EDT, Pacific/Pohnpei, America/Rankin_Inlet, America/Bogota, America/Porto_Acre, Europe/Guernsey, America/Lima, America/Santa_Isabel, America/Whitehorse, Europe/Zurich, America/Los_Angeles, Asia/Kuching, Africa/Ndjamena, America/Monterrey, Etc/GMT-13, Atlantic/Madeira, Asia/Kuala_Lumpur, Australia/Lindeman, America/Creston, America/Dawson_Creek, Europe/Tiraspol, Europe/Madrid, America/Marigot, Asia/Novokuznetsk, CET, America/Atikokan, Africa/Bissau, America/Fort_Wayne, Kwajalein, Asia/Riyadh, Etc/GMT+5, Europe/Tirane, Asia/Ho_Chi_Minh, Antarctica/McMurdo, Asia/Bangkok, America/Argentina/Jujuy, America/Chicago, America/Cuiaba, Australia/South, Asia/Kashgar, Asia/Istanbul, Asia/Qatar, Canada/Eastern, Australia/Currie, Asia/Kolkata, Asia/Qyzylorda, Atlantic/Reykjavik, America/Jujuy, Asia/Pontianak, Europe/Bucharest, EST, US/Eastern, America/Manaus, Europe/Busingen, Asia/Omsk, America/Metlakatla, America/Godthab, America/Thunder_Bay, Europe/Brussels, Israel, America/Santiago, Arctic/Longyearbyen, America/St_Lucia, Asia/Jerusalem, Pacific/Yap, Atlantic/Bermuda, America/Blanc-Sablon, Africa/El_Aaiun, Atlantic/South_Georgia, US/Central, Europe/Minsk, America/Belize, Pacific/Port_Moresby, Etc/GMT+12, Europe/Prague, Europe/Zagreb, America/Montserrat, Africa/Lagos, Asia/Kamchatka, America/Guatemala, Asia/Dili, Australia/Sydney, Asia/Magadan, America/Cambridge_Bay, Asia/Taipei, America/Eirunepe, Asia/Aqtau, Africa/Johannesburg, America/Shiprock, Europe/Chisinau, Pacific/Honolulu, Brazil/Acre, America/Bahia, Europe/Istanbul, Asia/Thimphu, NZ-CHAT, Pacific/Apia, Asia/Dacca, Australia/Hobart, Africa/Algiers, Hongkong, Asia/Kuwait, Africa/Bamako, Pacific/Pitcairn, America/Noronha, Canada/Newfoundland, US/Hawaii, America/Tortola, Europe/Kirov, America/Asuncion, Etc/GMT+2, Antarctica/South_Pole, Pacific/Chatham, Etc/GMT-0, Asia/Oral, Libya, Africa/Addis_Ababa, Indian/Kerguelen, Asia/Yakutsk, America/Recife, America/Anguilla, Africa/Maputo, America/Argentina/Cordoba, Antarctica/Macquarie, Europe/Luxembourg, America/Argentina/Rio_Gallegos, Asia/Hebron, US/Pacific, Europe/London, Pacific/Majuro, GB, America/Cayenne, America/Menominee, Europe/Tallinn, America/Argentina/ComodRivadavia, Asia/Sakhalin, Africa/Gaborone, Asia/Srednekolymsk, America/Santo_Domingo, America/Buenos_Aires, America/Nipigon, America/Iqaluit, America/Tegucigalpa, America/Virgin, Chile/Continental, Pacific/Noumea, America/Argentina/Buenos_Aires, America/Denver, Africa/Freetown, Antarctica/Casey, America/Rainy_River, America/St_Thomas, US/Michigan, Canada/Yukon, America/New_York, Asia/Gaza, Pacific/Easter, Asia/Kathmandu, Pacific/Tarawa, America/Kralendijk, Etc/GMT+10, Brazil/DeNoronha, Europe/Lisbon, Pacific/Tahiti, Asia/Jakarta, Etc/GMT0, Asia/Qostanay, America/Dominica, Atlantic/Stanley, America/Martinique, Asia/Dubai, Etc/GMT-11, Africa/Mbabane, Atlantic/Canary, US/Alaska, America/Argentina/Ushuaia, Portugal, Africa/Bangui, America/Caracas, PRC, America/Indiana/Vevay, Pacific/Samoa, America/Paramaribo, PST8PDT, America/Goose_Bay, Europe/Helsinki, Pacific/Guam, Mexico/General, Asia/Chungking, Europe/Athens, America/Mendoza, Africa/Tunis, Asia/Ulan_Bator, Asia/Ashkhabad, Europe/Gibraltar, Africa/Juba, Asia/Dhaka, America/Sao_Paulo, Asia/Ulaanbaatar, MST, US/Indiana-Starke, America/Argentina/Tucuman, Australia/Queensland, Antarctica/Davis, America/Costa_Rica, Australia/North, Asia/Tomsk, Indian/Mauritius, Pacific/Galapagos, Asia/Brunei, Africa/Bujumbura, Pacific/Pago_Pago, Antarctica/Syowa, Asia/Chita, Asia/Rangoon, Etc/UCT, America/Regina, America/Detroit, Europe/Samara, Asia/Krasnoyarsk, Europe/Isle_of_Man, Europe/Vilnius, Asia/Tehran, America/Kentucky/Monticello, Asia/Vientiane, America/Adak, Etc/Greenwich, Pacific/Gambier, Pacific/Marquesas, America/Juneau, America/Matamoros, Australia/NSW, UCT, Asia/Bishkek, Atlantic/Azores, Africa/Casablanca, Africa/Nouakchott, America/Glace_Bay, Antarctica/Palmer, Poland, Asia/Ashgabat, Asia/Karachi, Pacific/Rarotonga, Asia/Jayapura, America/Thule, Africa/Kinshasa, America/Indiana/Tell_City, Asia/Colombo, Africa/Asmara, Etc/GMT-1, Australia/Yancowinna, Australia/Victoria, Asia/Singapore, Etc/GMT-12, US/Samoa, America/Barbados, Europe/Warsaw, Asia/Katmandu, Etc/GMT-8, Europe/Moscow, Eire, Australia/Lord_Howe, Africa/Conakry, Pacific/Kwajalein, Iceland, US/Mountain, America/Mexico_City, W-SU, Africa/Dakar, Pacific/Midway, America/Cayman, Atlantic/Jan_Mayen, Etc/GMT+6, America/Campo_Grande, Indian/Comoro, Pacific/Chuuk, America/Puerto_Rico, Europe/Vatican, Africa/Lusaka, America/Indiana/Petersburg, America/Managua, Japan, America/Araguaina, Indian/Cocos, Atlantic/Faroe, America/St_Kitts, America/Indianapolis, Antarctica/Troll, Asia/Calcutta, Etc/GMT-9, America/North_Dakota/Beulah, Etc/GMT+8, Asia/Kabul, Pacific/Niue, Asia/Thimbu, America/Indiana/Knox, America/Santarem, America/Winnipeg, Australia/Eucla, America/Edmonton, Asia/Manila, America/Indiana/Indianapolis, America/Grand_Turk, America/Halifax, Africa/Maseru, Asia/Aqtobe, Africa/Banjul, GB-Eire, Pacific/Truk, Asia/Damascus, Australia/LHI, Africa/Lome, Atlantic/Faeroe, Europe/Astrakhan, America/La_Paz, Africa/Brazzaville, America/Rosario, Pacific/Guadalcanal, Asia/Vladivostok, Pacific/Bougainville, Europe/Volgograd, Africa/Lubumbashi, Europe/Riga, America/Indiana/Vincennes, America/Port-au-Prince, Turkey, Africa/Abidjan, Canada/Central, Africa/Mogadishu, EET, Europe/Skopje, America/Indiana/Marengo, Europe/Oslo, Jamaica, Africa/Tripoli, America/Argentina/Mendoza, Pacific/Norfolk, MET, Africa/Djibouti, America/Jamaica, GMT-0, Asia/Irkutsk, Europe/Malta, Africa/Libreville, Africa/Nairobi, America/Mazatlan, America/Miquelon, Africa/Khartoum, America/Kentucky/Louisville, America/Catamarca, Etc/GMT+1, America/Phoenix, Asia/Famagusta, Europe/Jersey, America/Pangnirtung, America/Argentina/La_Rioja, GMT0, Asia/Dushanbe, Brazil/West, America/Lower_Princes, Europe/Bratislava, Africa/Luanda, Australia/West, America/St_Barthelemy, America/Toronto, Indian/Chagos, Antarctica/DumontDUrville, Iran, America/St_Johns, America/Rio_Branco, Asia/Yerevan, Etc/GMT+7, Universal, America/St_Vincent, Asia/Yekaterinburg, America/Louisville, Europe/Sarajevo, America/Ensenada, Europe/Copenhagen, Etc/GMT+4, Europe/Berlin, Pacific/Wake, America/Curacao, Asia/Macau, America/Resolute, Asia/Nicosia, Europe/Saratov
- guide_line:
- One of: SS_025211, SBR_B_2002, DIN4150_3_80Hz, IN1226, Circulaire86, ISEE_250Hz, SBR_A_2010, ONORM_S_9020, BS7385_250Hz, SBR_A_2017, DIN4150_2, SS_4604861, SN640312a, UNE_22_381_93
- category (optional):
- One of: CAT3, CAT1, CAT2
- building_level:
- One of: structure, guidelineValues, buildingClass3, buildingClass1, buildingClass4, unspecified, dinFoundation, undergroundCavities, buildingClass5, pipeline, lowerLevel, OSMRE_1983, USBM_RI8507_drywall, highestFloor, USBM_RI8507_plaster, freshConcrete, foundation, floorSlabs, buildingClass2, selfDefined
- flat_level:
- Only available when the building_level is set to unspecified.
This will be an absolute value as alarm level.
- vector_enabled:
- Off, On, setting it to On will store the PVS (peak vector sum)
and also trigger (non frequency dependend) alarms based on PVS.
- vdv_enabled:
- Off, On, setting it to On will calculate and store VDV (vibration dose value)
- atop_enabled:
- Off, On, setting it to On will calculate and store PPA (peak particle acceleration)
- vtop_enabled:
- Off, On, 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: ISO2631_Wf, BS6841_Wb, ISO2631_Wj, ISO5349_Wh, BS6841_We, ISO8041_Wh, ISO2631_Wm, BS6841_Wf, ISO2631_Wk, ISO2631_Wc, BS6841_Wg, BS6841_Wc, ISO2631_We, BS6841_Wd, ISO2631_Wd
- vdv_y:
- One of: ISO2631_Wf, BS6841_Wb, ISO2631_Wj, ISO5349_Wh, BS6841_We, ISO8041_Wh, ISO2631_Wm, BS6841_Wf, ISO2631_Wk, ISO2631_Wc, BS6841_Wg, BS6841_Wc, ISO2631_We, BS6841_Wd, ISO2631_Wd
- vdv_z:
- One of: ISO2631_Wf, BS6841_Wb, ISO2631_Wj, ISO5349_Wh, BS6841_We, ISO8041_Wh, ISO2631_Wm, BS6841_Wf, ISO2631_Wk, ISO2631_Wc, BS6841_Wg, BS6841_Wc, ISO2631_We, BS6841_Wd, ISO2631_Wd
- measuring_type:
- Needed with SBR, DIN 4150-3 and Circulaire86 measurements. One of extensive, indicative, limited
- concrete_setting_level
- Used with IN 1226. One of rc10MPaTo15MPa, moreThan15MPa, lessThan10MPa, lessThan2hours
- vibration_source
- Used with IN 1226. One of pilingSheetingExcavation, compaction, mechanicalDevices, blasting
- vibration_type:
- Needed with SBR, DIN 4150-3 and Circulaire86 measurements. One of peak, shortTerm, continually, impulsive, momentarily, continuous, repeated, longTerm
- 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_7m, H_4m, H_3m, H_2m, H_8m, H_6m, H_1m, H_5m
- lining_material:
- One of: materialClass1, concreteAndStone, materialClass4, materialClass3, materialClass2, reinforcedConcreteAndTubing, masonry
- construction_type:
- One of: resistantConstruction, designClass1, structureType2, designClass3, designClass2, verySensitiveConstruction, sensitiveConstruction, structureType3, platformAndCatenaryPost, structureType1
- 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: