(event, context)
| 68 | # Lambda handler |
| 69 | # ------------------------------------------------------ |
| 70 | def lambda_handler(event, context): |
| 71 | # Initialize Keeper Commander params |
| 72 | params = get_params() |
| 73 | |
| 74 | # Keeper login and sync |
| 75 | api.login(params) |
| 76 | api.sync_down(params) |
| 77 | # Enterprise sync (for enterprise commands) |
| 78 | api.query_enterprise(params) |
| 79 | |
| 80 | run_keeper_cli( |
| 81 | params, |
| 82 | 'device-approve -a' |
| 83 | ) |
| 84 | |
| 85 | run_keeper_cli( |
| 86 | params, |
| 87 | 'action-report --target locked --apply-action delete --dry-run' |
| 88 | ) |
| 89 | |
| 90 | return get_keeper_report( |
| 91 | params, |
| 92 | { |
| 93 | 'report_type':'raw', |
| 94 | 'format':'json', |
| 95 | 'limit':100, |
| 96 | 'event_type':['login'] |
| 97 | } |
| 98 | ) |
nothing calls this directly
no test coverage detected