@samsarahq/samsara 7.0.0 → 7.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (200) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/betaApIs/client/Client.d.ts +31 -0
  3. package/dist/cjs/api/resources/betaApIs/client/Client.js +88 -0
  4. package/dist/cjs/api/resources/betaApIs/client/requests/ResolveAssignmentByDetailsResolveAssignmentByDetailsRequestBody.d.ts +13 -0
  5. package/dist/cjs/api/resources/betaApIs/client/requests/ResolveAssignmentByDetailsResolveAssignmentByDetailsRequestBody.js +3 -0
  6. package/dist/cjs/api/resources/betaApIs/client/requests/index.d.ts +1 -0
  7. package/dist/cjs/api/resources/media/client/Client.d.ts +1 -1
  8. package/dist/cjs/api/resources/media/client/Client.js +1 -1
  9. package/dist/cjs/api/resources/media/client/requests/MediaRetrievalPostMediaRetrievalRequestBody.d.ts +1 -1
  10. package/dist/cjs/api/resources/previewApIs/client/Client.d.ts +73 -0
  11. package/dist/cjs/api/resources/previewApIs/client/Client.js +191 -0
  12. package/dist/cjs/api/resources/previewApIs/client/requests/ListAssociationsRequest.d.ts +17 -0
  13. package/dist/cjs/api/resources/previewApIs/client/requests/ListAssociationsRequest.js +3 -0
  14. package/dist/cjs/api/resources/previewApIs/client/requests/SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.d.ts +31 -0
  15. package/dist/cjs/api/resources/previewApIs/client/requests/SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.js +17 -0
  16. package/dist/cjs/api/resources/previewApIs/client/requests/index.d.ts +2 -0
  17. package/dist/cjs/api/resources/previewApIs/client/requests/index.js +3 -0
  18. package/dist/cjs/api/types/AssociationResponseBody.d.ts +15 -0
  19. package/dist/cjs/api/types/AssociationResponseBody.js +3 -0
  20. package/dist/cjs/api/types/AssociationsListAssociationsBadGatewayErrorResponseBody.d.ts +9 -0
  21. package/dist/cjs/api/types/AssociationsListAssociationsBadGatewayErrorResponseBody.js +3 -0
  22. package/dist/cjs/api/types/AssociationsListAssociationsGatewayTimeoutErrorResponseBody.d.ts +9 -0
  23. package/dist/cjs/api/types/AssociationsListAssociationsGatewayTimeoutErrorResponseBody.js +3 -0
  24. package/dist/cjs/api/types/AssociationsListAssociationsInternalServerErrorResponseBody.d.ts +9 -0
  25. package/dist/cjs/api/types/AssociationsListAssociationsInternalServerErrorResponseBody.js +3 -0
  26. package/dist/cjs/api/types/AssociationsListAssociationsMethodNotAllowedErrorResponseBody.d.ts +9 -0
  27. package/dist/cjs/api/types/AssociationsListAssociationsMethodNotAllowedErrorResponseBody.js +3 -0
  28. package/dist/cjs/api/types/AssociationsListAssociationsNotFoundErrorResponseBody.d.ts +9 -0
  29. package/dist/cjs/api/types/AssociationsListAssociationsNotFoundErrorResponseBody.js +3 -0
  30. package/dist/cjs/api/types/AssociationsListAssociationsNotImplementedErrorResponseBody.d.ts +9 -0
  31. package/dist/cjs/api/types/AssociationsListAssociationsNotImplementedErrorResponseBody.js +3 -0
  32. package/dist/cjs/api/types/AssociationsListAssociationsResponseBody.d.ts +6 -0
  33. package/dist/cjs/api/types/AssociationsListAssociationsResponseBody.js +3 -0
  34. package/dist/cjs/api/types/AssociationsListAssociationsServiceUnavailableErrorResponseBody.d.ts +9 -0
  35. package/dist/cjs/api/types/AssociationsListAssociationsServiceUnavailableErrorResponseBody.js +3 -0
  36. package/dist/cjs/api/types/AssociationsListAssociationsTooManyRequestsErrorResponseBody.d.ts +9 -0
  37. package/dist/cjs/api/types/AssociationsListAssociationsTooManyRequestsErrorResponseBody.js +3 -0
  38. package/dist/cjs/api/types/AssociationsListAssociationsUnauthorizedErrorResponseBody.d.ts +9 -0
  39. package/dist/cjs/api/types/AssociationsListAssociationsUnauthorizedErrorResponseBody.js +3 -0
  40. package/dist/cjs/api/types/DefectTypesResponseDataResponseBody.d.ts +9 -0
  41. package/dist/cjs/api/types/DefectTypesResponseDataResponseBody.js +6 -0
  42. package/dist/cjs/api/types/DvirDefectsObjectV20220913ResponseBody.d.ts +13 -0
  43. package/dist/cjs/api/types/DvirDefectsObjectV20220913ResponseBody.js +10 -0
  44. package/dist/cjs/api/types/MissingStateResponseBody.d.ts +10 -2
  45. package/dist/cjs/api/types/MissingStateResponseBody.js +9 -0
  46. package/dist/cjs/api/types/PatchSafetyEventsDismissalReasonBodyRequestBody.d.ts +18 -0
  47. package/dist/cjs/api/types/PatchSafetyEventsDismissalReasonBodyRequestBody.js +13 -0
  48. package/dist/cjs/api/types/PatchSafetyEventsResponseItemDataResponseBody.d.ts +7 -0
  49. package/dist/cjs/api/types/PatchSafetyEventsResponseItemDataResponseBody.js +3 -0
  50. package/dist/cjs/api/types/PatchSafetyEventsResponseItemResponseBody.d.ts +9 -0
  51. package/dist/cjs/api/types/PatchSafetyEventsResponseItemResponseBody.js +3 -0
  52. package/dist/cjs/api/types/RecoveryStateResponseBody.d.ts +10 -2
  53. package/dist/cjs/api/types/RecoveryStateResponseBody.js +9 -0
  54. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsBadGatewayErrorResponseBody.d.ts +9 -0
  55. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsBadGatewayErrorResponseBody.js +3 -0
  56. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsGatewayTimeoutErrorResponseBody.d.ts +9 -0
  57. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsGatewayTimeoutErrorResponseBody.js +3 -0
  58. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsInternalServerErrorResponseBody.d.ts +9 -0
  59. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsInternalServerErrorResponseBody.js +3 -0
  60. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsMethodNotAllowedErrorResponseBody.d.ts +9 -0
  61. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsMethodNotAllowedErrorResponseBody.js +3 -0
  62. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotFoundErrorResponseBody.d.ts +9 -0
  63. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotFoundErrorResponseBody.js +3 -0
  64. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotImplementedErrorResponseBody.d.ts +9 -0
  65. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotImplementedErrorResponseBody.js +3 -0
  66. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsResponseBody.d.ts +4 -0
  67. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsResponseBody.js +3 -0
  68. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsServiceUnavailableErrorResponseBody.d.ts +9 -0
  69. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsServiceUnavailableErrorResponseBody.js +3 -0
  70. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsTooManyRequestsErrorResponseBody.d.ts +9 -0
  71. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsTooManyRequestsErrorResponseBody.js +3 -0
  72. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsUnauthorizedErrorResponseBody.d.ts +9 -0
  73. package/dist/cjs/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsUnauthorizedErrorResponseBody.js +3 -0
  74. package/dist/cjs/api/types/ResolveAssignmentByDetailsResponseBodyResponseBody.d.ts +9 -0
  75. package/dist/cjs/api/types/ResolveAssignmentByDetailsResponseBodyResponseBody.js +3 -0
  76. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchBadGatewayErrorResponseBody.d.ts +9 -0
  77. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchBadGatewayErrorResponseBody.js +3 -0
  78. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchGatewayTimeoutErrorResponseBody.d.ts +9 -0
  79. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchGatewayTimeoutErrorResponseBody.js +3 -0
  80. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchInternalServerErrorResponseBody.d.ts +9 -0
  81. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchInternalServerErrorResponseBody.js +3 -0
  82. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchMethodNotAllowedErrorResponseBody.d.ts +9 -0
  83. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchMethodNotAllowedErrorResponseBody.js +3 -0
  84. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotFoundErrorResponseBody.d.ts +9 -0
  85. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotFoundErrorResponseBody.js +3 -0
  86. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotImplementedErrorResponseBody.d.ts +9 -0
  87. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotImplementedErrorResponseBody.js +3 -0
  88. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchResponseBody.d.ts +7 -0
  89. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchResponseBody.js +3 -0
  90. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchServiceUnavailableErrorResponseBody.d.ts +9 -0
  91. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchServiceUnavailableErrorResponseBody.js +3 -0
  92. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchTooManyRequestsErrorResponseBody.d.ts +9 -0
  93. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchTooManyRequestsErrorResponseBody.js +3 -0
  94. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchUnauthorizedErrorResponseBody.d.ts +9 -0
  95. package/dist/cjs/api/types/SafetyEventsV2PatchSafetyEventsV2BatchUnauthorizedErrorResponseBody.js +3 -0
  96. package/dist/cjs/api/types/index.d.ts +35 -0
  97. package/dist/cjs/api/types/index.js +35 -0
  98. package/dist/cjs/version.d.ts +1 -1
  99. package/dist/cjs/version.js +1 -1
  100. package/dist/esm/BaseClient.mjs +2 -2
  101. package/dist/esm/api/resources/betaApIs/client/Client.d.mts +31 -0
  102. package/dist/esm/api/resources/betaApIs/client/Client.mjs +88 -0
  103. package/dist/esm/api/resources/betaApIs/client/requests/ResolveAssignmentByDetailsResolveAssignmentByDetailsRequestBody.d.mts +13 -0
  104. package/dist/esm/api/resources/betaApIs/client/requests/ResolveAssignmentByDetailsResolveAssignmentByDetailsRequestBody.mjs +2 -0
  105. package/dist/esm/api/resources/betaApIs/client/requests/index.d.mts +1 -0
  106. package/dist/esm/api/resources/media/client/Client.d.mts +1 -1
  107. package/dist/esm/api/resources/media/client/Client.mjs +1 -1
  108. package/dist/esm/api/resources/media/client/requests/MediaRetrievalPostMediaRetrievalRequestBody.d.mts +1 -1
  109. package/dist/esm/api/resources/previewApIs/client/Client.d.mts +73 -0
  110. package/dist/esm/api/resources/previewApIs/client/Client.mjs +191 -0
  111. package/dist/esm/api/resources/previewApIs/client/requests/ListAssociationsRequest.d.mts +17 -0
  112. package/dist/esm/api/resources/previewApIs/client/requests/ListAssociationsRequest.mjs +2 -0
  113. package/dist/esm/api/resources/previewApIs/client/requests/SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.d.mts +31 -0
  114. package/dist/esm/api/resources/previewApIs/client/requests/SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.mjs +14 -0
  115. package/dist/esm/api/resources/previewApIs/client/requests/index.d.mts +2 -0
  116. package/dist/esm/api/resources/previewApIs/client/requests/index.mjs +1 -1
  117. package/dist/esm/api/types/AssociationResponseBody.d.mts +15 -0
  118. package/dist/esm/api/types/AssociationResponseBody.mjs +2 -0
  119. package/dist/esm/api/types/AssociationsListAssociationsBadGatewayErrorResponseBody.d.mts +9 -0
  120. package/dist/esm/api/types/AssociationsListAssociationsBadGatewayErrorResponseBody.mjs +2 -0
  121. package/dist/esm/api/types/AssociationsListAssociationsGatewayTimeoutErrorResponseBody.d.mts +9 -0
  122. package/dist/esm/api/types/AssociationsListAssociationsGatewayTimeoutErrorResponseBody.mjs +2 -0
  123. package/dist/esm/api/types/AssociationsListAssociationsInternalServerErrorResponseBody.d.mts +9 -0
  124. package/dist/esm/api/types/AssociationsListAssociationsInternalServerErrorResponseBody.mjs +2 -0
  125. package/dist/esm/api/types/AssociationsListAssociationsMethodNotAllowedErrorResponseBody.d.mts +9 -0
  126. package/dist/esm/api/types/AssociationsListAssociationsMethodNotAllowedErrorResponseBody.mjs +2 -0
  127. package/dist/esm/api/types/AssociationsListAssociationsNotFoundErrorResponseBody.d.mts +9 -0
  128. package/dist/esm/api/types/AssociationsListAssociationsNotFoundErrorResponseBody.mjs +2 -0
  129. package/dist/esm/api/types/AssociationsListAssociationsNotImplementedErrorResponseBody.d.mts +9 -0
  130. package/dist/esm/api/types/AssociationsListAssociationsNotImplementedErrorResponseBody.mjs +2 -0
  131. package/dist/esm/api/types/AssociationsListAssociationsResponseBody.d.mts +6 -0
  132. package/dist/esm/api/types/AssociationsListAssociationsResponseBody.mjs +2 -0
  133. package/dist/esm/api/types/AssociationsListAssociationsServiceUnavailableErrorResponseBody.d.mts +9 -0
  134. package/dist/esm/api/types/AssociationsListAssociationsServiceUnavailableErrorResponseBody.mjs +2 -0
  135. package/dist/esm/api/types/AssociationsListAssociationsTooManyRequestsErrorResponseBody.d.mts +9 -0
  136. package/dist/esm/api/types/AssociationsListAssociationsTooManyRequestsErrorResponseBody.mjs +2 -0
  137. package/dist/esm/api/types/AssociationsListAssociationsUnauthorizedErrorResponseBody.d.mts +9 -0
  138. package/dist/esm/api/types/AssociationsListAssociationsUnauthorizedErrorResponseBody.mjs +2 -0
  139. package/dist/esm/api/types/DefectTypesResponseDataResponseBody.d.mts +9 -0
  140. package/dist/esm/api/types/DefectTypesResponseDataResponseBody.mjs +6 -0
  141. package/dist/esm/api/types/DvirDefectsObjectV20220913ResponseBody.d.mts +13 -0
  142. package/dist/esm/api/types/DvirDefectsObjectV20220913ResponseBody.mjs +9 -1
  143. package/dist/esm/api/types/MissingStateResponseBody.d.mts +10 -2
  144. package/dist/esm/api/types/MissingStateResponseBody.mjs +8 -1
  145. package/dist/esm/api/types/PatchSafetyEventsDismissalReasonBodyRequestBody.d.mts +18 -0
  146. package/dist/esm/api/types/PatchSafetyEventsDismissalReasonBodyRequestBody.mjs +10 -0
  147. package/dist/esm/api/types/PatchSafetyEventsResponseItemDataResponseBody.d.mts +7 -0
  148. package/dist/esm/api/types/PatchSafetyEventsResponseItemDataResponseBody.mjs +2 -0
  149. package/dist/esm/api/types/PatchSafetyEventsResponseItemResponseBody.d.mts +9 -0
  150. package/dist/esm/api/types/PatchSafetyEventsResponseItemResponseBody.mjs +2 -0
  151. package/dist/esm/api/types/RecoveryStateResponseBody.d.mts +10 -2
  152. package/dist/esm/api/types/RecoveryStateResponseBody.mjs +8 -1
  153. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsBadGatewayErrorResponseBody.d.mts +9 -0
  154. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsBadGatewayErrorResponseBody.mjs +2 -0
  155. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsGatewayTimeoutErrorResponseBody.d.mts +9 -0
  156. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsGatewayTimeoutErrorResponseBody.mjs +2 -0
  157. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsInternalServerErrorResponseBody.d.mts +9 -0
  158. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsInternalServerErrorResponseBody.mjs +2 -0
  159. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsMethodNotAllowedErrorResponseBody.d.mts +9 -0
  160. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsMethodNotAllowedErrorResponseBody.mjs +2 -0
  161. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotFoundErrorResponseBody.d.mts +9 -0
  162. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotFoundErrorResponseBody.mjs +2 -0
  163. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotImplementedErrorResponseBody.d.mts +9 -0
  164. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsNotImplementedErrorResponseBody.mjs +2 -0
  165. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsResponseBody.d.mts +4 -0
  166. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsResponseBody.mjs +2 -0
  167. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsServiceUnavailableErrorResponseBody.d.mts +9 -0
  168. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsServiceUnavailableErrorResponseBody.mjs +2 -0
  169. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsTooManyRequestsErrorResponseBody.d.mts +9 -0
  170. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsTooManyRequestsErrorResponseBody.mjs +2 -0
  171. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsUnauthorizedErrorResponseBody.d.mts +9 -0
  172. package/dist/esm/api/types/ResolveAssignmentByDetailsResolveAssignmentByDetailsUnauthorizedErrorResponseBody.mjs +2 -0
  173. package/dist/esm/api/types/ResolveAssignmentByDetailsResponseBodyResponseBody.d.mts +9 -0
  174. package/dist/esm/api/types/ResolveAssignmentByDetailsResponseBodyResponseBody.mjs +2 -0
  175. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchBadGatewayErrorResponseBody.d.mts +9 -0
  176. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchBadGatewayErrorResponseBody.mjs +2 -0
  177. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchGatewayTimeoutErrorResponseBody.d.mts +9 -0
  178. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchGatewayTimeoutErrorResponseBody.mjs +2 -0
  179. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchInternalServerErrorResponseBody.d.mts +9 -0
  180. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchInternalServerErrorResponseBody.mjs +2 -0
  181. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchMethodNotAllowedErrorResponseBody.d.mts +9 -0
  182. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchMethodNotAllowedErrorResponseBody.mjs +2 -0
  183. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotFoundErrorResponseBody.d.mts +9 -0
  184. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotFoundErrorResponseBody.mjs +2 -0
  185. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotImplementedErrorResponseBody.d.mts +9 -0
  186. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchNotImplementedErrorResponseBody.mjs +2 -0
  187. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchResponseBody.d.mts +7 -0
  188. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchResponseBody.mjs +2 -0
  189. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchServiceUnavailableErrorResponseBody.d.mts +9 -0
  190. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchServiceUnavailableErrorResponseBody.mjs +2 -0
  191. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchTooManyRequestsErrorResponseBody.d.mts +9 -0
  192. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchTooManyRequestsErrorResponseBody.mjs +2 -0
  193. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchUnauthorizedErrorResponseBody.d.mts +9 -0
  194. package/dist/esm/api/types/SafetyEventsV2PatchSafetyEventsV2BatchUnauthorizedErrorResponseBody.mjs +2 -0
  195. package/dist/esm/api/types/index.d.mts +35 -0
  196. package/dist/esm/api/types/index.mjs +35 -0
  197. package/dist/esm/version.d.mts +1 -1
  198. package/dist/esm/version.mjs +1 -1
  199. package/package.json +1 -1
  200. package/reference.md +231 -1
