Update Noise Threshold

Update a Noise Threshold on your Noise Sensor

Update Noise Threshold

PUT https://connect.getseam.com/noise_sensors/noise_thresholds/update

Headers

NameTypeDescription

Authorization*

String

Bearer <API_KEY>

Request Body

NameTypeDescription

noise_threshold_id*

String

Noise threshold id

device_id*

String

Device id of a device the noise threshold is on

name

String

Name of the Noise Threshold

starts_daily_at

String

Time when noise threshold becomes active daily

ends_daily_at

String

Time when noise threshold becomes inactive daily

noise_threshold_decibels

String

Noise level in decibels

noise_threshold_nrs

String

Noise level in Noiseaware Noise Risk Score (NRS) (only relevant for Noiseaware sensors)

{
  "action_attempt": {
    "status": "pending",
    "action_type": "UPDATE_NOISE_THRESHOLD",
    "action_attempt_id": "c10e3db5-a5a2-47f2-a76f-48379ed9cd22",
    "result": null,
    "error": null
  },
  "ok": true
}

Code Example

seam.noise_sensors.noise_thresholds.update(
  noise_threshold_id="792263f8-1660-4cf9-a6c6-054d23b78d86",
  device_id="123e4567-e89b-12d3-a456-426614174000",
  noise_threshold_decibels=75
)

# {
#   "noise_threshold_id": "792263f8-1660-4cf9-a6c6-054d23b78d86",
#   "device_id": "123e4567-e89b-12d3-a456-426614174000",
#   "name": "builtin_quiet_hours",
#   "noise_threshold_decibels": 75,
#   "starts_daily_at": "22:00:00[America/Los_Angeles]",
#   "ends_daily_at": "06:00:00[America/Los_Angeles]",
# }

Parameters

device_id

type: string

Device id of a device to create a noise threshold on

noise_threshold_id

string

Noise Threshold Id

name

string

Name of the Noise Threshold

starts_daily_at

Timestamp of when the Noise Threshold becomes active daily

ends_daily_at

Timestamp of when the Noise Threshold becomes inactive daily

noise_threshold_decibels

number

The noise level in decibels

noise_threshold_nrs

number, optional

Noise Level in Noiseaware Noise Risk Score (NRS) (only relevant for Noiseaware sensors)

Response

This section shows the JSON response returned by the API. Since each language encapsulates this response inside objects specific to that language and/or implementation, the actual type in your language might differ from what’s written here.

JSON format

{
  "action_attempt": {
    "status": "pending",
    "action_type": "UPDATE_NOISE_THRESHOLD",
    "action_attempt_id": "c10e3db5-a5a2-47f2-a76f-48379ed9cd22",
    "result": null,
    "error": null
  },
  "ok": true
}

Last updated

Logo

© Seam Labs, Inc. All rights reserved.