onvif-python 0.0.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (106) hide show
  1. onvif/__init__.py +13 -0
  2. onvif/client.py +485 -0
  3. onvif/operator.py +130 -0
  4. onvif/services/__init__.py +75 -0
  5. onvif/services/accesscontrol.py +105 -0
  6. onvif/services/accessrules.py +47 -0
  7. onvif/services/actionengine.py +46 -0
  8. onvif/services/analytics/analytics.py +60 -0
  9. onvif/services/analytics/ruleengine.py +44 -0
  10. onvif/services/analyticsdevice.py +122 -0
  11. onvif/services/appmgmt.py +40 -0
  12. onvif/services/authenticationbehavior.py +83 -0
  13. onvif/services/credential.py +159 -0
  14. onvif/services/deviceio.py +165 -0
  15. onvif/services/devicemgmt.py +410 -0
  16. onvif/services/display.py +62 -0
  17. onvif/services/doorcontrol.py +93 -0
  18. onvif/services/events/events.py +41 -0
  19. onvif/services/events/notification.py +34 -0
  20. onvif/services/events/pullpoint.py +29 -0
  21. onvif/services/events/subscription.py +21 -0
  22. onvif/services/imaging.py +62 -0
  23. onvif/services/media.py +424 -0
  24. onvif/services/media2.py +310 -0
  25. onvif/services/provisioning.py +50 -0
  26. onvif/services/ptz.py +187 -0
  27. onvif/services/receiver.py +46 -0
  28. onvif/services/recording.py +136 -0
  29. onvif/services/replay.py +30 -0
  30. onvif/services/schedule.py +82 -0
  31. onvif/services/search.py +149 -0
  32. onvif/services/security/advancedsecurity.py +19 -0
  33. onvif/services/security/authorizationserver.py +31 -0
  34. onvif/services/security/dot1x.py +42 -0
  35. onvif/services/security/jwt.py +21 -0
  36. onvif/services/security/keystore.py +208 -0
  37. onvif/services/security/mediasigning.py +30 -0
  38. onvif/services/security/tlsserver.py +82 -0
  39. onvif/services/thermal.py +54 -0
  40. onvif/services/uplink.py +28 -0
  41. onvif/utils/__init__.py +4 -0
  42. onvif/utils/exceptions.py +33 -0
  43. onvif/utils/wsdl.py +297 -0
  44. onvif/wsdl/ver10/accesscontrol/wsdl/index.html +7 -0
  45. onvif/wsdl/ver10/accessrules/wsdl/accessrules.wsdl +702 -0
  46. onvif/wsdl/ver10/accessrules/wsdl/index.html +7 -0
  47. onvif/wsdl/ver10/actionengine.wsdl +1265 -0
  48. onvif/wsdl/ver10/advancedsecurity/wsdl/advancedsecurity.wsdl +4159 -0
  49. onvif/wsdl/ver10/advancedsecurity/wsdl/index.html +7 -0
  50. onvif/wsdl/ver10/analyticsdevice.wsdl +709 -0
  51. onvif/wsdl/ver10/appmgmt/wsdl/appmgmt.wsdl +502 -0
  52. onvif/wsdl/ver10/appmgmt/wsdl/index.html +7 -0
  53. onvif/wsdl/ver10/authenticationbehavior/wsdl/authenticationbehavior.wsdl +1382 -0
  54. onvif/wsdl/ver10/authenticationbehavior/wsdl/index.html +7 -0
  55. onvif/wsdl/ver10/credential/wsdl/credential.wsdl +2018 -0
  56. onvif/wsdl/ver10/credential/wsdl/index.html +7 -0
  57. onvif/wsdl/ver10/device/wsdl/devicemgmt.wsdl +4623 -0
  58. onvif/wsdl/ver10/deviceio.wsdl +1414 -0
  59. onvif/wsdl/ver10/display/display.wsdl +383 -0
  60. onvif/wsdl/ver10/display/wsdl/index.htm +383 -0
  61. onvif/wsdl/ver10/display.wsdl +521 -0
  62. onvif/wsdl/ver10/doorcontrol/wsdl/index.html +7 -0
  63. onvif/wsdl/ver10/events/wsdl/bw-2-vs-mod.wsdl +449 -0
  64. onvif/wsdl/ver10/events/wsdl/event-vs.wsdl +947 -0
  65. onvif/wsdl/ver10/events/wsdl/event.wsdl +947 -0
  66. onvif/wsdl/ver10/events/wsdl/index.html +7 -0
  67. onvif/wsdl/ver10/federatedsearch.wsdl +344 -0
  68. onvif/wsdl/ver10/media/wsdl/media.wsdl +3684 -0
  69. onvif/wsdl/ver10/pacs/accesscontrol.wsdl +1942 -0
  70. onvif/wsdl/ver10/pacs/doorcontrol.wsdl +1792 -0
  71. onvif/wsdl/ver10/pacs/types.xsd +181 -0
  72. onvif/wsdl/ver10/provisioning/wsdl/provisioning.wsdl +588 -0
  73. onvif/wsdl/ver10/receiver.wsdl +398 -0
  74. onvif/wsdl/ver10/recording.wsdl +1231 -0
  75. onvif/wsdl/ver10/replay.wsdl +221 -0
  76. onvif/wsdl/ver10/schedule/wsdl/index.html +7 -0
  77. onvif/wsdl/ver10/schedule/wsdl/schedule.wsdl +1383 -0
  78. onvif/wsdl/ver10/schema/common.xsd +422 -0
  79. onvif/wsdl/ver10/schema/metadatastream.xsd +520 -0
  80. onvif/wsdl/ver10/schema/onvif.xsd +9251 -0
  81. onvif/wsdl/ver10/search.wsdl +882 -0
  82. onvif/wsdl/ver10/thermal/wsdl/index.html +7 -0
  83. onvif/wsdl/ver10/thermal/wsdl/thermal.wsdl +777 -0
  84. onvif/wsdl/ver10/topics/topicns.xml +13 -0
  85. onvif/wsdl/ver10/uplink/wsdl/index.html +7 -0
  86. onvif/wsdl/ver10/uplink/wsdl/uplink.wsdl +256 -0
  87. onvif/wsdl/ver20/analytics/humanbody.xsd +490 -0
  88. onvif/wsdl/ver20/analytics/humanface.xsd +501 -0
  89. onvif/wsdl/ver20/analytics/index.html +7 -0
  90. onvif/wsdl/ver20/analytics/radiometry.xsd +389 -0
  91. onvif/wsdl/ver20/analytics/rules.xsd +127 -0
  92. onvif/wsdl/ver20/analytics/wsdl/analytics.wsdl +757 -0
  93. onvif/wsdl/ver20/analytics/wsdl/index.html +7 -0
  94. onvif/wsdl/ver20/imaging/wsdl/imaging.wsdl +603 -0
  95. onvif/wsdl/ver20/media/wsdl/index.html +7 -0
  96. onvif/wsdl/ver20/media/wsdl/media.wsdl +2862 -0
  97. onvif/wsdl/ver20/ptz/wsdl/ptz.wsdl +1450 -0
  98. onvif/wsdl/ver20/util/federated_search_documentation.html +1647 -0
  99. onvif/wsdl/ver20/util/fedsearch-docu-viewer.xsl +8 -0
  100. onvif/wsdl/ver20/util/onvif-wsdl-viewer.xsl +2580 -0
  101. onvif/wsdl/ver20/util/operationIndex.html +97 -0
  102. onvif_python-0.0.1.dist-info/METADATA +381 -0
  103. onvif_python-0.0.1.dist-info/RECORD +106 -0
  104. onvif_python-0.0.1.dist-info/WHEEL +5 -0
  105. onvif_python-0.0.1.dist-info/licenses/LICENSE.md +21 -0
  106. onvif_python-0.0.1.dist-info/top_level.txt +1 -0
