Camera
Camera
Camera class.
clip_device_camera
Generate a video clip of up to 5 minutes long.
API documentation: clipDeviceCamera
Parameters:
-
serial(str) –Serial.
-
start_timestamp(str) –The start time for the clip. The timestamp is expected to be in ISO 8601 format.
-
end_timestamp(str) –The end time for the clip. The timestamp is expected to be in ISO 8601 format.
-
imager_id(int | None, default:None) –The imager ID to query. Required for multi-imager cameras (must be between 1 and the imager count). For single-imager cameras, must be omitted or set to 0.
Returns:
-
ClipDeviceCameraResponse–Successful operation.
Example API response
{
"url": "https://spn4.meraki.com/stream/jpeg/snapshot/b2d123asdf423qd22d2",
"expiry": "Access to the image will expire at 2018-12-11T03:12:39Z."
}
create_network_camera_quality_retention_profile
Creates new quality retention profile for this network.
API documentation: createNetworkCameraQualityRetentionProfile
Parameters:
-
network_id(str) –Network ID.
-
name(str) –The name of the new profile. Must be unique. This parameter is required.
-
motion_based_retention_enabled(bool | None, default:None) –Deletes footage older than 3 days in which no motion was detected. Can be either true or false. Defaults to false. This setting does not apply to MV2 cameras.
-
restricted_bandwidth_mode_enabled(bool | None, default:None) –Disable features that require additional bandwidth such as Motion Recap. Can be either true or false. Defaults to false. This setting does not apply to MV2 cameras.
-
audio_recording_enabled(bool | None, default:None) –Whether or not to record audio. Can be either true or false. Defaults to false.
-
cloud_archive_enabled(bool | None, default:None) –Create redundant video backup using Cloud Archive. Can be either true or false. Defaults to false.
-
motion_detector_version(int | None, default:None) –The version of the motion detector that will be used by the camera. Only applies to Gen 2 cameras. Defaults to v2.
-
smart_retention(CreateNetworkCameraQualityRetentionProfileSmartRetention | None, default:None) –Smart Retention records footage in two qualities and intelligently retains higher quality when motion, people or vehicles are detected.
-
schedule_id(str | None, default:None) –Schedule for which this camera will record video, or 'null' to always record.
-
max_retention_days(int | None, default:None) –The maximum number of days for which the data will be stored, or 'null' to keep data until storage space runs out. If the former, it can be in the range of one to ninety days.
-
video_settings(CreateNetworkCameraQualityRetentionProfileVideoSettings | None, default:None) –Video quality and resolution settings for all the camera models.
Returns:
-
NetworkCameraQualityRetentionProfileResponse–Successful operation.
Example API response
{
"id": "1234",
"networkId": "N_24329156",
"name": "Sample quality retention profile",
"restrictedBandwidthModeEnabled": true,
"motionBasedRetentionEnabled": false,
"audioRecordingEnabled": false,
"cloudArchiveEnabled": false,
"maxRetentionDays": 7,
"scheduleId": "1234",
"motionDetectorVersion": 2,
"smartRetention": {
"enabled": true
},
"videoSettings": {
"MV32": {
"quality": "Enhanced",
"resolution": "1080x1080"
}
}
}
create_network_camera_wireless_profile
Creates a new camera wireless profile for this network.
API documentation: createNetworkCameraWirelessProfile
Parameters:
-
network_id(str) –Network ID.
-
name(str) –The name of the camera wireless profile. This parameter is required.
-
ssid(CreateNetworkCameraWirelessProfileSsid) –The details of the SSID config.
-
identity(CreateNetworkCameraWirelessProfileIdentity | None, default:None) –The identity of the wireless profile. Required for creating wireless profiles in 8021x-radius auth mode.
Returns:
-
NetworkCameraWirelessProfileResponse–Successful operation.
Example API response
{
"id": "152",
"name": "wireless profile A",
"appliedDeviceCount": 0,
"ssid": {
"name": "ssid test",
"authMode": "8021x-radius",
"encryptionMode": "wpa-eap",
"psk": "sampleKey"
},
"identity": {
"username": "identityname",
"password": "password123"
}
}
create_organization_camera_custom_analytics_artifact
Create custom analytics artifact.
API documentation: createOrganizationCameraCustomAnalyticsArtifact
Parameters:
-
organization_id(str) –Organization ID.
-
name(str | None, default:None) –Unique name of the artifact.
Returns:
-
CreateOrganizationCameraCustomAnalyticsArtifactResponse–Successful operation.
Example API response
{
"artifactId": "1",
"organizationId": "2",
"name": "example",
"status": {
"type": "pending",
"message": "sample message"
},
"uploadId": "00112233445566778899aabbccddeeff",
"uploadUrl": "https://meraki_custom_cv_upload_url",
"uploadUrlExpiry": "2022-01-23T01:23:45.123456+00:00"
}
create_organization_camera_role
Creates new role for this organization.
API documentation: createOrganizationCameraRole
Parameters:
-
organization_id(str) –Organization ID.
-
name(str) –The name of the new role. Must be unique. This parameter is required.
-
applied_on_devices(list[CreateOrganizationCameraRoleAppliedOnDevicesItem] | None, default:None) –Device tag on which this specified permission is applied.
-
applied_on_networks(list[CreateOrganizationCameraRoleAppliedOnNetworksItem] | None, default:None) –Network tag on which this specified permission is applied.
-
applied_org_wide(list[CreateOrganizationCameraRoleAppliedOrgWideItem] | None, default:None) –Permissions to be applied org wide.
Returns:
-
OrganizationCameraRoleResponse–Successful operation.
Example API response
{
"name": "Security_Guard",
"appliedOnDevices": [
{
"tag": "reception-desk",
"id": "",
"permissionScopeId": "1",
"permissionScope": "camera-video",
"permissionLevel": "view_and_export"
}
],
"appliedOnNetworks": [
{
"tag": "",
"id": "2568",
"permissionScopeId": "2",
"permissionScope": "camera-video",
"permissionLevel": "view"
}
],
"appliedOrgWide": [
{
"tag": "building-a",
"permissionScopeId": "2",
"permissionScope": "camera_video",
"permissionLevel": "view_live"
}
]
}
delete_network_camera_quality_retention_profile
Delete an existing quality retention profile for this network.
API documentation: deleteNetworkCameraQualityRetentionProfile
Parameters:
-
network_id(str) –Network ID.
-
quality_retention_profile_id(str) –Quality retention profile ID.
Returns:
-
None–Successful operation.
delete_network_camera_wireless_profile
Delete an existing camera wireless profile for this network.
API documentation: deleteNetworkCameraWirelessProfile
Parameters:
-
network_id(str) –Network ID.
-
wireless_profile_id(str) –Wireless profile ID.
Returns:
-
None–Successful operation.
delete_organization_camera_custom_analytics_artifact
Delete Custom Analytics Artifact.
API documentation: deleteOrganizationCameraCustomAnalyticsArtifact
Parameters:
-
organization_id(str) –Organization ID.
-
artifact_id(str) –Artifact ID.
Returns:
-
None–Successful operation.
delete_organization_camera_role
Delete an existing role for this organization.
API documentation: deleteOrganizationCameraRole
Parameters:
-
organization_id(str) –Organization ID.
-
role_id(str) –Role ID.
Returns:
-
None–Successful operation.
generate_device_camera_snapshot
Generate a snapshot of what the camera sees at the specified time and return a link to that image.
API documentation: generateDeviceCameraSnapshot
Parameters:
-
serial(str) –Serial.
-
timestamp(str | None, default:None) –[optional] The snapshot will be taken from this time on the camera. The timestamp is expected to be in ISO 8601 format. If no timestamp is specified, we will assume current time.
-
fullframe(bool | None, default:None) –[optional] If set to "true" the snapshot will be taken at full sensor resolution. This will error if used with timestamp.
Returns:
-
ClipDeviceCameraResponse–Successful operation.
Example API response
{
"url": "https://spn4.meraki.com/stream/jpeg/snapshot/b2d123asdf423qd22d2",
"expiry": "Access to the image will expire at 2018-12-11T03:12:39Z."
}
get_device_camera_analytics_live
Returns live state from camera analytics zones.
API documentation: getDeviceCameraAnalyticsLive
Parameters:
-
serial(str) –Serial.
Returns:
-
GetDeviceCameraAnalyticsLiveResponse–Successful operation.
Example API response
{
"ts": "2018-08-15T18:32:38.123Z",
"zones": {
"zoneId": {
"person": 0
}
}
}
get_device_camera_analytics_overview
Returns an overview of aggregate analytics data for a timespan.
API documentation: getDeviceCameraAnalyticsOverview
Parameters:
-
serial(str) –Serial.
-
t0(str | None, default:None) –The beginning of the timespan for the data. The maximum lookback period is 365 days from today.
-
t1(str | None, default:None) –The end of the timespan for the data. t1 can be a maximum of 7 days after t0.
-
timespan(float | None, default:None) –The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be less than or equal to 7 days. The default is 1 hour.
-
object_type(GetDeviceCameraAnalyticsOverviewObjectType | None, default:None) –[optional] The object type for which analytics will be retrieved. The default object type is person. The available types are [person, vehicle].
Returns:
-
PaginatedResponse[GetDeviceCameraAnalyticsOverviewResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"startTs": "2018-08-15T18:32:38.123Z",
"endTs": "2018-08-15T18:33:38.123Z",
"zoneId": 0,
"entrances": 254,
"averageCount": 5.0
}
]
get_device_camera_analytics_recent
Returns most recent record for analytics zones.
API documentation: getDeviceCameraAnalyticsRecent
Parameters:
-
serial(str) –Serial.
-
object_type(GetDeviceCameraAnalyticsRecentObjectType | None, default:None) –[optional] The object type for which analytics will be retrieved. The default object type is person. The available types are [person, vehicle].
Returns:
-
PaginatedResponse[GetDeviceCameraAnalyticsOverviewResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"startTs": "2018-08-15T18:32:38.123Z",
"endTs": "2018-08-15T18:33:38.123Z",
"zoneId": 0,
"entrances": 10,
"averageCount": 2.54
}
]
get_device_camera_analytics_zone_history
Return historical records for analytic zones.
API documentation: getDeviceCameraAnalyticsZoneHistory
Parameters:
-
serial(str) –Serial.
-
zone_id(str) –Zone ID.
-
t0(str | None, default:None) –The beginning of the timespan for the data. The maximum lookback period is 365 days from today.
-
t1(str | None, default:None) –The end of the timespan for the data. t1 can be a maximum of 14 hours after t0.
-
timespan(float | None, default:None) –The timespan for which the information will be fetched. If specifying timespan, do not specify parameters t0 and t1. The value must be in seconds and be less than or equal to 14 hours. The default is 1 hour.
-
resolution(int | None, default:None) –The time resolution in seconds for returned data. The valid resolutions are: 60. The default is 60.
-
object_type(GetDeviceCameraAnalyticsZoneHistoryObjectType | None, default:None) –[optional] The object type for which analytics will be retrieved. The default object type is person. The available types are [person, vehicle].
Returns:
-
PaginatedResponse[GetDeviceCameraAnalyticsZoneHistoryResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"startTs": "2018-08-15T18:32:38.123Z",
"endTs": "2018-08-15T18:33:38.123Z",
"entrances": 5,
"averageCount": 1.5
}
]
get_device_camera_analytics_zones
Returns all configured analytic zones for this camera.
API documentation: getDeviceCameraAnalyticsZones
Parameters:
-
serial(str) –Serial.
Returns:
-
PaginatedResponse[GetDeviceCameraAnalyticsZonesResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"id": "0",
"type": "occupancy",
"label": "Full Frame",
"regionOfInterest": {
"x0": "0.00",
"y0": "0.00",
"x1": "1.00",
"y1": "1.00"
}
}
]
get_device_camera_custom_analytics
Return custom analytics settings for a camera.
API documentation: getDeviceCameraCustomAnalytics
Parameters:
-
serial(str) –Serial.
Returns:
-
DeviceCameraCustomAnalyticsResponse–Successful operation.
Example API response
{
"enabled": true,
"artifactId": "1",
"parameters": [
{
"name": "detection_threshold",
"value": 0.5
}
]
}
get_device_camera_quality_and_retention
Returns quality and retention settings for the given camera.
API documentation: getDeviceCameraQualityAndRetention
Parameters:
-
serial(str) –Serial.
Returns:
-
DeviceCameraQualityAndRetentionResponse–Successful operation.
Example API response
{
"profileId": "1234",
"motionBasedRetentionEnabled": false,
"audioRecordingEnabled": false,
"restrictedBandwidthModeEnabled": false,
"quality": "Standard",
"resolution": "1280x720",
"motionDetectorVersion": 2
}
get_device_camera_sense
Returns sense settings for a given camera.
API documentation: getDeviceCameraSense
Parameters:
-
serial(str) –Serial.
Returns:
-
DeviceCameraSenseResponse–Successful operation.
Example API response
{
"senseEnabled": true,
"mqttBrokerId": "1234",
"mqttTopics": [
"/merakimv/Q2AA-AAAA-1111/raw_detections",
"/merakimv/Q2AA-AAAA-1111/light"
],
"audioDetection": {
"enabled": false
},
"detectionModelId": "1234"
}
get_device_camera_sense_object_detection_models
Returns the MV Sense object detection model list for the given camera.
API documentation: getDeviceCameraSenseObjectDetectionModels
Parameters:
-
serial(str) –Serial.
Returns:
-
PaginatedResponse[GetDeviceCameraSenseObjectDetectionModelsResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"id": "0",
"description": "Model A"
}
]
get_device_camera_video_link
Returns video link to the specified camera.
API documentation: getDeviceCameraVideoLink
Parameters:
-
serial(str) –Serial.
-
timestamp(str | None, default:None) –[optional] The video link will start at this time. The timestamp should be a string in ISO8601 format. If no timestamp is specified, we will assume current time.
Returns:
-
GetDeviceCameraVideoLinkResponse–Successful operation.
Example API response
{
"url": "https://n1.meraki.com/office-cameras/n/sample/manage/nodes/new_list/1284392014819?timestamp=1284392014819",
"visionUrl": "https://vision.meraki.com/n/2930418/cameras/1284392014819?ts=1284392014819"
}
get_device_camera_video_settings
Returns video settings for the given camera.
API documentation: getDeviceCameraVideoSettings
Parameters:
-
serial(str) –Serial.
Returns:
-
DeviceCameraVideoSettingsResponse–Successful operation.
Example API response
{
"externalRtspEnabled": true,
"rtspUrl": "rtsp://10.0.0.1:9000/live"
}
get_device_camera_wireless_profiles
Returns wireless profile assigned to the given camera.
API documentation: getDeviceCameraWirelessProfiles
Parameters:
-
serial(str) –Serial.
Returns:
-
DeviceCameraWirelessProfilesResponse–Successful operation.
Example API response
{
"ids": {
"primary": "3",
"secondary": "2",
"backup": "1"
}
}
get_network_camera_quality_retention_profile
Retrieve a single quality retention profile.
API documentation: getNetworkCameraQualityRetentionProfile
Parameters:
-
network_id(str) –Network ID.
-
quality_retention_profile_id(str) –Quality retention profile ID.
Returns:
-
NetworkCameraQualityRetentionProfileResponse–Successful operation.
Example API response
{
"id": "1234",
"networkId": "N_24329156",
"name": "Sample quality retention profile",
"restrictedBandwidthModeEnabled": true,
"motionBasedRetentionEnabled": false,
"audioRecordingEnabled": false,
"cloudArchiveEnabled": false,
"maxRetentionDays": 7,
"scheduleId": "1234",
"motionDetectorVersion": 2,
"smartRetention": {
"enabled": true
},
"videoSettings": {
"MV32": {
"quality": "Enhanced",
"resolution": "1080x1080"
}
}
}
get_network_camera_quality_retention_profiles
List the quality retention profiles for this network.
API documentation: getNetworkCameraQualityRetentionProfiles
Parameters:
-
network_id(str) –Network ID.
Returns:
-
PaginatedResponse[NetworkCameraQualityRetentionProfileResponse]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"id": "1234",
"networkId": "N_24329156",
"name": "Sample quality retention profile",
"restrictedBandwidthModeEnabled": true,
"motionBasedRetentionEnabled": false,
"audioRecordingEnabled": false,
"cloudArchiveEnabled": false,
"maxRetentionDays": 7,
"scheduleId": "1234",
"motionDetectorVersion": 2,
"smartRetention": {
"enabled": true
},
"videoSettings": {
"MV32": {
"quality": "Enhanced",
"resolution": "1080x1080"
}
}
}
]
get_network_camera_schedules
Returns a list of all camera recording schedules.
API documentation: getNetworkCameraSchedules
Parameters:
-
network_id(str) –Network ID.
Returns:
-
PaginatedResponse[GetNetworkCameraSchedulesResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"id": "123",
"name": "Weekday schedule"
}
]
get_network_camera_wireless_profile
Retrieve a single camera wireless profile.
API documentation: getNetworkCameraWirelessProfile
Parameters:
-
network_id(str) –Network ID.
-
wireless_profile_id(str) –Wireless profile ID.
Returns:
-
NetworkCameraWirelessProfileResponse–Successful operation.
Example API response
{
"id": "152",
"name": "wireless profile A",
"appliedDeviceCount": 0,
"ssid": {
"name": "ssid test",
"authMode": "8021x-radius",
"encryptionMode": "wpa-eap",
"psk": "sampleKey"
},
"identity": {
"username": "identityname",
"password": "password123"
}
}
get_network_camera_wireless_profiles
List the camera wireless profiles for this network.
API documentation: getNetworkCameraWirelessProfiles
Parameters:
-
network_id(str) –Network ID.
Returns:
-
PaginatedResponse[NetworkCameraWirelessProfileResponse]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"id": "152",
"name": "wireless profile A",
"appliedDeviceCount": 0,
"ssid": {
"name": "ssid test",
"authMode": "8021x-radius",
"encryptionMode": "wpa-eap",
"psk": "sampleKey"
},
"identity": {
"username": "identityname",
"password": "password123"
}
}
]
get_organization_camera_boundaries_areas_by_device
Returns all configured area boundaries of cameras.
API documentation: getOrganizationCameraBoundariesAreasByDevice
Parameters:
-
organization_id(str) –Organization ID.
-
serials(list[str] | None, default:None) –A list of serial numbers. The returned cameras will be filtered to only include these serials.
Returns:
-
PaginatedResponse[GetOrganizationCameraBoundariesAreasByDeviceResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"networkId": "N_24329156",
"serial": "Q234-ABCD-5678",
"boundaries": {
"id": "k74272e",
"type": "area",
"name": "myarea",
"vertices": [
{
"x": 0.1,
"y": 0.1
}
]
}
}
]
get_organization_camera_boundaries_lines_by_device
Returns all configured crossingline boundaries of cameras.
API documentation: getOrganizationCameraBoundariesLinesByDevice
Parameters:
-
organization_id(str) –Organization ID.
-
serials(list[str] | None, default:None) –A list of serial numbers. The returned cameras will be filtered to only include these serials.
Returns:
-
PaginatedResponse[GetOrganizationCameraBoundariesLinesByDeviceResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"networkId": "N_24329156",
"serial": "Q234-ABCD-5678",
"boundaries": {
"id": "k74272e",
"type": "line",
"name": "mycline",
"vertices": [
{
"x": 0.375,
"y": 0.5
}
],
"directionVertex": {
"x": 0.5,
"y": 0.54
}
}
}
]
get_organization_camera_custom_analytics_artifact
Get Custom Analytics Artifact.
API documentation: getOrganizationCameraCustomAnalyticsArtifact
Parameters:
-
organization_id(str) –Organization ID.
-
artifact_id(str) –Artifact ID.
Returns:
-
GetOrganizationCameraCustomAnalyticsArtifactResponse–Successful operation.
Example API response
{
"artifactId": "1",
"organizationId": "2",
"name": "example",
"status": {
"type": "pending",
"message": "sample message"
}
}
get_organization_camera_custom_analytics_artifacts
List Custom Analytics Artifacts.
API documentation: getOrganizationCameraCustomAnalyticsArtifacts
Parameters:
-
organization_id(str) –Organization ID.
Returns:
-
PaginatedResponse[GetOrganizationCameraCustomAnalyticsArtifactResponse]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"artifactId": "1",
"organizationId": "2",
"name": "example",
"status": {
"type": "pending",
"message": "sample message"
}
}
]
get_organization_camera_detections_history_by_boundary_by_interval
Returns analytics data for timespans.
API documentation: getOrganizationCameraDetectionsHistoryByBoundaryByInterval
Parameters:
-
organization_id(str) –Organization ID.
-
boundary_ids(list[str]) –A list of boundary ids. The returned cameras will be filtered to only include these ids.
-
ranges(list[dict[str, Any]]) –A list of time ranges with intervals.
-
duration(int | None, default:None) –The minimum time, in seconds, that the person or car remains in the area to be counted. Defaults to boundary configuration or 60.
-
per_page(int | None, default:None) –The number of entries per page returned. Acceptable range is 1 - 1000. Defaults to 1000.
-
boundary_types(GetOrganizationCameraDetectionsHistoryByBoundaryByIntervalBoundaryTypes | None, default:None) –The detection types. Defaults to 'person'.
-
total_pages(int | Literal['all'], default:'all') –use with per_page to get total results up to total_pages * per_page; -1 or "all" for all pages.
-
direction(Literal['prev', 'next'], default:'next') –direction to paginate, either "next" (default) or "prev" page.
Returns:
-
PaginatedResponse[GetOrganizationCameraDetectionsHistoryByBoundaryByIntervalResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"boundaryId": "k74272e",
"type": "line",
"results": {
"startTime": "2018-02-11T00:00:00Z",
"endTime": "2018-05-12T00:00:00Z",
"objectType": "person",
"in": 22,
"out": 13
}
}
]
get_organization_camera_onboarding_statuses
Fetch onboarding status of cameras.
API documentation: getOrganizationCameraOnboardingStatuses
Parameters:
-
organization_id(str) –Organization ID.
-
serials(list[str] | None, default:None) –A list of serial numbers. The returned cameras will be filtered to only include these serials.
-
network_ids(list[str] | None, default:None) –A list of network IDs. The returned cameras will be filtered to only include these networks.
Returns:
-
PaginatedResponse[GetOrganizationCameraOnboardingStatusesResponseItem]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"networkId": "N_12345",
"serial": "Q234-ABCD-5678",
"status": "pending onboarding",
"updatedAt": "2018-02-11T00:00:00.090210Z"
}
]
get_organization_camera_permission
Retrieve a single permission scope.
API documentation: getOrganizationCameraPermission
Parameters:
-
organization_id(str) –Organization ID.
-
permission_scope_id(str) –Permission scope ID.
Returns:
-
GetOrganizationCameraPermissionResponse–Successful operation.
Example API response
{
"id": "1234",
"name": "camera_video",
"level": "live_video"
}
get_organization_camera_permissions
List the permissions scopes for this organization.
API documentation: getOrganizationCameraPermissions
Parameters:
-
organization_id(str) –Organization ID.
Returns:
-
PaginatedResponse[GetOrganizationCameraPermissionResponse]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"id": "1234",
"name": "camera_video",
"level": "live_video"
}
]
get_organization_camera_role
Retrieve a single role.
API documentation: getOrganizationCameraRole
Parameters:
-
organization_id(str) –Organization ID.
-
role_id(str) –Role ID.
Returns:
-
OrganizationCameraRoleResponse–Successful operation.
Example API response
{
"name": "Security_Guard",
"appliedOnDevices": [
{
"tag": "reception-desk",
"id": "",
"permissionScopeId": "1",
"permissionScope": "camera-video",
"permissionLevel": "view_and_export"
}
],
"appliedOnNetworks": [
{
"tag": "",
"id": "2568",
"permissionScopeId": "2",
"permissionScope": "camera-video",
"permissionLevel": "view"
}
],
"appliedOrgWide": [
{
"tag": "building-a",
"permissionScopeId": "2",
"permissionScope": "camera_video",
"permissionLevel": "view_live"
}
]
}
get_organization_camera_roles
List all the roles in this organization.
API documentation: getOrganizationCameraRoles
Parameters:
-
organization_id(str) –Organization ID.
Returns:
-
PaginatedResponse[OrganizationCameraRoleResponse]–Successful operation.
Note
Returns a lazy PaginatedResponse
that can be iterated or collected with .collect().
Page metadata is available on .meta and .meta_pages.
Example API response
[
{
"name": "Security_Guard",
"appliedOnDevices": [
{
"tag": "reception-desk",
"id": "",
"permissionScopeId": "1",
"permissionScope": "camera-video",
"permissionLevel": "view_and_export"
}
],
"appliedOnNetworks": [
{
"tag": "",
"id": "2568",
"permissionScopeId": "2",
"permissionScope": "camera-video",
"permissionLevel": "view"
}
],
"appliedOrgWide": [
{
"tag": "building-a",
"permissionScopeId": "2",
"permissionScope": "camera_video",
"permissionLevel": "view_live"
}
]
}
]
update_device_camera_custom_analytics
Update custom analytics settings for a camera.
API documentation: updateDeviceCameraCustomAnalytics
Parameters:
-
serial(str) –Serial.
-
enabled(bool | None, default:None) –Enable custom analytics.
-
artifact_id(str | None, default:None) –The ID of the custom analytics artifact.
-
parameters(list[UpdateDeviceCameraCustomAnalyticsParametersItem] | None, default:None) –Parameters for the custom analytics workload.
Returns:
-
DeviceCameraCustomAnalyticsResponse–Successful operation.
Example API response
{
"enabled": true,
"artifactId": "1",
"parameters": [
{
"name": "detection_threshold",
"value": 0.5
}
]
}
update_device_camera_quality_and_retention
Update quality and retention settings for the given camera.
API documentation: updateDeviceCameraQualityAndRetention
Parameters:
-
serial(str) –Serial.
-
profile_id(str | None, default:None) –The ID of a quality and retention profile to assign to the camera. The profile's settings will override all of the per-camera quality and retention settings. If the value of this parameter is null, any existing profile will be unassigned from the camera.
-
motion_based_retention_enabled(bool | None, default:None) –Boolean indicating if motion-based retention is enabled(true) or disabled(false) on the camera.
-
audio_recording_enabled(bool | None, default:None) –Boolean indicating if audio recording is enabled(true) or disabled(false) on the camera.
-
restricted_bandwidth_mode_enabled(bool | None, default:None) –Boolean indicating if restricted bandwidth is enabled(true) or disabled(false) on the camera. This setting does not apply to MV2 cameras.
-
quality(UpdateDeviceCameraQualityAndRetentionQuality | None, default:None) –Quality of the camera. Can be one of 'Standard', 'High', 'Enhanced' or 'Ultra'. Not all qualities are supported by every camera model.
-
resolution(UpdateDeviceCameraQualityAndRetentionResolution | None, default:None) –Resolution of the camera. Can be one of '1280x720', '1920x1080', '1080x1080', '2112x2112', '2880x2880', '2688x1512' or '3840x2160'.Not all resolutions are supported by every camera model.
-
motion_detector_version(UpdateDeviceCameraQualityAndRetentionMotionDetectorVersion | None, default:None) –The version of the motion detector that will be used by the camera. Only applies to Gen 2 cameras. Defaults to v2.
Returns:
-
DeviceCameraQualityAndRetentionResponse–Successful operation.
Example API response
{
"profileId": "1234",
"motionBasedRetentionEnabled": false,
"audioRecordingEnabled": false,
"restrictedBandwidthModeEnabled": false,
"quality": "Standard",
"resolution": "1280x720",
"motionDetectorVersion": 2
}
update_device_camera_sense
Update sense settings for the given camera.
API documentation: updateDeviceCameraSense
Parameters:
-
serial(str) –Serial.
-
sense_enabled(bool | None, default:None) –Boolean indicating if sense(license) is enabled(true) or disabled(false) on the camera.
-
mqtt_broker_id(str | None, default:None) –The ID of the MQTT broker to be enabled on the camera. A value of null will disable MQTT on the camera.
-
audio_detection(UpdateDeviceCameraSenseAudioDetection | None, default:None) –The details of the audio detection config.
-
detection_model_id(str | None, default:None) –The ID of the object detection model.
Returns:
-
DeviceCameraSenseResponse–Successful operation.
Example API response
{
"senseEnabled": true,
"mqttBrokerId": "1234",
"mqttTopics": [
"/merakimv/Q2AA-AAAA-1111/raw_detections",
"/merakimv/Q2AA-AAAA-1111/light"
],
"audioDetection": {
"enabled": false
},
"detectionModelId": "1234"
}
update_device_camera_video_settings
Update video settings for the given camera.
API documentation: updateDeviceCameraVideoSettings
Parameters:
-
serial(str) –Serial.
-
external_rtsp_enabled(bool | None, default:None) –Boolean indicating if external rtsp stream is exposed.
Returns:
-
DeviceCameraVideoSettingsResponse–Successful operation.
Example API response
{
"externalRtspEnabled": true,
"rtspUrl": "rtsp://10.0.0.1:9000/live"
}
update_device_camera_wireless_profiles
Assign wireless profiles to the given camera.
API documentation: updateDeviceCameraWirelessProfiles
Parameters:
-
serial(str) –Serial.
-
ids(UpdateDeviceCameraWirelessProfilesIds) –The ids of the wireless profile to assign to the given camera.
Returns:
-
DeviceCameraWirelessProfilesResponse–Successful operation.
Example API response
{
"ids": {
"primary": "3",
"secondary": "2",
"backup": "1"
}
}
update_network_camera_quality_retention_profile
Update an existing quality retention profile for this network.
API documentation: updateNetworkCameraQualityRetentionProfile
Parameters:
-
network_id(str) –Network ID.
-
quality_retention_profile_id(str) –Quality retention profile ID.
-
name(str | None, default:None) –The name of the new profile. Must be unique.
-
motion_based_retention_enabled(bool | None, default:None) –Deletes footage older than 3 days in which no motion was detected. Can be either true or false. Defaults to false. This setting does not apply to MV2 cameras.
-
restricted_bandwidth_mode_enabled(bool | None, default:None) –Disable features that require additional bandwidth such as Motion Recap. Can be either true or false. Defaults to false. This setting does not apply to MV2 cameras.
-
audio_recording_enabled(bool | None, default:None) –Whether or not to record audio. Can be either true or false. Defaults to false.
-
cloud_archive_enabled(bool | None, default:None) –Create redundant video backup using Cloud Archive. Can be either true or false. Defaults to false.
-
motion_detector_version(int | None, default:None) –The version of the motion detector that will be used by the camera. Only applies to Gen 2 cameras. Defaults to v2.
-
smart_retention(UpdateNetworkCameraQualityRetentionProfileSmartRetention | None, default:None) –Smart Retention records footage in two qualities and intelligently retains higher quality when motion, people or vehicles are detected.
-
schedule_id(str | None, default:None) –Schedule for which this camera will record video, or 'null' to always record.
-
max_retention_days(int | None, default:None) –The maximum number of days for which the data will be stored, or 'null' to keep data until storage space runs out. If the former, it can be in the range of one to ninety days.
-
video_settings(UpdateNetworkCameraQualityRetentionProfileVideoSettings | None, default:None) –Video quality and resolution settings for all the camera models.
Returns:
-
NetworkCameraQualityRetentionProfileResponse–Successful operation.
Example API response
{
"id": "1234",
"networkId": "N_24329156",
"name": "Sample quality retention profile",
"restrictedBandwidthModeEnabled": true,
"motionBasedRetentionEnabled": false,
"audioRecordingEnabled": false,
"cloudArchiveEnabled": false,
"maxRetentionDays": 7,
"scheduleId": "1234",
"motionDetectorVersion": 2,
"smartRetention": {
"enabled": true
},
"videoSettings": {
"MV32": {
"quality": "Enhanced",
"resolution": "1080x1080"
}
}
}
update_network_camera_wireless_profile
Update an existing camera wireless profile in this network.
API documentation: updateNetworkCameraWirelessProfile
Parameters:
-
network_id(str) –Network ID.
-
wireless_profile_id(str) –Wireless profile ID.
-
name(str | None, default:None) –The name of the camera wireless profile.
-
ssid(UpdateNetworkCameraWirelessProfileSsid | None, default:None) –The details of the SSID config.
-
identity(UpdateNetworkCameraWirelessProfileIdentity | None, default:None) –The identity of the wireless profile. Required for creating wireless profiles in 8021x-radius auth mode.
Returns:
-
NetworkCameraWirelessProfileResponse–Successful operation.
Example API response
{
"id": "152",
"name": "wireless profile A",
"appliedDeviceCount": 0,
"ssid": {
"name": "ssid test",
"authMode": "8021x-radius",
"encryptionMode": "wpa-eap",
"psk": "sampleKey"
},
"identity": {
"username": "identityname",
"password": "password123"
}
}
update_organization_camera_onboarding_statuses
Notify that credential handoff to camera has completed.
API documentation: updateOrganizationCameraOnboardingStatuses
Parameters:
-
organization_id(str) –Organization ID.
-
serial(str | None, default:None) –Serial of camera.
-
wireless_credentials_sent(bool | None, default:None) –Note whether credentials were sent successfully.
Returns:
-
UpdateOrganizationCameraOnboardingStatusesResponse–Successful operation.
Example API response
{
"success": true
}
update_organization_camera_role
Update an existing role in this organization.
API documentation: updateOrganizationCameraRole
Parameters:
-
organization_id(str) –Organization ID.
-
role_id(str) –Role ID.
-
name(str | None, default:None) –The name of the new role. Must be unique.
-
applied_on_devices(list[UpdateOrganizationCameraRoleAppliedOnDevicesItem] | None, default:None) –Device tag on which this specified permission is applied.
-
applied_on_networks(list[UpdateOrganizationCameraRoleAppliedOnNetworksItem] | None, default:None) –Network tag on which this specified permission is applied.
-
applied_org_wide(list[UpdateOrganizationCameraRoleAppliedOrgWideItem] | None, default:None) –Permissions to be applied org wide.
Returns:
-
OrganizationCameraRoleResponse–Successful operation.
Example API response
{
"name": "Security_Guard",
"appliedOnDevices": [
{
"tag": "reception-desk",
"id": "",
"permissionScopeId": "1",
"permissionScope": "camera-video",
"permissionLevel": "view_and_export"
}
],
"appliedOnNetworks": [
{
"tag": "",
"id": "2568",
"permissionScopeId": "2",
"permissionScope": "camera-video",
"permissionLevel": "view"
}
],
"appliedOrgWide": [
{
"tag": "building-a",
"permissionScopeId": "2",
"permissionScope": "camera_video",
"permissionLevel": "view_live"
}
]
}