Api doc


SDK's


Api Modules

payroll.ratecard

Returns a payroll rate card.



Supported Methods:

GET
Params
  • token (Required): valid token
  • id (Required): integer


CREATE
Params
  • token (Required): valid token
  • name (Required): varchar
  • stack_overtime: enum (0, 1)


DELETE
Params
  • token (Required): valid token
  • id (Required): integer
  • def: enum (0, 1)


UPDATE
Params
  • token (Required): valid token
  • id (Required): integer
  • name: varchar
  • pay_code: varchar
  • def: enum (0, 1)
  • rates: varchar
  • overtime: varchar
  • day_limit: enum (CREATE, UPDATE, DELETE)
  • day_limit_id: integer
  • day_limit_minimum: integer
  • day_limit_rate: integer
  • stack_overtime: enum (0, 1)
  • override_payroll: enum (0, 1)


Documentation

GET
Retrieves a payroll rate card by id.
Level 5 is required (all users can fetch this module)

--

Parameters:

  1. "id": required //Ratecard id (integer)
  2. "token": "xxxxxxx" //Valid token is required

Example Request:

  1. {
  2. "method":"GET",
  3. "module":"payroll.ratecard",
  4. "request":{
  5. "id":"198"
  6. }
  7. }

Example Response:

  1. {
  2. "status":1,
  3. "data":{
  4. "id":"120",
  5. "name":"Wakatta 2",
  6. "overtime":"100",
  7. "created":"1339517515",
  8. "def":"0",
  9. "stack_overtime":"0",
  10. "rates":{
  11. "1":{
  12. "name":"Sun",
  13. "24":"100.00",
  14. "23":"100.00",
  15. "22":"100.00",
  16. "21":"100.00",
  17. "20":"100.00",
  18. "19":"100.00",
  19. "18":"100.00",
  20. "17":"100.00",
  21. "16":"100.00",
  22. "15":"100.00",
  23. "14":"100.00",
  24. "13":"100.00",
  25. "12":"100.00",
  26. "11":"100.00",
  27. "10":"100.00",
  28. "9":"100.00",
  29. "1":"100",
  30. "2":"100",
  31. "3":"100",
  32. "4":"100",
  33. "5":"100",
  34. "6":"100",
  35. "7":"100",
  36. "8":"100"
  37. },
  38. "2":{
  39. "name":"Mon",
  40. "1":"100",
  41. "2":"100",
  42. "3":"100",
  43. "4":"100",
  44. "5":"100",
  45. "6":"100",
  46. "7":"100",
  47. "8":"100",
  48. "9":"100",
  49. "10":"100",
  50. "11":"100",
  51. "12":"100",
  52. "13":"100",
  53. "14":"100",
  54. "15":"100",
  55. "16":"100",
  56. "17":"100",
  57. "18":"100",
  58. "19":"100",
  59. "20":"100",
  60. "21":"100",
  61. "22":"100",
  62. "23":"100",
  63. "24":"100"
  64. },
  65. "3":{
  66. "name":"Tue",
  67. "1":"100",
  68. "2":"100",
  69. "3":"100",
  70. "4":"100",
  71. "5":"100",
  72. "6":"100",
  73. "7":"100",
  74. "8":"100",
  75. "9":"100",
  76. "10":"100",
  77. "11":"100",
  78. "12":"100",
  79. "13":"100",
  80. "14":"100",
  81. "15":"100",
  82. "16":"100",
  83. "17":"100",
  84. "18":"100",
  85. "19":"100",
  86. "20":"100",
  87. "21":"100",
  88. "22":"100",
  89. "23":"100",
  90. "24":"100"
  91. },
  92. "4":{
  93. "name":"Wed",
  94. "1":"100",
  95. "2":"100",
  96. "3":"100",
  97. "4":"100",
  98. "5":"100",
  99. "6":"100",
  100. "7":"100",
  101. "8":"100",
  102. "9":"100",
  103. "10":"100",
  104. "11":"100",
  105. "12":"100",
  106. "13":"100",
  107. "14":"100",
  108. "15":"100",
  109. "16":"100",
  110. "17":"100",
  111. "18":"100",
  112. "19":"100",
  113. "20":"100",
  114. "21":"100",
  115. "22":"100",
  116. "23":"100",
  117. "24":"100"
  118. },
  119. "5":{
  120. "name":"Thu",
  121. "1":"100",
  122. "2":"100",
  123. "3":"100",
  124. "4":"100",
  125. "5":"100",
  126. "6":"100",
  127. "7":"100",
  128. "8":"100",
  129. "9":"100",
  130. "10":"100",
  131. "11":"100",
  132. "12":"100",
  133. "13":"100",
  134. "14":"100",
  135. "15":"100",
  136. "16":"100",
  137. "17":"100",
  138. "18":"100",
  139. "19":"100",
  140. "20":"100",
  141. "21":"100",
  142. "22":"100",
  143. "23":"100",
  144. "24":"100"
  145. },
  146. "6":{
  147. "name":"Fri",
  148. "1":"100",
  149. "2":"100",
  150. "3":"100",
  151. "4":"100",
  152. "5":"100",
  153. "6":"100",
  154. "7":"100",
  155. "8":"100",
  156. "9":"100",
  157. "10":"100",
  158. "11":"100",
  159. "12":"100",
  160. "13":"100",
  161. "14":"100",
  162. "15":"100",
  163. "16":"100",
  164. "17":"100",
  165. "18":"100",
  166. "19":"100",
  167. "20":"100",
  168. "21":"100",
  169. "22":"100",
  170. "23":"100",
  171. "24":"100"
  172. },
  173. "7":{
  174. "name":"Sat",
  175. "9":"200.00",
  176. "10":"200.00",
  177. "11":"200.00",
  178. "12":"200.00",
  179. "13":"200.00",
  180. "14":"200.00",
  181. "15":"200.00",
  182. "16":"200.00",
  183. "17":"200.00",
  184. "18":"200.00",
  185. "19":"200.00",
  186. "20":"200.00",
  187. "21":"200.00",
  188. "22":"200.00",
  189. "23":"200.00",
  190. "24":"200.00",
  191. "8":"200.00",
  192. "1":"100.00",
  193. "2":"100.00",
  194. "3":"100.00",
  195. "4":"100.00",
  196. "5":"100.00",
  197. "6":"100.00",
  198. "7":"100.00"
  199. }
  200. },
  201. "day_overtime":[
  202.  
  203. ]
  204. },
  205. "token":"xxxxxxx"
  206. }

