This question has been flagged
i can send attendance record using xmlrpc, using this below code:
import xmlrpclib
username = 'admin'
pwd = 'admin'
dbname = 'database-name' sock_common = xmlrpclib.ServerProxy ('http://server-url:port/xmlrpc/common') 
uid = sock_common.login(dbname, username, pwd) sock = xmlrpclib.ServerProxy('http://server-url:port/xmlrpc/object')
emp_id = sock.execute(dbname, uid, pwd, 'hr.employee', 'search', [('barcode','=', '8902579100025')])
attn_record = {'employee_id': emp_id, 'check_in': '11/10/2020 12:12:12'}
result = sock.execute(dbname, uid, pwd, 'hr.attendane', 'create', attn_record)
But i want to use kiosk mode entry, from looking at http request [browser kiosk mode] i can see that the barcode is being send to server using json script. like below.
{"jsonrpc":"2.0","method":"call","params":{"args":["8902579100025"],"model":"hr.employee","method":"attendance_scan","kwargs":{"context":{"lang":"en_GB","tz":"Asia/Kolkata","uid":2,"allowed_company_ids":[1]}}},"id":635426473}
now how can i send barcode data like this using xmlrpc. please guide me. my ultimate goal to create arduino or raspberry kiosk. 

Avatar
Discard