@@ -19,6 +19,104 @@ export class PreviewApIsClient {
19
19
  constructor(options = {}) {
20
20
  this._options = normalizeClientOptionsWithAuth(options);
21
21
  }
22
+ /**
23
+ * List associations between vehicles and peripheral devices within a given time range. Associations represent the relationship between a central device (vehicle) and a peripheral device (e.g. asset tag). An association with a null endTime is still active.
24
+ *
25
+ * <b>Rate limit:</b> 5 requests/sec (learn more about rate limits <a href="https://developers.samsara.com/docs/rate-limits" target="_blank">here</a>).
26
+ *
27
+ * To use this endpoint, select **Read Assets** under the Assets category when creating or editing an API token. <a href="https://developers.samsara.com/docs/authentication#scopes-for-api-tokens" target="_blank">Learn More.</a>
28
+ *
29
+ * Endpoints in this section are in Preview. These APIs are not functional and are instead for soliciting feedback from our API users on the intended design of this API. Additionally, it is not guaranteed that we will be releasing an endpoint included in this section to production. This means that developers should **NOT** rely on these APIs to build business critical applications
30
+ *
31
+ * - Samsara may change the structure of a preview API's interface without versioning or any notice to API users.
32
+ *
33
+ * - When an endpoint becomes generally available, it will be announced in the API [changelog](https://developers.samsara.com/changelog).
34
+ *
35
+ *
36
+ * **Submit Feedback**: Likes, dislikes, and API feature requests should be filed as feedback in our <a href="https://forms.gle/zkD4NCH7HjKb7mm69" target="_blank">API feedback form</a>. If you encountered an issue or noticed inaccuracies in the API documentation, please <a href="https://www.samsara.com/help" target="_blank">submit a case</a> to our support team.
37
+ *
38
+ * @param {Samsara.ListAssociationsRequest} request
39
+ * @param {PreviewApIsClient.RequestOptions} requestOptions - Request-specific configuration.
40
+ *
41
+ * @throws {@link Samsara.UnauthorizedError}
42
+ * @throws {@link Samsara.NotFoundError}
43
+ * @throws {@link Samsara.MethodNotAllowedError}
44
+ * @throws {@link Samsara.TooManyRequestsError}
45
+ * @throws {@link Samsara.InternalServerError}
46
+ * @throws {@link Samsara.NotImplementedError}
47
+ * @throws {@link Samsara.BadGatewayError}
48
+ * @throws {@link Samsara.ServiceUnavailableError}
49
+ * @throws {@link Samsara.GatewayTimeoutError}
50
+ *
51
+ * @example
52
+ * await client.previewApIs.listAssociations({
53
+ * startTime: "startTime",
54
+ * endTime: "endTime"
55
+ * })
56
+ */
57
+ listAssociations(request, requestOptions) {
58
+ return core.HttpResponsePromise.fromPromise(this.__listAssociations(request, requestOptions));
59
+ }
60
+ __listAssociations(request, requestOptions) {
61
+ return __awaiter(this, void 0, void 0, function* () {
62
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
63
+ const { peripheralIds, startTime, endTime, after } = request;
64
+ const _queryParams = {
65
+ peripheralIds,
66
+ startTime,
67
+ endTime,
68
+ after,
69
+ };
70
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
71
+ const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ "X-Samsara-Version": requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
72
+ const _response = yield core.fetcher({
73
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SamsaraEnvironment.ProductionApi, "preview/fleet/assets/associations"),
74
+ method: "GET",
75
+ headers: _headers,
76
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
77
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
78
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
79
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
80
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
81
+ logging: this._options.logging,
82
+ });
83
+ if (_response.ok) {
84
+ return {
85
+ data: _response.body,
86
+ rawResponse: _response.rawResponse,
87
+ };
88
+ }
89
+ if (_response.error.reason === "status-code") {
90
+ switch (_response.error.statusCode) {
91
+ case 401:
92
+ throw new Samsara.UnauthorizedError(_response.error.body, _response.rawResponse);
93
+ case 404:
94
+ throw new Samsara.NotFoundError(_response.error.body, _response.rawResponse);
95
+ case 405:
96
+ throw new Samsara.MethodNotAllowedError(_response.error.body, _response.rawResponse);
97
+ case 429:
98
+ throw new Samsara.TooManyRequestsError(_response.error.body, _response.rawResponse);
99
+ case 500:
100
+ throw new Samsara.InternalServerError(_response.error.body, _response.rawResponse);
101
+ case 501:
102
+ throw new Samsara.NotImplementedError(_response.error.body, _response.rawResponse);
103
+ case 502:
104
+ throw new Samsara.BadGatewayError(_response.error.body, _response.rawResponse);
105
+ case 503:
106
+ throw new Samsara.ServiceUnavailableError(_response.error.body, _response.rawResponse);
107
+ case 504:
108
+ throw new Samsara.GatewayTimeoutError(_response.error.body, _response.rawResponse);
109
+ default:
110
+ throw new errors.SamsaraError({
111
+ statusCode: _response.error.statusCode,
112
+ body: _response.error.body,
113
+ rawResponse: _response.rawResponse,
114
+ });
115
+ }
116
+ }
117
+ return handleNonStatusCodeError(_response.error, _response.rawResponse, "GET", "/preview/fleet/assets/associations");
118
+ });
119
+ }
22
120
  /**
23
121
  * Creates a short-lived auth token for a driver.
24
122
  *
@@ -288,4 +386,97 @@ export class PreviewApIsClient {
288
386
  return handleNonStatusCodeError(_response.error, _response.rawResponse, "DELETE", "/preview/fleet/vehicles/{id}/lock");
289
387
  });
290
388
  }
389
+ /**
390
+ * Asynchronously update eventState and/or context labels for one or more Safety Events. Returns 202 Accepted immediately. State changes propagate asynchronously; use GET /safety-events to confirm updated state. If any safetyEventIds are not found, the entire request fails with 404 before any mutations are executed. If both eventState and label fields are provided, the two mutations execute serially and are not transactional — a label mutation failure will not roll back a successful state change.
391
+ *
392
+ * <b>Rate limit:</b> 5 requests/sec (learn more about rate limits <a href="https://developers.samsara.com/docs/rate-limits" target="_blank">here</a>).
393
+ *
394
+ * To use this endpoint, select **Write Safety Events & Scores** under the Safety & Cameras category when creating or editing an API token. <a href="https://developers.samsara.com/docs/authentication#scopes-for-api-tokens" target="_blank">Learn More.</a>
395
+ *
396
+ * Endpoints in this section are in Preview. These APIs are not functional and are instead for soliciting feedback from our API users on the intended design of this API. Additionally, it is not guaranteed that we will be releasing an endpoint included in this section to production. This means that developers should **NOT** rely on these APIs to build business critical applications
397
+ *
398
+ * - Samsara may change the structure of a preview API's interface without versioning or any notice to API users.
399
+ *
400
+ * - When an endpoint becomes generally available, it will be announced in the API [changelog](https://developers.samsara.com/changelog).
401
+ *
402
+ *
403
+ * **Submit Feedback**: Likes, dislikes, and API feature requests should be filed as feedback in our <a href="https://forms.gle/zkD4NCH7HjKb7mm69" target="_blank">API feedback form</a>. If you encountered an issue or noticed inaccuracies in the API documentation, please <a href="https://www.samsara.com/help" target="_blank">submit a case</a> to our support team.
404
+ *
405
+ * @param {Samsara.SafetyEventsV2PatchSafetyEventsV2BatchRequestBody} request
406
+ * @param {PreviewApIsClient.RequestOptions} requestOptions - Request-specific configuration.
407
+ *
408
+ * @throws {@link Samsara.UnauthorizedError}
409
+ * @throws {@link Samsara.NotFoundError}
410
+ * @throws {@link Samsara.MethodNotAllowedError}
411
+ * @throws {@link Samsara.TooManyRequestsError}
412
+ * @throws {@link Samsara.InternalServerError}
413
+ * @throws {@link Samsara.NotImplementedError}
414
+ * @throws {@link Samsara.BadGatewayError}
415
+ * @throws {@link Samsara.ServiceUnavailableError}
416
+ * @throws {@link Samsara.GatewayTimeoutError}
417
+ *
418
+ * @example
419
+ * await client.previewApIs.patchSafetyEventsV2Batch({
420
+ * safetyEventIds: ["bb2ff5ab-30ad-49ec-9d2d-55ec30bbf590", "bb2ff5ab-30ad-49ec-9d2d-55ec30bbf590"]
421
+ * })
422
+ */
423
+ patchSafetyEventsV2Batch(request, requestOptions) {
424
+ return core.HttpResponsePromise.fromPromise(this.__patchSafetyEventsV2Batch(request, requestOptions));
425
+ }
426
+ __patchSafetyEventsV2Batch(request, requestOptions) {
427
+ return __awaiter(this, void 0, void 0, function* () {
428
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
429
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
430
+ const _headers = mergeHeaders(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, mergeOnlyDefinedHeaders({ "X-Samsara-Version": requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.version }), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
431
+ const _response = yield core.fetcher({
432
+ url: core.url.join((_c = (_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.SamsaraEnvironment.ProductionApi, "preview/safety-events/batch"),
433
+ method: "PATCH",
434
+ headers: _headers,
435
+ contentType: "application/json",
436
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
437
+ requestType: "json",
438
+ body: request,
439
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
440
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
441
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
442
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
443
+ logging: this._options.logging,
444
+ });
445
+ if (_response.ok) {
446
+ return {
447
+ data: _response.body,
448
+ rawResponse: _response.rawResponse,
449
+ };
450
+ }
451
+ if (_response.error.reason === "status-code") {
452
+ switch (_response.error.statusCode) {
453
+ case 401:
454
+ throw new Samsara.UnauthorizedError(_response.error.body, _response.rawResponse);
455
+ case 404:
456
+ throw new Samsara.NotFoundError(_response.error.body, _response.rawResponse);
457
+ case 405:
458
+ throw new Samsara.MethodNotAllowedError(_response.error.body, _response.rawResponse);
459
+ case 429:
460
+ throw new Samsara.TooManyRequestsError(_response.error.body, _response.rawResponse);
461
+ case 500:
462
+ throw new Samsara.InternalServerError(_response.error.body, _response.rawResponse);
463
+ case 501:
464
+ throw new Samsara.NotImplementedError(_response.error.body, _response.rawResponse);
465
+ case 502:
466
+ throw new Samsara.BadGatewayError(_response.error.body, _response.rawResponse);
467
+ case 503:
468
+ throw new Samsara.ServiceUnavailableError(_response.error.body, _response.rawResponse);
469
+ case 504:
470
+ throw new Samsara.GatewayTimeoutError(_response.error.body, _response.rawResponse);
471
+ default:
472
+ throw new errors.SamsaraError({
473
+ statusCode: _response.error.statusCode,
474
+ body: _response.error.body,
475
+ rawResponse: _response.rawResponse,
476
+ });
477
+ }
478
+ }
479
+ return handleNonStatusCodeError(_response.error, _response.rawResponse, "PATCH", "/preview/safety-events/batch");
480
+ });
481
+ }
291
482
  }
@@ -0,0 +1,17 @@
1
+ /**
2
+ * @example
3
+ * {
4
+ * startTime: "startTime",
5
+ * endTime: "endTime"
6
+ * }
7
+ */
8
+ export interface ListAssociationsRequest {
9
+ /** A comma-separated list of peripheral asset IDs to filter associations by. (Example: 1234,5678) */
10
+ peripheralIds?: string | string[];
11
+ /** A start time in RFC 3339 format. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00). */
12
+ startTime: string;
13
+ /** An end time in RFC 3339 format. Millisecond precision and timezones are supported. (Examples: 2019-06-13T19:08:25Z, 2019-06-13T19:08:25.455Z, OR 2015-09-15T14:00:12-04:00). */
14
+ endTime: string;
15
+ /** If specified, this should be the endCursor value from the previous page of results. When present, this request will return the next page of results that occur immediately after the previous page of results. */
16
+ after?: string;
17
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,31 @@
1
+ import type * as Samsara from "../../../../index.mjs";
2
+ /**
3
+ * @example
4
+ * {
5
+ * safetyEventIds: ["bb2ff5ab-30ad-49ec-9d2d-55ec30bbf590", "bb2ff5ab-30ad-49ec-9d2d-55ec30bbf590"]
6
+ * }
7
+ */
8
+ export interface SafetyEventsV2PatchSafetyEventsV2BatchRequestBody {
9
+ /** Context label IDs to add to the Safety Events. */
10
+ contextLabelIdsToAdd?: string[];
11
+ /** Context label IDs to remove from the Safety Events. */
12
+ contextLabelIdsToRemove?: string[];
13
+ dismissalReason?: Samsara.PatchSafetyEventsDismissalReasonBodyRequestBody;
14
+ /** The new state to apply to all specified Safety Events. Valid values: `needsReview`, `reviewed`, `needsCoaching`, `coached`, `dismissed`, `needsRecognition`, `recognized` */
15
+ eventState?: SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.EventState;
16
+ /** IDs of the Safety Events to update. Maximum 200. */
17
+ safetyEventIds: string[];
18
+ }
19
+ export declare namespace SafetyEventsV2PatchSafetyEventsV2BatchRequestBody {
20
+ /** The new state to apply to all specified Safety Events. Valid values: `needsReview`, `reviewed`, `needsCoaching`, `coached`, `dismissed`, `needsRecognition`, `recognized` */
21
+ const EventState: {
22
+ readonly NeedsReview: "needsReview";
23
+ readonly Reviewed: "reviewed";
24
+ readonly NeedsCoaching: "needsCoaching";
25
+ readonly Coached: "coached";
26
+ readonly Dismissed: "dismissed";
27
+ readonly NeedsRecognition: "needsRecognition";
28
+ readonly Recognized: "recognized";
29
+ };
30
+ type EventState = (typeof EventState)[keyof typeof EventState];
31
+ }
@@ -0,0 +1,14 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export var SafetyEventsV2PatchSafetyEventsV2BatchRequestBody;
3
+ (function (SafetyEventsV2PatchSafetyEventsV2BatchRequestBody) {
4
+ /** The new state to apply to all specified Safety Events. Valid values: `needsReview`, `reviewed`, `needsCoaching`, `coached`, `dismissed`, `needsRecognition`, `recognized` */
5
+ SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.EventState = {
6
+ NeedsReview: "needsReview",
7
+ Reviewed: "reviewed",
8
+ NeedsCoaching: "needsCoaching",
9
+ Coached: "coached",
10
+ Dismissed: "dismissed",
11
+ NeedsRecognition: "needsRecognition",
12
+ Recognized: "recognized",
13
+ };
14
+ })(SafetyEventsV2PatchSafetyEventsV2BatchRequestBody || (SafetyEventsV2PatchSafetyEventsV2BatchRequestBody = {}));
@@ -1,3 +1,5 @@
1
1
  export type { DriversAuthTokenCreateDriverAuthTokenRequestBody } from "./DriversAuthTokenCreateDriverAuthTokenRequestBody.mjs";
2
+ export type { ListAssociationsRequest } from "./ListAssociationsRequest.mjs";
2
3
  export type { LockVehicleRequest } from "./LockVehicleRequest.mjs";
4
+ export { SafetyEventsV2PatchSafetyEventsV2BatchRequestBody } from "./SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.mjs";
3
5
  export type { UnlockVehicleRequest } from "./UnlockVehicleRequest.mjs";
@@ -1 +1 @@
1
- export {};
1
+ export { SafetyEventsV2PatchSafetyEventsV2BatchRequestBody } from "./SafetyEventsV2PatchSafetyEventsV2BatchRequestBody.mjs";
@@ -0,0 +1,15 @@
1
+ /**
2
+ * An association between a vehicle (central device) and a peripheral device.
3
+ */
4
+ export interface AssociationResponseBody {
5
+ /** The time when this association ended, in RFC 3339 format. Null if the association is still active. */
6
+ associationEndTime?: string | undefined;
7
+ /** The time when this association started, in RFC 3339 format. */
8
+ associationStartTime: string;
9
+ /** The Samsara ID of the peripheral device in this association. */
10
+ peripheralId: string;
11
+ /** The human-readable name of the peripheral device, if available. */
12
+ peripheralName?: string | undefined;
13
+ /** The Samsara ID of the vehicle (central device) in this association. */
14
+ vehicleId: string;
15
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Bad Gateway
3
+ */
4
+ export interface AssociationsListAssociationsBadGatewayErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Gateway timeout
3
+ */
4
+ export interface AssociationsListAssociationsGatewayTimeoutErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * An internal server error occurred
3
+ */
4
+ export interface AssociationsListAssociationsInternalServerErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Method not allowed
3
+ */
4
+ export interface AssociationsListAssociationsMethodNotAllowedErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Resource not found
3
+ */
4
+ export interface AssociationsListAssociationsNotFoundErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Requested endpoint is not yet implemented
3
+ */
4
+ export interface AssociationsListAssociationsNotImplementedErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,6 @@
1
+ import type * as Samsara from "../index.mjs";
2
+ export interface AssociationsListAssociationsResponseBody {
3
+ /** List of asset associations matching the filter criteria. */
4
+ data: Samsara.AssociationResponseBody[];
5
+ pagination: Samsara.GoaPaginationResponseResponseBody;
6
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Service unavailable
3
+ */
4
+ export interface AssociationsListAssociationsServiceUnavailableErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Too many requests
3
+ */
4
+ export interface AssociationsListAssociationsTooManyRequestsErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ /**
2
+ * Unauthorized
3
+ */
4
+ export interface AssociationsListAssociationsUnauthorizedErrorResponseBody {
5
+ /** Message of error */
6
+ message: string;
7
+ /** The request ID; used when reaching out to support for issues with requests. */
8
+ requestId: string;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -10,6 +10,8 @@ export interface DefectTypesResponseDataResponseBody {
10
10
  label: string;
11
11
  /** Section for DVIR defect type. Valid values: `exteriorFront`, `exteriorRear`, `exteriorSideUnderneath`, `interiorDriverCab`, `interiorPassengerArea`, `other`, `unknown` */
12
12
  sectionType: DefectTypesResponseDataResponseBody.SectionType;
13
+ /** The severity of the defect type. Only present for DVIR 2.0 defect types. Valid values: `major`, `minor`, `notApplicable` */
14
+ severity?: DefectTypesResponseDataResponseBody.Severity | undefined;
13
15
  }
14
16
  export declare namespace DefectTypesResponseDataResponseBody {
15
17
  /** Section for DVIR defect type. Valid values: `exteriorFront`, `exteriorRear`, `exteriorSideUnderneath`, `interiorDriverCab`, `interiorPassengerArea`, `other`, `unknown` */
@@ -23,4 +25,11 @@ export declare namespace DefectTypesResponseDataResponseBody {
23
25
  readonly Unknown: "unknown";
24
26
  };
25
27
  type SectionType = (typeof SectionType)[keyof typeof SectionType];
28
+ /** The severity of the defect type. Only present for DVIR 2.0 defect types. Valid values: `major`, `minor`, `notApplicable` */
29
+ const Severity: {
30
+ readonly Major: "major";
31
+ readonly Minor: "minor";
32
+ readonly NotApplicable: "notApplicable";
33
+ };
34
+ type Severity = (typeof Severity)[keyof typeof Severity];
26
35
  }
@@ -11,4 +11,10 @@ export var DefectTypesResponseDataResponseBody;
11
11
  Other: "other",
12
12
  Unknown: "unknown",
13
13
  };
14
+ /** The severity of the defect type. Only present for DVIR 2.0 defect types. Valid values: `major`, `minor`, `notApplicable` */
15
+ DefectTypesResponseDataResponseBody.Severity = {
16
+ Major: "major",
17
+ Minor: "minor",
18
+ NotApplicable: "notApplicable",
19
+ };
14
20
  })(DefectTypesResponseDataResponseBody || (DefectTypesResponseDataResponseBody = {}));
@@ -7,8 +7,12 @@ export interface DvirDefectsObjectV20220913ResponseBody {
7
7
  comment?: string | undefined;
8
8
  /** Time when the defect was created. UTC timestamp in RFC 3339 format. */
9
9
  createdAtTime: string;
10
+ /** The severity of the DVIR defect. Valid values: `minor`, `major`, `unspecified` */
11
+ defectSeverity?: DvirDefectsObjectV20220913ResponseBody.DefectSeverity | undefined;
10
12
  /** The type of DVIR defect. */
11
13
  defectType: string;
14
+ /** The ID of the DVIR defect type. */
15
+ defectTypeId?: string | undefined;
12
16
  /** The ID of the defect. */
13
17
  id: string;
14
18
  /** Signifies if this defect is resolved. */
@@ -23,3 +27,12 @@ export interface DvirDefectsObjectV20220913ResponseBody {
23
27
  trailer?: Samsara.GoaTrailerTinyResponseResponseBody | undefined;
24
28
  vehicle?: Samsara.VehicleWithGatewayTinyResponseResponseBody | undefined;
25
29
  }
30
+ export declare namespace DvirDefectsObjectV20220913ResponseBody {
31
+ /** The severity of the DVIR defect. Valid values: `minor`, `major`, `unspecified` */
32
+ const DefectSeverity: {
33
+ readonly Minor: "minor";
34
+ readonly Major: "major";
35
+ readonly Unspecified: "unspecified";
36
+ };
37
+ type DefectSeverity = (typeof DefectSeverity)[keyof typeof DefectSeverity];
38
+ }
@@ -1,2 +1,10 @@
1
1
  // This file was auto-generated by Fern from our API Definition.
2
- export {};
2
+ export var DvirDefectsObjectV20220913ResponseBody;
3
+ (function (DvirDefectsObjectV20220913ResponseBody) {
4
+ /** The severity of the DVIR defect. Valid values: `minor`, `major`, `unspecified` */
5
+ DvirDefectsObjectV20220913ResponseBody.DefectSeverity = {
6
+ Minor: "minor",
7
+ Major: "major",
8
+ Unspecified: "unspecified",
9
+ };
10
+ })(DvirDefectsObjectV20220913ResponseBody || (DvirDefectsObjectV20220913ResponseBody = {}));
@@ -11,10 +11,18 @@ export interface MissingStateResponseBody {
11
11
  note?: string | undefined;
12
12
  /** Users subscribed to location update notifications for this asset. */
13
13
  notification_recipients?: Samsara.NotificationRecipientResponseResponseBody[] | undefined;
14
+ /** The source of the last update to this recovery state. Defaults to `dashboard` if not explicitly set. Valid values: `dashboard`, `api` */
15
+ update_source?: MissingStateResponseBody.UpdateSource | undefined;
14
16
  /** Timestamp when the asset was marked as missing, in milliseconds since epoch. */
15
17
  updated_at_ms: number;
16
18
  /** The ID of the user who marked the asset as missing. */
17
19
  updated_by_user_id?: number | undefined;
18
- /** The unique UUID of this recovery state record. */
19
- uuid: string;
20
+ }
21
+ export declare namespace MissingStateResponseBody {
22
+ /** The source of the last update to this recovery state. Defaults to `dashboard` if not explicitly set. Valid values: `dashboard`, `api` */
23
+ const UpdateSource: {
24
+ readonly Dashboard: "dashboard";
25
+ readonly Api: "api";
26
+ };
27
+ type UpdateSource = (typeof UpdateSource)[keyof typeof UpdateSource];
20
28
  }
@@ -1,2 +1,9 @@
1
1
  // This file was auto-generated by Fern from our API Definition.
2
- export {};
2
+ export var MissingStateResponseBody;
3
+ (function (MissingStateResponseBody) {
4
+ /** The source of the last update to this recovery state. Defaults to `dashboard` if not explicitly set. Valid values: `dashboard`, `api` */
5
+ MissingStateResponseBody.UpdateSource = {
6
+ Dashboard: "dashboard",
7
+ Api: "api",
8
+ };
9
+ })(MissingStateResponseBody || (MissingStateResponseBody = {}));
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Dismissal reason. Required when eventState is `dismissed`. Must not be provided for other states.
3
+ */
4
+ export interface PatchSafetyEventsDismissalReasonBodyRequestBody {
5
+ /** The dismissal reason code associated with the event. Valid values: `incorrect`, `minorEvent`, `other` */
6
+ code: PatchSafetyEventsDismissalReasonBodyRequestBody.Code;
7
+ /** The dismissal reason comment associated with the event. */
8
+ comment?: string | undefined;
9
+ }
10
+ export declare namespace PatchSafetyEventsDismissalReasonBodyRequestBody {
11
+ /** The dismissal reason code associated with the event. Valid values: `incorrect`, `minorEvent`, `other` */
12
+ const Code: {
13
+ readonly Incorrect: "incorrect";
14
+ readonly MinorEvent: "minorEvent";
15
+ readonly Other: "other";
16
+ };
17
+ type Code = (typeof Code)[keyof typeof Code];
18
+ }
@@ -0,0 +1,10 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export var PatchSafetyEventsDismissalReasonBodyRequestBody;
3
+ (function (PatchSafetyEventsDismissalReasonBodyRequestBody) {
4
+ /** The dismissal reason code associated with the event. Valid values: `incorrect`, `minorEvent`, `other` */
5
+ PatchSafetyEventsDismissalReasonBodyRequestBody.Code = {
6
+ Incorrect: "incorrect",
7
+ MinorEvent: "minorEvent",
8
+ Other: "other",
9
+ };
10
+ })(PatchSafetyEventsDismissalReasonBodyRequestBody || (PatchSafetyEventsDismissalReasonBodyRequestBody = {}));
@@ -0,0 +1,7 @@
1
+ /**
2
+ * Data payload for a single Safety Event in the batch response.
3
+ */
4
+ export interface PatchSafetyEventsResponseItemDataResponseBody {
5
+ /** The unique Samsara ID (uuid) of the safety event. */
6
+ safetyEventId: string;
7
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};
@@ -0,0 +1,9 @@
1
+ import type * as Samsara from "../index.mjs";
2
+ /**
3
+ * Per-item result for a single Safety Event in the batch.
4
+ */
5
+ export interface PatchSafetyEventsResponseItemResponseBody {
6
+ data: Samsara.PatchSafetyEventsResponseItemDataResponseBody;
7
+ /** HTTP status code for this item. Always 202 on success. */
8
+ status: number;
9
+ }
@@ -0,0 +1,2 @@
1
+ // This file was auto-generated by Fern from our API Definition.
2
+ export {};