Update Company Settings
Changes company settings, as the SalaryBox app’s Settings screen does. Send only the settings you want to change; anything left out stays as it is. Shared rules: see Writing data.
- The body is closed: an unknown field is refused with
400"Unknown field."Counts toward your write budget. - At least one setting is required: otherwise
400"Send at least one field to change." block_fake_gps_attendance,device_verification,ai_face_recognition,auto_live_track,include_week_offs,include_holidays,auto_calculate_tds,round_off_total_salaryandcustom_permissionsaretrueorfalse.ai_face_recognition: turning it on also turns on selfie attendance for every staff member, and matches faces only for staff whose face is enrolled. Faces are enrolled in the SalaryBox Android app; staff not yet enrolled punch with a selfie and no match until they are. Turning it off turns face matching off for everyone.salary_calculation_daysiscalendar_month,30_day_monthor26_day_month. See Fetch Company Settings for what each means.include_week_offsandinclude_holidayscan befalseonly whensalary_calculation_daysiscalendar_month(already, or in the same request); otherwise400. Switching to30_day_monthor26_day_monthsets both back totrue, as in the app.- Changing
include_week_offsorinclude_holidaysneeds Payroll on your plan: otherwise403"Payroll is not included in your plan. Contact us."Sending one at its current value is always accepted. - A setting sent at its current value is ignored. Only the settings that change are saved and trigger their effects:
salary_calculation_days,include_week_offsandinclude_holidayschange how payroll is worked out for all staff, and changingdevice_verificationorai_face_recognitionapplies to every staff member. If nothing changes, the current settings are returned with200. - A setting your plan does not include is refused with
403and nothing is saved. custom_permissionscan’t be turned off while staff have the Custom role:400, and nothing is saved. Move those staff to another role first.
Authentication
Format: “Api-Key {api-key}”
Request
Block Fake GPS Attendance: punches from a phone using a fake GPS app are refused.
Device Verification: staff can punch only from an approved device. A new device needs approval (see Approve or Reject Device Request).
AI Face Recognition: a staff member’s punch photo is matched against their enrolled face. Turning it on also turns on selfie attendance for every staff member, and face matching applies only to staff whose face is enrolled (enrolment is done in the SalaryBox Android app). Needs AI Face Recognition on your plan.
Auto Live Track: staff’s live location is tracked automatically during working hours.
How many days a month’s salary is spread over, which sets the per-day salary used for absences, fines and overtime. calendar_month: the days in that month (January 31, February 28). 30_day_month: always 30. 26_day_month: always 26.
Include Weekoffs: week offs count as paid days of the calendar month. Off, they are taken out of the month’s days, so a 31-day month with 4 week offs counts as 27 days. Can be false only with salary_calculation_days calendar_month.
Include Holidays: holidays count as paid days of the calendar month. Off, they are taken out of the month’s days, so a 31-day month with 1 holiday counts as 30 days. Can be false only with salary_calculation_days calendar_month.
Auto-Calculate TDS: payroll works out and deducts TDS for staff.
Round Off Total Salary: each staff member’s total salary is rounded to the nearest rupee. Needs Payroll on your plan.
Enable Custom Role: staff can be given the Custom role, with permissions set person by person.
Response
The settings were updated. data has every setting after the change.