---

CREATE
Creates a payroll rate card.
Level 3 is required.

--

Parameters:

  1. "name": required //Name (integer)
  2. "stack_overtime" required //Stack overtime (enum[0,1])
  3. /* 0: Do not stack overtime
  4.   * 1: Stack overtime */
  5. "token": "xxxxxxx" //Valid token is required

Example Request:

  1. {
  2. "module":"payroll.ratecard",
  3. "method":"CREATE",
  4. "request":{
  5. "name":"NewRateCard"
  6. }
  7. }

Example Response:

  1. {
  2. "status":1,
  3. "data":{
  4. "id":"121",
  5. "name":"NewRateCard",
  6. "overtime":"100",
  7. "created":"1339517515",
  8. "def":"0",
  9. "stack_overtime":"0",
  10. "rates":{
  11. "1":{
  12. "name":"Sun",
  13. "24":"100.00",
  14. "23":"100.00",
  15. "22":"100.00",
  16. "21":"100.00",
  17. "20":"100.00",
  18. "19":"100.00",
  19. "18":"100.00",
  20. "17":"100.00",
  21. "16":"100.00",
  22. "15":"100.00",
  23. "14":"100.00",
  24. "13":"100.00",
  25. "12":"100.00",
  26. "11":"100.00",
  27. "10":"100.00",
  28. "9":"100.00",
  29. "1":"100",
  30. "2":"100",
  31. "3":"100",
  32. "4":"100",
  33. "5":"100",
  34. "6":"100",
  35. "7":"100",
  36. "8":"100"
  37. },
  38. "2":{
  39. "name":"Mon",
  40. "1":"100",
  41. "2":"100",
  42. "3":"100",
  43. "4":"100",
  44. "5":"100",
  45. "6":"100",
  46. "7":"100",
  47. "8":"100",
  48. "9":"100",
  49. "10":"100",
  50. "11":"100",
  51. "12":"100",
  52. "13":"100",
  53. "14":"100",
  54. "15":"100",
  55. "16":"100",
  56. "17":"100",
  57. "18":"100",
  58. "19":"100",
  59. "20":"100",
  60. "21":"100",
  61. "22":"100",
  62. "23":"100",
  63. "24":"100"
  64. },
  65. "3":{
  66. "name":"Tue",
  67. "1":"100",
  68. "2":"100",
  69. "3":"100",
  70. "4":"100",
  71. "5":"100",
  72. "6":"100",
  73. "7":"100",
  74. "8":"100",
  75. "9":"100",
  76. "10":"100",
  77. "11":"100",
  78. "12":"100",
  79. "13":"100",
  80. "14":"100",
  81. "15":"100",
  82. "16":"100",
  83. "17":"100",
  84. "18":"100",
  85. "19":"100",
  86. "20":"100",
  87. "21":"100",
  88. "22":"100",
  89. "23":"100",
  90. "24":"100"
  91. },
  92. "4":{
  93. "name":"Wed",
  94. "1":"100",
  95. "2":"100",
  96. "3":"100",
  97. "4":"100",
  98. "5":"100",
  99. "6":"100",
  100. "7":"100",
  101. "8":"100",
  102. "9":"100",
  103. "10":"100",
  104. "11":"100",
  105. "12":"100",
  106. "13":"100",
  107. "14":"100",
  108. "15":"100",
  109. "16":"100",
  110. "17":"100",
  111. "18":"100",
  112. "19":"100",
  113. "20":"100",
  114. "21":"100",
  115. "22":"100",
  116. "23":"100",
  117. "24":"100"
  118. },
  119. "5":{
  120. "name":"Thu",
  121. "1":"100",
  122. "2":"100",
  123. "3":"100",
  124. "4":"100",
  125. "5":"100",
  126. "6":"100",
  127. "7":"100",
  128. "8":"100",
  129. "9":"100",
  130. "10":"100",
  131. "11":"100",
  132. "12":"100",
  133. "13":"100",
  134. "14":"100",
  135. "15":"100",
  136. "16":"100",
  137. "17":"100",
  138. "18":"100",
  139. "19":"100",
  140. "20":"100",
  141. "21":"100",
  142. "22":"100",
  143. "23":"100",
  144. "24":"100"
  145. },
  146. "6":{
  147. "name":"Fri",
  148. "1":"100",
  149. "2":"100",
  150. "3":"100",
  151. "4":"100",
  152. "5":"100",
  153. "6":"100",
  154. "7":"100",
  155. "8":"100",
  156. "9":"100",
  157. "10":"100",
  158. "11":"100",
  159. "12":"100",
  160. "13":"100",
  161. "14":"100",
  162. "15":"100",
  163. "16":"100",
  164. "17":"100",
  165. "18":"100",
  166. "19":"100",
  167. "20":"100",
  168. "21":"100",
  169. "22":"100",
  170. "23":"100",
  171. "24":"100"
  172. },
  173. "7":{
  174. "name":"Sat",
  175. "9":"200.00",
  176. "10":"200.00",
  177. "11":"200.00",
  178. "12":"200.00",
  179. "13":"200.00",
  180. "14":"200.00",
  181. "15":"200.00",
  182. "16":"200.00",
  183. "17":"200.00",
  184. "18":"200.00",
  185. "19":"200.00",
  186. "20":"200.00",
  187. "21":"200.00",
  188. "22":"200.00",
  189. "23":"200.00",
  190. "24":"200.00",
  191. "8":"200.00",
  192. "1":"100.00",
  193. "2":"100.00",
  194. "3":"100.00",
  195. "4":"100.00",
  196. "5":"100.00",
  197. "6":"100.00",
  198. "7":"100.00"
  199. }
  200. },
  201. "day_overtime":[
  202.  
  203. ]
  204. },
  205. "token":"xxxxxxx"
  206. }

