File tree 1 file changed +30
-1
lines changed
yoti_python_sdk/doc_scan/session/retrieve
1 file changed +30
-1
lines changed Original file line number Diff line number Diff line change 4
4
5
5
class FaceCaptureResponse (ResourceResponse ):
6
6
"""
7
- Represents a Face Capture resource for a given session
7
+ Represents a Face Capture resource for a given session.
8
8
"""
9
9
10
10
def __init__ (self , data = None ):
@@ -26,3 +26,32 @@ def image(self):
26
26
@property
27
27
def tasks (self ):
28
28
return self ._data .get ("tasks" ) or []
29
+
30
+
31
+ class FaceCaptureResource (object ):
32
+ """
33
+ Represents a Face Capture resource object.
34
+ """
35
+
36
+ def __init__ (self , session_id = None , payload = None ):
37
+ self .__session_id = session_id
38
+ self .__payload = payload
39
+
40
+ @property
41
+ def session_id (self ):
42
+ return self .__session_id
43
+
44
+ @property
45
+ def payload (self ):
46
+ return self .__payload
47
+
48
+ @classmethod
49
+ def build (cls , session_id , face_capture_response ):
50
+ return cls (
51
+ session_id = session_id ,
52
+ payload = {
53
+ "image" : face_capture_response .image ,
54
+ "tasks" : face_capture_response .tasks ,
55
+ "source" : face_capture_response .source ,
56
+ }
57
+ )
You can’t perform that action at this time.
0 commit comments