@@ -0,0 +1,159 @@
1
+ # onvif/services/credential.py
2
+
3
+ from ..operator import ONVIFOperator
4
+ from ..utils import ONVIFWSDL
5
+
6
+
7
+ class Credential:
8
+ def __init__(self, xaddr=None, **kwargs):
9
+ definition = ONVIFWSDL.get_definition("credential")
10
+ self.operator = ONVIFOperator(
11
+ definition["path"],
12
+ binding=f"{{{definition['namespace']}}}{definition['binding']}",
13
+ service_path="Credential", # fallback
14
+ xaddr=xaddr,
15
+ **kwargs,
16
+ )
17
+
18
+ def GetServiceCapabilities(self):
19
+ return self.operator.call("GetServiceCapabilities")
20
+
21
+ def GetSupportedFormatTypes(self, CredentialIdentifierTypeName):
22
+ return self.operator.call(
23
+ "GetSupportedFormatTypes",
24
+ CredentialIdentifierTypeName=CredentialIdentifierTypeName,
25
+ )
26
+
27
+ def GetCredentialInfo(self, Token):
28
+ return self.operator.call("GetCredentialInfo", Token=Token)
29
+
30
+ def GetCredentialInfoList(self, Limit=None, StartReference=None):
31
+ return self.operator.call(
32
+ "GetCredentialInfoList", Limit=Limit, StartReference=StartReference
33
+ )
34
+
35
+ def GetCredentials(self, Token):
36
+ return self.operator.call("GetCredentials", Token=Token)
37
+
38
+ def GetCredentialList(self, Limit=None, StartReference=None):
39
+ return self.operator.call(
40
+ "GetCredentialList", Limit=Limit, StartReference=StartReference
41
+ )
42
+
43
+ def CreateCredential(self, Credential, State):
44
+ return self.operator.call(
45
+ "CreateCredential", Credential=Credential, State=State
46
+ )
47
+
48
+ def SetCredential(self, CredentialData):
49
+ return self.operator.call("SetCredential", CredentialData=CredentialData)
50
+
51
+ def ModifyCredential(self, Credential):
52
+ return self.operator.call("ModifyCredential", Credential=Credential)
53
+
54
+ def DeleteCredential(self, Token):
55
+ return self.operator.call("DeleteCredential", Token=Token)
56
+
57
+ def GetCredentialState(self, Token):
58
+ return self.operator.call("GetCredentialState", Token=Token)
59
+
60
+ def EnableCredential(self, Token, Reason=None):
61
+ return self.operator.call("EnableCredential", Token=Token, Reason=Reason)
62
+
63
+ def DisableCredential(self, Token, Reason=None):
64
+ return self.operator.call("DisableCredential", Token=Token, Reason=Reason)
65
+
66
+ def ResetAntipassbackViolation(self, CredentialToken):
67
+ return self.operator.call(
68
+ "ResetAntipassbackViolation", CredentialToken=CredentialToken
69
+ )
70
+
71
+ def GetCredentialIdentifiers(self, CredentialToken):
72
+ return self.operator.call(
73
+ "GetCredentialIdentifiers", CredentialToken=CredentialToken
74
+ )
75
+
76
+ def SetCredentialIdentifier(self, CredentialToken, CredentialIdentifier):
77
+ return self.operator.call(
78
+ "SetCredentialIdentifier",
79
+ CredentialToken=CredentialToken,
80
+ CredentialIdentifier=CredentialIdentifier,
81
+ )
82
+
83
+ def DeleteCredentialIdentifier(self, CredentialToken, CredentialIdentifierTypeName):
84
+ return self.operator.call(
85
+ "DeleteCredentialIdentifier",
86
+ CredentialToken=CredentialToken,
87
+ CredentialIdentifierTypeName=CredentialIdentifierTypeName,
88
+ )
89
+
90
+ def GetCredentialAccessProfiles(self, CredentialToken):
91
+ return self.operator.call(
92
+ "GetCredentialAccessProfiles", CredentialToken=CredentialToken
93
+ )
94
+
95
+ def SetCredentialAccessProfiles(self, CredentialToken, CredentialAccessProfile):
96
+ return self.operator.call(
97
+ "SetCredentialAccessProfiles",
98
+ CredentialToken=CredentialToken,
99
+ CredentialAccessProfile=CredentialAccessProfile,
100
+ )
101
+
102
+ def DeleteCredentialAccessProfiles(self, CredentialToken, AccessProfileToken):
103
+ return self.operator.call(
104
+ "DeleteCredentialAccessProfiles",
105
+ CredentialToken=CredentialToken,
106
+ AccessProfileToken=AccessProfileToken,
107
+ )
108
+
109
+ def GetWhitelist(
110
+ self,
111
+ Limit=None,
112
+ StartReference=None,
113
+ IdentifierType=None,
114
+ FormatType=None,
115
+ Value=None,
116
+ ):
117
+ return self.operator.call(
118
+ "GetWhitelist",
119
+ Limit=Limit,
120
+ StartReference=StartReference,
121
+ IdentifierType=IdentifierType,
122
+ FormatType=FormatType,
123
+ Value=Value,
124
+ )
125
+
126
+ def AddToWhitelist(self, Identifier):
127
+ return self.operator.call("AddToWhitelist", Identifier=Identifier)
128
+
129
+ def RemoveFromWhitelist(self, Identifier):
130
+ return self.operator.call("RemoveFromWhitelist", Identifier=Identifier)
131
+
132
+ def DeleteWhitelist(self):
133
+ return self.operator.call("DeleteWhitelist")
134
+
135
+ def GetBlacklist(
136
+ self,
137
+ Limit=None,
138
+ StartReference=None,
139
+ IdentifierType=None,
140
+ FormatType=None,
141
+ Value=None,
142
+ ):
143
+ return self.operator.call(
144
+ "GetBlacklist",
145
+ Limit=Limit,
146
+ StartReference=StartReference,
147
+ IdentifierType=IdentifierType,
148
+ FormatType=FormatType,
149
+ Value=Value,
150
+ )
151
+
152
+ def AddToBlacklist(self, Identifier):
153
+ return self.operator.call("AddToBlacklist", Identifier=Identifier)
154
+
155
+ def RemoveFromBlacklist(self, Identifier):
156
+ return self.operator.call("RemoveFromBlacklist", Identifier=Identifier)
157
+
158
+ def DeleteBlacklist(self):
159
+ return self.operator.call("DeleteBlacklist")
@@ -0,0 +1,165 @@
1
+ # onvif/services/deviceio.py
2
+
3
+ from ..operator import ONVIFOperator
4
+ from ..utils import ONVIFWSDL
5
+
6
+
7
+ class DeviceIO:
8
+ def __init__(self, xaddr=None, **kwargs):
9
+ definition = ONVIFWSDL.get_definition("deviceio")
10
+ self.operator = ONVIFOperator(
11
+ definition["path"],
12
+ binding=f"{{{definition['namespace']}}}{definition['binding']}",
13
+ service_path="DeviceIO", # fallback
14
+ xaddr=xaddr,
15
+ **kwargs,
16
+ )
17
+
18
+ def GetServiceCapabilities(self):
19
+ return self.operator.call("GetServiceCapabilities")
20
+
21
+ def GetRelayOutputOptions(self, RelayOutputToken=None):
22
+ return self.operator.call(
23
+ "GetRelayOutputOptions", RelayOutputToken=RelayOutputToken
24
+ )
25
+
26
+ def GetAudioSources(self):
27
+ return self.operator.call("GetAudioSources")
28
+
29
+ def GetAudioOutputs(self):
30
+ return self.operator.call("GetAudioOutputs")
31
+
32
+ def GetVideoSources(self):
33
+ return self.operator.call("GetVideoSources")
34
+
35
+ def GetVideoOutputs(self):
36
+ return self.operator.call("GetVideoOutputs")
37
+
38
+ def GetVideoSourceConfiguration(self, VideoSourceToken):
39
+ return self.operator.call(
40
+ "GetVideoSourceConfiguration", VideoSourceToken=VideoSourceToken
41
+ )
42
+
43
+ def GetVideoOutputConfiguration(self, VideoOutputToken):
44
+ return self.operator.call(
45
+ "GetVideoOutputConfiguration", VideoOutputToken=VideoOutputToken
46
+ )
47
+
48
+ def GetAudioSourceConfiguration(self, AudioSourceToken):
49
+ return self.operator.call(
50
+ "GetAudioSourceConfiguration", AudioSourceToken=AudioSourceToken
51
+ )
52
+
53
+ def GetAudioOutputConfiguration(self, AudioOutputToken):
54
+ return self.operator.call(
55
+ "GetAudioOutputConfiguration", AudioOutputToken=AudioOutputToken
56
+ )
57
+
58
+ def SetVideoSourceConfiguration(self, Configuration, ForcePersistence):
59
+ return self.operator.call(
60
+ "SetVideoSourceConfiguration",
61
+ Configuration=Configuration,
62
+ ForcePersistence=ForcePersistence,
63
+ )
64
+
65
+ def SetVideoOutputConfiguration(self, Configuration, ForcePersistence):
66
+ return self.operator.call(
67
+ "SetVideoOutputConfiguration",
68
+ Configuration=Configuration,
69
+ ForcePersistence=ForcePersistence,
70
+ )
71
+
72
+ def SetAudioSourceConfiguration(self, Configuration, ForcePersistence):
73
+ return self.operator.call(
74
+ "SetAudioSourceConfiguration",
75
+ Configuration=Configuration,
76
+ ForcePersistence=ForcePersistence,
77
+ )
78
+
79
+ def SetAudioOutputConfiguration(self, Configuration, ForcePersistence):
80
+ return self.operator.call(
81
+ "SetAudioOutputConfiguration",
82
+ Configuration=Configuration,
83
+ ForcePersistence=ForcePersistence,
84
+ )
85
+
86
+ def GetVideoSourceConfigurationOptions(self, VideoSourceToken):
87
+ return self.operator.call(
88
+ "GetVideoSourceConfigurationOptions", VideoSourceToken=VideoSourceToken
89
+ )
90
+
91
+ def GetVideoOutputConfigurationOptions(self, VideoOutputToken):
92
+ return self.operator.call(
93
+ "GetVideoOutputConfigurationOptions", VideoOutputToken=VideoOutputToken
94
+ )
95
+
96
+ def GetAudioSourceConfigurationOptions(self, AudioSourceToken):
97
+ return self.operator.call(
98
+ "GetAudioSourceConfigurationOptions", AudioSourceToken=AudioSourceToken
99
+ )
100
+
101
+ def GetAudioOutputConfigurationOptions(self, AudioOutputToken):
102
+ return self.operator.call(
103
+ "GetAudioOutputConfigurationOptions", AudioOutputToken=AudioOutputToken
104
+ )
105
+
106
+ def GetRelayOutputs(self):
107
+ return self.operator.call("GetRelayOutputs")
108
+
109
+ def SetRelayOutputSettings(self, RelayOutput, RelayOutputToken, Properties):
110
+ return self.operator.call(
111
+ "SetRelayOutputSettings",
112
+ RelayOutput=RelayOutput,
113
+ RelayOutputToken=RelayOutputToken,
114
+ Properties=Properties,
115
+ )
116
+
117
+ def SetRelayOutputState(self, RelayOutputToken, LogicalState):
118
+ return self.operator.call(
119
+ "SetRelayOutputState",
120
+ RelayOutputToken=RelayOutputToken,
121
+ LogicalState=LogicalState,
122
+ )
123
+
124
+ def GetDigitalInputs(self):
125
+ return self.operator.call("GetDigitalInputs")
126
+
127
+ def GetDigitalInputConfigurationOptions(self, Token=None):
128
+ return self.operator.call("GetDigitalInputConfigurationOptions", Token=Token)
129
+
130
+ def SetDigitalInputConfigurations(self, DigitalInputs):
131
+ return self.operator.call(
132
+ "SetDigitalInputConfigurations", DigitalInputs=DigitalInputs
133
+ )
134
+
135
+ def GetSerialPorts(self):
136
+ return self.operator.call("GetSerialPorts")
137
+
138
+ def GetSerialPortConfiguration(self, SerialPortToken):
139
+ return self.operator.call(
140
+ "GetSerialPortConfiguration", SerialPortToken=SerialPortToken
141
+ )
142
+
143
+ def SetSerialPortConfiguration(self, SerialPortConfiguration, ForcePersistence):
144
+ return self.operator.call(
145
+ "SetSerialPortConfiguration",
146
+ SerialPortConfiguration=SerialPortConfiguration,
147
+ ForcePersistence=ForcePersistence,
148
+ )
149
+
150
+ def GetSerialPortConfigurationOptions(self, SerialPortToken):
151
+ return self.operator.call(
152
+ "GetSerialPortConfigurationOptions", SerialPortToken=SerialPortToken
153
+ )
154
+
155
+ def SendReceiveSerialCommand(
156
+ self, Token=None, SerialData=None, TimeOut=None, DataLength=None, Delimiter=None
157
+ ):
158
+ return self.operator.call(
159
+ "SendReceiveSerialCommand",
160
+ Token=Token,
161
+ SerialData=SerialData,
162
+ TimeOut=TimeOut,
163
+ DataLength=DataLength,
164
+ Delimiter=Delimiter,
165
+ )