---

UPDATE
Updates a payroll rate card.
Level 3 is required.

--

Parameters:

  1. "id": required //Retecard id (integer)
  2. "name": accepted //Name (varchar)
  3. "def": accepted //Default (enum[0,1])
  4. /* 0: Not default rate card
  5.   * 1: Default rate card */
  6. "rates": accepted //Update rates (varchar)
  7. "overtime": accepted //Overtime (integer)
  8. "day_limit": accepted //Day limit (enum[CREATE,UPDATE,DELETE)
  9. /* CREATE: Create day limit
  10.   * UPDATE: Update day limit
  11.   * DELETE: Delete day limit */
  12. "day_limit_id": accepted //Day limit id (integer)
  13. "day_limit_minimum": accepted //Day limit minimum (integer)
  14. "day_limit_rate": accepted //Day limit rate (integer)
  15. "stack_overtime": accepted //Stack overtime (enum[0,1])
  16. /* 0: Do not stack overtime
  17.   * 1: Stack overtime */
  18. "token": "xxxxxxx" //Valid token is required

Example Request:

  1. {
  2. "module":"payroll.ratecard",
  3. "method":"UPDATE",
  4. "request":{
  5. "id":"121",
  6. "name":"Updated"
  7. }
  8. }

Example Response:

  1. {
  2. "status":1,
  3. "data":{
  4. "id":"121",
  5. "name":"Updated",
  6. "overtime":"100",
  7. "created":"1339517515",
  8. "def":"0",
  9. "stack_overtime":"0",
  10. "rates":{
  11. "1":{
  12. "name":"Sun",
  13. "24":"100.00",
  14. "23":"100.00",
  15. "22":"100.00",
  16. "21":"100.00",
  17. "20":"100.00",
  18. "19":"100.00",
  19. "18":"100.00",
  20. "17":"100.00",
  21. "16":"100.00",
  22. "15":"100.00",
  23. "14":"100.00",
  24. "13":"100.00",
  25. "12":"100.00",
  26. "11":"100.00",
  27. "10":"100.00",
  28. "9":"100.00",
  29. "1":"100",
  30. "2":"100",
  31. "3":"100",
  32. "4":"100",
  33. "5":"100",
  34. "6":"100",
  35. "7":"100",
  36. "8":"100"
  37. },
  38. "2":{
  39. "name":"Mon",
  40. "1":"100",
  41. "2":"100",
  42. "3":"100",
  43. "4":"100",
  44. "5":"100",
  45. "6":"100",
  46. "7":"100",
  47. "8":"100",
  48. "9":"100",
  49. "10":"100",
  50. "11":"100",
  51. "12":"100",
  52. "13":"100",
  53. "14":"100",
  54. "15":"100",
  55. "16":"100",
  56. "17":"100",
  57. "18":"100",
  58. "19":"100",
  59. "20":"100",
  60. "21":"100",
  61. "22":"100",
  62. "23":"100",
  63. "24":"100"
  64. },
  65. "3":{
  66. "name":"Tue",
  67. "1":"100",
  68. "2":"100",
  69. "3":"100",
  70. "4":"100",
  71. "5":"100",
  72. "6":"100",
  73. "7":"100",
  74. "8":"100",
  75. "9":"100",
  76. "10":"100",
  77. "11":"100",
  78. "12":"100",
  79. "13":"100",
  80. "14":"100",
  81. "15":"100",
  82. "16":"100",
  83. "17":"100",
  84. "18":"100",
  85. "19":"100",
  86. "20":"100",
  87. "21":"100",
  88. "22":"100",
  89. "23":"100",
  90. "24":"100"
  91. },
  92. "4":{
  93. "name":"Wed",
  94. "1":"100",
  95. "2":"100",
  96. "3":"100",
  97. "4":"100",
  98. "5":"100",
  99. "6":"100",
  100. "7":"100",
  101. "8":"100",
  102. "9":"100",
  103. "10":"100",
  104. "11":"100",
  105. "12":"100",
  106. "13":"100",
  107. "14":"100",
  108. "15":"100",
  109. "16":"100",
  110. "17":"100",
  111. "18":"100",
  112. "19":"100",
  113. "20":"100",
  114. "21":"100",
  115. "22":"100",
  116. "23":"100",
  117. "24":"100"
  118. },
  119. "5":{
  120. "name":"Thu",
  121. "1":"100",
  122. "2":"100",
  123. "3":"100",
  124. "4":"100",
  125. "5":"100",
  126. "6":"100",
  127. "7":"100",
  128. "8":"100",
  129. "9":"100",
  130. "10":"100",
  131. "11":"100",
  132. "12":"100",
  133. "13":"100",
  134. "14":"100",
  135. "15":"100",
  136. "16":"100",
  137. "17":"100",
  138. "18":"100",
  139. "19":"100",
  140. "20":"100",
  141. "21":"100",
  142. "22":"100",
  143. "23":"100",
  144. "24":"100"
  145. },
  146. "6":{
  147. "name":"Fri",
  148. "1":"100",
  149. "2":"100",
  150. "3":"100",
  151. "4":"100",
  152. "5":"100",
  153. "6":"100",
  154. "7":"100",
  155. "8":"100",
  156. "9":"100",
  157. "10":"100",
  158. "11":"100",
  159. "12":"100",
  160. "13":"100",
  161. "14":"100",
  162. "15":"100",
  163. "16":"100",
  164. "17":"100",
  165. "18":"100",
  166. "19":"100",
  167. "20":"100",
  168. "21":"100",
  169. "22":"100",
  170. "23":"100",
  171. "24":"100"
  172. },
  173. "7":{
  174. "name":"Sat",
  175. "9":"200.00",
  176. "10":"200.00",
  177. "11":"200.00",
  178. "12":"200.00",
  179. "13":"200.00",
  180. "14":"200.00",
  181. "15":"200.00",
  182. "16":"200.00",
  183. "17":"200.00",
  184. "18":"200.00",
  185. "19":"200.00",
  186. "20":"200.00",
  187. "21":"200.00",
  188. "22":"200.00",
  189. "23":"200.00",
  190. "24":"200.00",
  191. "8":"200.00",
  192. "1":"100.00",
  193. "2":"100.00",
  194. "3":"100.00",
  195. "4":"100.00",
  196. "5":"100.00",
  197. "6":"100.00",
  198. "7":"100.00"
  199. }
  200. },
  201. "day_overtime":[
  202.  
  203. ]
  204. },
  205. "token":"xxxxxxx"
  206. }

---

DELETE
Deletes a payroll rate card.
Level 3 is required.

--

Parameters:

  1. "id": required //Retecard id (integer)
  2. "def": accepted //Default (enum[0,1])
  3. /* 0: Not default rate card
  4.   * 1: Default rate card */
  5. "token": "xxxxxxx" //Valid token is required

Example Request:

  1. {
  2. "module":"payroll.ratecard",
  3. "method":"DELETE",
  4. "request":{
  5. "id":"201"
  6. }
  7. }

Example Response:

  1. {
  2. "status":1,
  3. "data":"",
  4. "token":"xxxxxxx"
  5. }