@truvity/sdk 0.0.1

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 (1191) hide show
  1. package/Client.d.ts +25 -0
  2. package/Client.js +22 -0
  3. package/api/errors/BadRequestError.d.ts +8 -0
  4. package/api/errors/BadRequestError.js +41 -0
  5. package/api/errors/ForbiddenError.d.ts +8 -0
  6. package/api/errors/ForbiddenError.js +41 -0
  7. package/api/errors/InternalServerError.d.ts +8 -0
  8. package/api/errors/InternalServerError.js +41 -0
  9. package/api/errors/NotFoundError.d.ts +7 -0
  10. package/api/errors/NotFoundError.js +41 -0
  11. package/api/errors/UnauthorizedError.d.ts +8 -0
  12. package/api/errors/UnauthorizedError.js +41 -0
  13. package/api/errors/index.d.ts +5 -0
  14. package/api/errors/index.js +21 -0
  15. package/api/index.d.ts +3 -0
  16. package/api/index.js +19 -0
  17. package/api/resources/index.d.ts +4 -0
  18. package/api/resources/index.js +33 -0
  19. package/api/resources/owners/client/Client.d.ts +124 -0
  20. package/api/resources/owners/client/Client.js +711 -0
  21. package/api/resources/owners/client/index.d.ts +1 -0
  22. package/api/resources/owners/client/index.js +17 -0
  23. package/api/resources/owners/client/requests/OwnerCreateRequest.d.ts +38 -0
  24. package/api/resources/owners/client/requests/OwnerCreateRequest.js +5 -0
  25. package/api/resources/owners/client/requests/OwnerDeleteRequest.d.ts +49 -0
  26. package/api/resources/owners/client/requests/OwnerDeleteRequest.js +5 -0
  27. package/api/resources/owners/client/requests/OwnerHistoryRequest.d.ts +27 -0
  28. package/api/resources/owners/client/requests/OwnerHistoryRequest.js +5 -0
  29. package/api/resources/owners/client/requests/OwnerLatestRequest.d.ts +27 -0
  30. package/api/resources/owners/client/requests/OwnerLatestRequest.js +5 -0
  31. package/api/resources/owners/client/requests/OwnerRevisionRequest.d.ts +27 -0
  32. package/api/resources/owners/client/requests/OwnerRevisionRequest.js +5 -0
  33. package/api/resources/owners/client/requests/OwnerSearch.d.ts +14 -0
  34. package/api/resources/owners/client/requests/OwnerSearch.js +5 -0
  35. package/api/resources/owners/client/requests/OwnerUpdateRequest.d.ts +57 -0
  36. package/api/resources/owners/client/requests/OwnerUpdateRequest.js +5 -0
  37. package/api/resources/owners/client/requests/index.d.ts +7 -0
  38. package/api/resources/owners/client/requests/index.js +2 -0
  39. package/api/resources/owners/index.d.ts +1 -0
  40. package/api/resources/owners/index.js +17 -0
  41. package/api/resources/pets/client/Client.d.ts +133 -0
  42. package/api/resources/pets/client/Client.js +861 -0
  43. package/api/resources/pets/client/index.d.ts +1 -0
  44. package/api/resources/pets/client/index.js +17 -0
  45. package/api/resources/pets/client/requests/PetCreateRequest.d.ts +38 -0
  46. package/api/resources/pets/client/requests/PetCreateRequest.js +5 -0
  47. package/api/resources/pets/client/requests/PetDeleteRequest.d.ts +49 -0
  48. package/api/resources/pets/client/requests/PetDeleteRequest.js +5 -0
  49. package/api/resources/pets/client/requests/PetDownloadRequest.d.ts +23 -0
  50. package/api/resources/pets/client/requests/PetDownloadRequest.js +5 -0
  51. package/api/resources/pets/client/requests/PetHistoryRequest.d.ts +27 -0
  52. package/api/resources/pets/client/requests/PetHistoryRequest.js +5 -0
  53. package/api/resources/pets/client/requests/PetLatestRequest.d.ts +27 -0
  54. package/api/resources/pets/client/requests/PetLatestRequest.js +5 -0
  55. package/api/resources/pets/client/requests/PetRevisionRequest.d.ts +27 -0
  56. package/api/resources/pets/client/requests/PetRevisionRequest.js +5 -0
  57. package/api/resources/pets/client/requests/PetSearch.d.ts +14 -0
  58. package/api/resources/pets/client/requests/PetSearch.js +5 -0
  59. package/api/resources/pets/client/requests/PetUpdateRequest.d.ts +56 -0
  60. package/api/resources/pets/client/requests/PetUpdateRequest.js +5 -0
  61. package/api/resources/pets/client/requests/UploadRequest.d.ts +31 -0
  62. package/api/resources/pets/client/requests/UploadRequest.js +5 -0
  63. package/api/resources/pets/client/requests/index.d.ts +9 -0
  64. package/api/resources/pets/client/requests/index.js +2 -0
  65. package/api/resources/pets/index.d.ts +1 -0
  66. package/api/resources/pets/index.js +17 -0
  67. package/api/types/AnnotationValue.d.ts +7 -0
  68. package/api/types/AnnotationValue.js +5 -0
  69. package/api/types/Annotations.d.ts +11 -0
  70. package/api/types/Annotations.js +5 -0
  71. package/api/types/BadRequestErrorBody.d.ts +16 -0
  72. package/api/types/BadRequestErrorBody.js +5 -0
  73. package/api/types/BlobId.d.ts +8 -0
  74. package/api/types/BlobId.js +5 -0
  75. package/api/types/Checksum.d.ts +22 -0
  76. package/api/types/Checksum.js +5 -0
  77. package/api/types/ChecksumAlgorithm.d.ts +13 -0
  78. package/api/types/ChecksumAlgorithm.js +12 -0
  79. package/api/types/ChecksumCrc32.d.ts +10 -0
  80. package/api/types/ChecksumCrc32.js +5 -0
  81. package/api/types/ChecksumCrc32C.d.ts +10 -0
  82. package/api/types/ChecksumCrc32C.js +5 -0
  83. package/api/types/ChecksumSha1.d.ts +10 -0
  84. package/api/types/ChecksumSha1.js +5 -0
  85. package/api/types/ChecksumSha256.d.ts +10 -0
  86. package/api/types/ChecksumSha256.js +5 -0
  87. package/api/types/ContentType.d.ts +7 -0
  88. package/api/types/ContentType.js +5 -0
  89. package/api/types/Download.d.ts +7 -0
  90. package/api/types/Download.js +5 -0
  91. package/api/types/ETag.d.ts +14 -0
  92. package/api/types/ETag.js +5 -0
  93. package/api/types/FilterId.d.ts +22 -0
  94. package/api/types/FilterId.js +5 -0
  95. package/api/types/FilterIdEqual.d.ts +10 -0
  96. package/api/types/FilterIdEqual.js +5 -0
  97. package/api/types/FilterIdIn.d.ts +10 -0
  98. package/api/types/FilterIdIn.js +5 -0
  99. package/api/types/FilterIdNotEqual.d.ts +10 -0
  100. package/api/types/FilterIdNotEqual.js +5 -0
  101. package/api/types/FilterIdNotIn.d.ts +10 -0
  102. package/api/types/FilterIdNotIn.js +5 -0
  103. package/api/types/FilterInteger.d.ts +31 -0
  104. package/api/types/FilterInteger.js +5 -0
  105. package/api/types/FilterIntegerBetween.d.ts +12 -0
  106. package/api/types/FilterIntegerBetween.js +5 -0
  107. package/api/types/FilterIntegerEqual.d.ts +10 -0
  108. package/api/types/FilterIntegerEqual.js +5 -0
  109. package/api/types/FilterIntegerGreaterThan.d.ts +10 -0
  110. package/api/types/FilterIntegerGreaterThan.js +5 -0
  111. package/api/types/FilterIntegerGreaterThanOrEqual.d.ts +10 -0
  112. package/api/types/FilterIntegerGreaterThanOrEqual.js +5 -0
  113. package/api/types/FilterIntegerLessThan.d.ts +10 -0
  114. package/api/types/FilterIntegerLessThan.js +5 -0
  115. package/api/types/FilterIntegerLessThanOrEqual.d.ts +10 -0
  116. package/api/types/FilterIntegerLessThanOrEqual.js +5 -0
  117. package/api/types/FilterIntegerNotEqual.d.ts +10 -0
  118. package/api/types/FilterIntegerNotEqual.js +5 -0
  119. package/api/types/FilterString.d.ts +16 -0
  120. package/api/types/FilterString.js +5 -0
  121. package/api/types/FilterStringEqual.d.ts +10 -0
  122. package/api/types/FilterStringEqual.js +5 -0
  123. package/api/types/FilterStringNotEqual.d.ts +10 -0
  124. package/api/types/FilterStringNotEqual.js +5 -0
  125. package/api/types/FilterTimestamp.d.ts +31 -0
  126. package/api/types/FilterTimestamp.js +5 -0
  127. package/api/types/FilterTimestampBetween.d.ts +12 -0
  128. package/api/types/FilterTimestampBetween.js +5 -0
  129. package/api/types/FilterTimestampEqual.d.ts +10 -0
  130. package/api/types/FilterTimestampEqual.js +5 -0
  131. package/api/types/FilterTimestampGreaterThan.d.ts +10 -0
  132. package/api/types/FilterTimestampGreaterThan.js +5 -0
  133. package/api/types/FilterTimestampGreaterThanOrEqual.d.ts +10 -0
  134. package/api/types/FilterTimestampGreaterThanOrEqual.js +5 -0
  135. package/api/types/FilterTimestampIsNotNull.d.ts +8 -0
  136. package/api/types/FilterTimestampIsNotNull.js +5 -0
  137. package/api/types/FilterTimestampIsNull.d.ts +8 -0
  138. package/api/types/FilterTimestampIsNull.js +5 -0
  139. package/api/types/FilterTimestampLessThan.d.ts +10 -0
  140. package/api/types/FilterTimestampLessThan.js +5 -0
  141. package/api/types/FilterTimestampLessThanOrEqual.d.ts +10 -0
  142. package/api/types/FilterTimestampLessThanOrEqual.js +5 -0
  143. package/api/types/FilterTimestampNotEqual.d.ts +10 -0
  144. package/api/types/FilterTimestampNotEqual.js +5 -0
  145. package/api/types/FilterTimestampOptional.d.ts +38 -0
  146. package/api/types/FilterTimestampOptional.js +5 -0
  147. package/api/types/HashCrc32.d.ts +7 -0
  148. package/api/types/HashCrc32.js +5 -0
  149. package/api/types/HashCrc32C.d.ts +7 -0
  150. package/api/types/HashCrc32C.js +5 -0
  151. package/api/types/HashSha1.d.ts +7 -0
  152. package/api/types/HashSha1.js +5 -0
  153. package/api/types/HashSha256.d.ts +7 -0
  154. package/api/types/HashSha256.js +5 -0
  155. package/api/types/HttpMethod.d.ts +18 -0
  156. package/api/types/HttpMethod.js +17 -0
  157. package/api/types/HttpRequestPart.d.ts +13 -0
  158. package/api/types/HttpRequestPart.js +12 -0
  159. package/api/types/LabelValue.d.ts +7 -0
  160. package/api/types/LabelValue.js +5 -0
  161. package/api/types/Labels.d.ts +12 -0
  162. package/api/types/Labels.js +5 -0
  163. package/api/types/Owner.d.ts +12 -0
  164. package/api/types/Owner.js +5 -0
  165. package/api/types/OwnerField.d.ts +19 -0
  166. package/api/types/OwnerField.js +18 -0
  167. package/api/types/OwnerFilter.d.ts +18 -0
  168. package/api/types/OwnerFilter.js +5 -0
  169. package/api/types/OwnerFilterData.d.ts +8 -0
  170. package/api/types/OwnerFilterData.js +5 -0
  171. package/api/types/OwnerInput.d.ts +14 -0
  172. package/api/types/OwnerInput.js +5 -0
  173. package/api/types/OwnerList.d.ts +10 -0
  174. package/api/types/OwnerList.js +5 -0
  175. package/api/types/OwnerResource.d.ts +19 -0
  176. package/api/types/OwnerResource.js +5 -0
  177. package/api/types/OwnerSort.d.ts +11 -0
  178. package/api/types/OwnerSort.js +5 -0
  179. package/api/types/Pet.d.ts +14 -0
  180. package/api/types/Pet.js +5 -0
  181. package/api/types/PetField.d.ts +20 -0
  182. package/api/types/PetField.js +19 -0
  183. package/api/types/PetFilter.d.ts +18 -0
  184. package/api/types/PetFilter.js +5 -0
  185. package/api/types/PetFilterData.d.ts +9 -0
  186. package/api/types/PetFilterData.js +5 -0
  187. package/api/types/PetInput.d.ts +13 -0
  188. package/api/types/PetInput.js +5 -0
  189. package/api/types/PetList.d.ts +10 -0
  190. package/api/types/PetList.js +5 -0
  191. package/api/types/PetResource.d.ts +19 -0
  192. package/api/types/PetResource.js +5 -0
  193. package/api/types/PetSort.d.ts +11 -0
  194. package/api/types/PetSort.js +5 -0
  195. package/api/types/ProblemBodyContent.d.ts +23 -0
  196. package/api/types/ProblemBodyContent.js +5 -0
  197. package/api/types/ProblemForbidden.d.ts +23 -0
  198. package/api/types/ProblemForbidden.js +5 -0
  199. package/api/types/ProblemInternalServerError.d.ts +23 -0
  200. package/api/types/ProblemInternalServerError.js +5 -0
  201. package/api/types/ProblemNotFoundBlob.d.ts +24 -0
  202. package/api/types/ProblemNotFoundBlob.js +5 -0
  203. package/api/types/ProblemNotFoundResource.d.ts +24 -0
  204. package/api/types/ProblemNotFoundResource.js +5 -0
  205. package/api/types/ProblemNotFoundRevision.d.ts +24 -0
  206. package/api/types/ProblemNotFoundRevision.js +5 -0
  207. package/api/types/ProblemNullUnicode.d.ts +25 -0
  208. package/api/types/ProblemNullUnicode.js +5 -0
  209. package/api/types/ProblemResourceConflict.d.ts +25 -0
  210. package/api/types/ProblemResourceConflict.js +5 -0
  211. package/api/types/ProblemResourceMethodNotAllowed.d.ts +26 -0
  212. package/api/types/ProblemResourceMethodNotAllowed.js +5 -0
  213. package/api/types/ProblemUnauthorized.d.ts +23 -0
  214. package/api/types/ProblemUnauthorized.js +5 -0
  215. package/api/types/ProblemUnsupportedMediaType.d.ts +24 -0
  216. package/api/types/ProblemUnsupportedMediaType.js +5 -0
  217. package/api/types/ProblemValidation.d.ts +25 -0
  218. package/api/types/ProblemValidation.js +5 -0
  219. package/api/types/RequestedETag.d.ts +12 -0
  220. package/api/types/RequestedETag.js +5 -0
  221. package/api/types/RequestedRevision.d.ts +12 -0
  222. package/api/types/RequestedRevision.js +5 -0
  223. package/api/types/Resource.d.ts +33 -0
  224. package/api/types/Resource.js +5 -0
  225. package/api/types/ResourceId.d.ts +8 -0
  226. package/api/types/ResourceId.js +5 -0
  227. package/api/types/ResourceKind.d.ts +11 -0
  228. package/api/types/ResourceKind.js +5 -0
  229. package/api/types/ResourceName.d.ts +7 -0
  230. package/api/types/ResourceName.js +5 -0
  231. package/api/types/ResourceVersion.d.ts +8 -0
  232. package/api/types/ResourceVersion.js +5 -0
  233. package/api/types/Revision.d.ts +7 -0
  234. package/api/types/Revision.js +5 -0
  235. package/api/types/SortOrder.d.ts +11 -0
  236. package/api/types/SortOrder.js +10 -0
  237. package/api/types/Species.d.ts +13 -0
  238. package/api/types/Species.js +11 -0
  239. package/api/types/Timestamp.d.ts +7 -0
  240. package/api/types/Timestamp.js +5 -0
  241. package/api/types/UploadResponse.d.ts +13 -0
  242. package/api/types/UploadResponse.js +5 -0
  243. package/api/types/Uri.d.ts +12 -0
  244. package/api/types/Uri.js +5 -0
  245. package/api/types/UriReference.d.ts +7 -0
  246. package/api/types/UriReference.js +5 -0
  247. package/api/types/ValidationError.d.ts +14 -0
  248. package/api/types/ValidationError.js +5 -0
  249. package/api/types/index.d.ts +91 -0
  250. package/api/types/index.js +107 -0
  251. package/core/fetcher/APIResponse.d.ts +10 -0
  252. package/core/fetcher/APIResponse.js +2 -0
  253. package/core/fetcher/Fetcher.d.ts +35 -0
  254. package/core/fetcher/Fetcher.js +164 -0
  255. package/core/fetcher/Supplier.d.ts +4 -0
  256. package/core/fetcher/Supplier.js +22 -0
  257. package/core/fetcher/getHeader.d.ts +1 -0
  258. package/core/fetcher/getHeader.js +12 -0
  259. package/core/fetcher/index.d.ts +5 -0
  260. package/core/fetcher/index.js +9 -0
  261. package/core/index.d.ts +3 -0
  262. package/core/index.js +32 -0
  263. package/core/runtime/index.d.ts +1 -0
  264. package/core/runtime/index.js +5 -0
  265. package/core/runtime/runtime.d.ts +8 -0
  266. package/core/runtime/runtime.js +82 -0
  267. package/core/schemas/Schema.d.ts +81 -0
  268. package/core/schemas/Schema.js +21 -0
  269. package/core/schemas/builders/date/date.d.ts +2 -0
  270. package/core/schemas/builders/date/date.js +63 -0
  271. package/core/schemas/builders/date/index.d.ts +1 -0
  272. package/core/schemas/builders/date/index.js +5 -0
  273. package/core/schemas/builders/enum/enum.d.ts +2 -0
  274. package/core/schemas/builders/enum/enum.js +39 -0
  275. package/core/schemas/builders/enum/index.d.ts +1 -0
  276. package/core/schemas/builders/enum/index.js +5 -0
  277. package/core/schemas/builders/index.d.ts +13 -0
  278. package/core/schemas/builders/index.js +29 -0
  279. package/core/schemas/builders/lazy/index.d.ts +3 -0
  280. package/core/schemas/builders/lazy/index.js +7 -0
  281. package/core/schemas/builders/lazy/lazy.d.ts +5 -0
  282. package/core/schemas/builders/lazy/lazy.js +36 -0
  283. package/core/schemas/builders/lazy/lazyObject.d.ts +3 -0
  284. package/core/schemas/builders/lazy/lazyObject.js +21 -0
  285. package/core/schemas/builders/list/index.d.ts +1 -0
  286. package/core/schemas/builders/list/index.js +5 -0
  287. package/core/schemas/builders/list/list.d.ts +2 -0
  288. package/core/schemas/builders/list/list.js +68 -0
  289. package/core/schemas/builders/literals/booleanLiteral.d.ts +2 -0
  290. package/core/schemas/builders/literals/booleanLiteral.js +29 -0
  291. package/core/schemas/builders/literals/index.d.ts +2 -0
  292. package/core/schemas/builders/literals/index.js +7 -0
  293. package/core/schemas/builders/literals/stringLiteral.d.ts +2 -0
  294. package/core/schemas/builders/literals/stringLiteral.js +29 -0
  295. package/core/schemas/builders/object/index.d.ts +6 -0
  296. package/core/schemas/builders/object/index.js +11 -0
  297. package/core/schemas/builders/object/object.d.ts +3 -0
  298. package/core/schemas/builders/object/object.js +258 -0
  299. package/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +6 -0
  300. package/core/schemas/builders/object/objectWithoutOptionalProperties.js +8 -0
  301. package/core/schemas/builders/object/property.d.ts +8 -0
  302. package/core/schemas/builders/object/property.js +16 -0
  303. package/core/schemas/builders/object/types.d.ts +26 -0
  304. package/core/schemas/builders/object/types.js +2 -0
  305. package/core/schemas/builders/object-like/getObjectLikeUtils.d.ts +9 -0
  306. package/core/schemas/builders/object-like/getObjectLikeUtils.js +63 -0
  307. package/core/schemas/builders/object-like/index.d.ts +2 -0
  308. package/core/schemas/builders/object-like/index.js +6 -0
  309. package/core/schemas/builders/object-like/types.d.ts +7 -0
  310. package/core/schemas/builders/object-like/types.js +2 -0
  311. package/core/schemas/builders/primitives/any.d.ts +1 -0
  312. package/core/schemas/builders/primitives/any.js +6 -0
  313. package/core/schemas/builders/primitives/boolean.d.ts +1 -0
  314. package/core/schemas/builders/primitives/boolean.js +25 -0
  315. package/core/schemas/builders/primitives/index.d.ts +5 -0
  316. package/core/schemas/builders/primitives/index.js +13 -0
  317. package/core/schemas/builders/primitives/number.d.ts +1 -0
  318. package/core/schemas/builders/primitives/number.js +25 -0
  319. package/core/schemas/builders/primitives/string.d.ts +1 -0
  320. package/core/schemas/builders/primitives/string.js +25 -0
  321. package/core/schemas/builders/primitives/unknown.d.ts +1 -0
  322. package/core/schemas/builders/primitives/unknown.js +6 -0
  323. package/core/schemas/builders/record/index.d.ts +2 -0
  324. package/core/schemas/builders/record/index.js +5 -0
  325. package/core/schemas/builders/record/record.d.ts +3 -0
  326. package/core/schemas/builders/record/record.js +106 -0
  327. package/core/schemas/builders/record/types.d.ts +4 -0
  328. package/core/schemas/builders/record/types.js +2 -0
  329. package/core/schemas/builders/schema-utils/JsonError.d.ts +5 -0
  330. package/core/schemas/builders/schema-utils/JsonError.js +12 -0
  331. package/core/schemas/builders/schema-utils/ParseError.d.ts +5 -0
  332. package/core/schemas/builders/schema-utils/ParseError.js +12 -0
  333. package/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +17 -0
  334. package/core/schemas/builders/schema-utils/getSchemaUtils.js +85 -0
  335. package/core/schemas/builders/schema-utils/index.d.ts +4 -0
  336. package/core/schemas/builders/schema-utils/index.js +11 -0
  337. package/core/schemas/builders/schema-utils/stringifyValidationErrors.d.ts +2 -0
  338. package/core/schemas/builders/schema-utils/stringifyValidationErrors.js +10 -0
  339. package/core/schemas/builders/set/index.d.ts +1 -0
  340. package/core/schemas/builders/set/index.js +5 -0
  341. package/core/schemas/builders/set/set.d.ts +2 -0
  342. package/core/schemas/builders/set/set.js +53 -0
  343. package/core/schemas/builders/undiscriminated-union/index.d.ts +2 -0
  344. package/core/schemas/builders/undiscriminated-union/index.js +5 -0
  345. package/core/schemas/builders/undiscriminated-union/types.d.ts +4 -0
  346. package/core/schemas/builders/undiscriminated-union/types.js +2 -0
  347. package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.d.ts +3 -0
  348. package/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +51 -0
  349. package/core/schemas/builders/union/discriminant.d.ts +5 -0
  350. package/core/schemas/builders/union/discriminant.js +10 -0
  351. package/core/schemas/builders/union/index.d.ts +4 -0
  352. package/core/schemas/builders/union/index.js +7 -0
  353. package/core/schemas/builders/union/types.d.ts +13 -0
  354. package/core/schemas/builders/union/types.js +2 -0
  355. package/core/schemas/builders/union/union.d.ts +4 -0
  356. package/core/schemas/builders/union/union.js +141 -0
  357. package/core/schemas/index.d.ts +2 -0
  358. package/core/schemas/index.js +17 -0
  359. package/core/schemas/utils/MaybePromise.d.ts +1 -0
  360. package/core/schemas/utils/MaybePromise.js +2 -0
  361. package/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +7 -0
  362. package/core/schemas/utils/addQuestionMarksToNullableProperties.js +2 -0
  363. package/core/schemas/utils/createIdentitySchemaCreator.d.ts +2 -0
  364. package/core/schemas/utils/createIdentitySchemaCreator.js +16 -0
  365. package/core/schemas/utils/entries.d.ts +1 -0
  366. package/core/schemas/utils/entries.js +7 -0
  367. package/core/schemas/utils/filterObject.d.ts +1 -0
  368. package/core/schemas/utils/filterObject.js +14 -0
  369. package/core/schemas/utils/getErrorMessageForIncorrectType.d.ts +1 -0
  370. package/core/schemas/utils/getErrorMessageForIncorrectType.js +24 -0
  371. package/core/schemas/utils/isPlainObject.d.ts +1 -0
  372. package/core/schemas/utils/isPlainObject.js +18 -0
  373. package/core/schemas/utils/keys.d.ts +1 -0
  374. package/core/schemas/utils/keys.js +7 -0
  375. package/core/schemas/utils/maybeSkipValidation.d.ts +2 -0
  376. package/core/schemas/utils/maybeSkipValidation.js +37 -0
  377. package/core/schemas/utils/partition.d.ts +1 -0
  378. package/core/schemas/utils/partition.js +16 -0
  379. package/dist/Client.d.ts +25 -0
  380. package/dist/Client.js +22 -0
  381. package/dist/api/errors/BadRequestError.d.ts +8 -0
  382. package/dist/api/errors/BadRequestError.js +41 -0
  383. package/dist/api/errors/ForbiddenError.d.ts +8 -0
  384. package/dist/api/errors/ForbiddenError.js +41 -0
  385. package/dist/api/errors/InternalServerError.d.ts +8 -0
  386. package/dist/api/errors/InternalServerError.js +41 -0
  387. package/dist/api/errors/NotFoundError.d.ts +7 -0
  388. package/dist/api/errors/NotFoundError.js +41 -0
  389. package/dist/api/errors/UnauthorizedError.d.ts +8 -0
  390. package/dist/api/errors/UnauthorizedError.js +41 -0
  391. package/dist/api/errors/index.d.ts +5 -0
  392. package/dist/api/errors/index.js +21 -0
  393. package/dist/api/index.d.ts +3 -0
  394. package/dist/api/index.js +19 -0
  395. package/dist/api/resources/index.d.ts +4 -0
  396. package/dist/api/resources/index.js +33 -0
  397. package/dist/api/resources/owners/client/Client.d.ts +124 -0
  398. package/dist/api/resources/owners/client/Client.js +711 -0
  399. package/dist/api/resources/owners/client/index.d.ts +1 -0
  400. package/dist/api/resources/owners/client/index.js +17 -0
  401. package/dist/api/resources/owners/client/requests/OwnerCreateRequest.d.ts +38 -0
  402. package/dist/api/resources/owners/client/requests/OwnerCreateRequest.js +5 -0
  403. package/dist/api/resources/owners/client/requests/OwnerDeleteRequest.d.ts +49 -0
  404. package/dist/api/resources/owners/client/requests/OwnerDeleteRequest.js +5 -0
  405. package/dist/api/resources/owners/client/requests/OwnerHistoryRequest.d.ts +27 -0
  406. package/dist/api/resources/owners/client/requests/OwnerHistoryRequest.js +5 -0
  407. package/dist/api/resources/owners/client/requests/OwnerLatestRequest.d.ts +27 -0
  408. package/dist/api/resources/owners/client/requests/OwnerLatestRequest.js +5 -0
  409. package/dist/api/resources/owners/client/requests/OwnerRevisionRequest.d.ts +27 -0
  410. package/dist/api/resources/owners/client/requests/OwnerRevisionRequest.js +5 -0
  411. package/dist/api/resources/owners/client/requests/OwnerSearch.d.ts +14 -0
  412. package/dist/api/resources/owners/client/requests/OwnerSearch.js +5 -0
  413. package/dist/api/resources/owners/client/requests/OwnerUpdateRequest.d.ts +57 -0
  414. package/dist/api/resources/owners/client/requests/OwnerUpdateRequest.js +5 -0
  415. package/dist/api/resources/owners/client/requests/index.d.ts +7 -0
  416. package/dist/api/resources/owners/client/requests/index.js +2 -0
  417. package/dist/api/resources/owners/index.d.ts +1 -0
  418. package/dist/api/resources/owners/index.js +17 -0
  419. package/dist/api/resources/pets/client/Client.d.ts +133 -0
  420. package/dist/api/resources/pets/client/Client.js +861 -0
  421. package/dist/api/resources/pets/client/index.d.ts +1 -0
  422. package/dist/api/resources/pets/client/index.js +17 -0
  423. package/dist/api/resources/pets/client/requests/PetCreateRequest.d.ts +38 -0
  424. package/dist/api/resources/pets/client/requests/PetCreateRequest.js +5 -0
  425. package/dist/api/resources/pets/client/requests/PetDeleteRequest.d.ts +49 -0
  426. package/dist/api/resources/pets/client/requests/PetDeleteRequest.js +5 -0
  427. package/dist/api/resources/pets/client/requests/PetDownloadRequest.d.ts +23 -0
  428. package/dist/api/resources/pets/client/requests/PetDownloadRequest.js +5 -0
  429. package/dist/api/resources/pets/client/requests/PetHistoryRequest.d.ts +27 -0
  430. package/dist/api/resources/pets/client/requests/PetHistoryRequest.js +5 -0
  431. package/dist/api/resources/pets/client/requests/PetLatestRequest.d.ts +27 -0
  432. package/dist/api/resources/pets/client/requests/PetLatestRequest.js +5 -0
  433. package/dist/api/resources/pets/client/requests/PetRevisionRequest.d.ts +27 -0
  434. package/dist/api/resources/pets/client/requests/PetRevisionRequest.js +5 -0
  435. package/dist/api/resources/pets/client/requests/PetSearch.d.ts +14 -0
  436. package/dist/api/resources/pets/client/requests/PetSearch.js +5 -0
  437. package/dist/api/resources/pets/client/requests/PetUpdateRequest.d.ts +56 -0
  438. package/dist/api/resources/pets/client/requests/PetUpdateRequest.js +5 -0
  439. package/dist/api/resources/pets/client/requests/UploadRequest.d.ts +31 -0
  440. package/dist/api/resources/pets/client/requests/UploadRequest.js +5 -0
  441. package/dist/api/resources/pets/client/requests/index.d.ts +9 -0
  442. package/dist/api/resources/pets/client/requests/index.js +2 -0
  443. package/dist/api/resources/pets/index.d.ts +1 -0
  444. package/dist/api/resources/pets/index.js +17 -0
  445. package/dist/api/types/AnnotationValue.d.ts +7 -0
  446. package/dist/api/types/AnnotationValue.js +5 -0
  447. package/dist/api/types/Annotations.d.ts +11 -0
  448. package/dist/api/types/Annotations.js +5 -0
  449. package/dist/api/types/BadRequestErrorBody.d.ts +16 -0
  450. package/dist/api/types/BadRequestErrorBody.js +5 -0
  451. package/dist/api/types/BlobId.d.ts +8 -0
  452. package/dist/api/types/BlobId.js +5 -0
  453. package/dist/api/types/Checksum.d.ts +22 -0
  454. package/dist/api/types/Checksum.js +5 -0
  455. package/dist/api/types/ChecksumAlgorithm.d.ts +13 -0
  456. package/dist/api/types/ChecksumAlgorithm.js +12 -0
  457. package/dist/api/types/ChecksumCrc32.d.ts +10 -0
  458. package/dist/api/types/ChecksumCrc32.js +5 -0
  459. package/dist/api/types/ChecksumCrc32C.d.ts +10 -0
  460. package/dist/api/types/ChecksumCrc32C.js +5 -0
  461. package/dist/api/types/ChecksumSha1.d.ts +10 -0
  462. package/dist/api/types/ChecksumSha1.js +5 -0
  463. package/dist/api/types/ChecksumSha256.d.ts +10 -0
  464. package/dist/api/types/ChecksumSha256.js +5 -0
  465. package/dist/api/types/ContentType.d.ts +7 -0
  466. package/dist/api/types/ContentType.js +5 -0
  467. package/dist/api/types/Download.d.ts +7 -0
  468. package/dist/api/types/Download.js +5 -0
  469. package/dist/api/types/ETag.d.ts +14 -0
  470. package/dist/api/types/ETag.js +5 -0
  471. package/dist/api/types/FilterId.d.ts +22 -0
  472. package/dist/api/types/FilterId.js +5 -0
  473. package/dist/api/types/FilterIdEqual.d.ts +10 -0
  474. package/dist/api/types/FilterIdEqual.js +5 -0
  475. package/dist/api/types/FilterIdIn.d.ts +10 -0
  476. package/dist/api/types/FilterIdIn.js +5 -0
  477. package/dist/api/types/FilterIdNotEqual.d.ts +10 -0
  478. package/dist/api/types/FilterIdNotEqual.js +5 -0
  479. package/dist/api/types/FilterIdNotIn.d.ts +10 -0
  480. package/dist/api/types/FilterIdNotIn.js +5 -0
  481. package/dist/api/types/FilterInteger.d.ts +31 -0
  482. package/dist/api/types/FilterInteger.js +5 -0
  483. package/dist/api/types/FilterIntegerBetween.d.ts +12 -0
  484. package/dist/api/types/FilterIntegerBetween.js +5 -0
  485. package/dist/api/types/FilterIntegerEqual.d.ts +10 -0
  486. package/dist/api/types/FilterIntegerEqual.js +5 -0
  487. package/dist/api/types/FilterIntegerGreaterThan.d.ts +10 -0
  488. package/dist/api/types/FilterIntegerGreaterThan.js +5 -0
  489. package/dist/api/types/FilterIntegerGreaterThanOrEqual.d.ts +10 -0
  490. package/dist/api/types/FilterIntegerGreaterThanOrEqual.js +5 -0
  491. package/dist/api/types/FilterIntegerLessThan.d.ts +10 -0
  492. package/dist/api/types/FilterIntegerLessThan.js +5 -0
  493. package/dist/api/types/FilterIntegerLessThanOrEqual.d.ts +10 -0
  494. package/dist/api/types/FilterIntegerLessThanOrEqual.js +5 -0
  495. package/dist/api/types/FilterIntegerNotEqual.d.ts +10 -0
  496. package/dist/api/types/FilterIntegerNotEqual.js +5 -0
  497. package/dist/api/types/FilterString.d.ts +16 -0
  498. package/dist/api/types/FilterString.js +5 -0
  499. package/dist/api/types/FilterStringEqual.d.ts +10 -0
  500. package/dist/api/types/FilterStringEqual.js +5 -0
  501. package/dist/api/types/FilterStringNotEqual.d.ts +10 -0
  502. package/dist/api/types/FilterStringNotEqual.js +5 -0
  503. package/dist/api/types/FilterTimestamp.d.ts +31 -0
  504. package/dist/api/types/FilterTimestamp.js +5 -0
  505. package/dist/api/types/FilterTimestampBetween.d.ts +12 -0
  506. package/dist/api/types/FilterTimestampBetween.js +5 -0
  507. package/dist/api/types/FilterTimestampEqual.d.ts +10 -0
  508. package/dist/api/types/FilterTimestampEqual.js +5 -0
  509. package/dist/api/types/FilterTimestampGreaterThan.d.ts +10 -0
  510. package/dist/api/types/FilterTimestampGreaterThan.js +5 -0
  511. package/dist/api/types/FilterTimestampGreaterThanOrEqual.d.ts +10 -0
  512. package/dist/api/types/FilterTimestampGreaterThanOrEqual.js +5 -0
  513. package/dist/api/types/FilterTimestampIsNotNull.d.ts +8 -0
  514. package/dist/api/types/FilterTimestampIsNotNull.js +5 -0
  515. package/dist/api/types/FilterTimestampIsNull.d.ts +8 -0
  516. package/dist/api/types/FilterTimestampIsNull.js +5 -0
  517. package/dist/api/types/FilterTimestampLessThan.d.ts +10 -0
  518. package/dist/api/types/FilterTimestampLessThan.js +5 -0
  519. package/dist/api/types/FilterTimestampLessThanOrEqual.d.ts +10 -0
  520. package/dist/api/types/FilterTimestampLessThanOrEqual.js +5 -0
  521. package/dist/api/types/FilterTimestampNotEqual.d.ts +10 -0
  522. package/dist/api/types/FilterTimestampNotEqual.js +5 -0
  523. package/dist/api/types/FilterTimestampOptional.d.ts +38 -0
  524. package/dist/api/types/FilterTimestampOptional.js +5 -0
  525. package/dist/api/types/HashCrc32.d.ts +7 -0
  526. package/dist/api/types/HashCrc32.js +5 -0
  527. package/dist/api/types/HashCrc32C.d.ts +7 -0
  528. package/dist/api/types/HashCrc32C.js +5 -0
  529. package/dist/api/types/HashSha1.d.ts +7 -0
  530. package/dist/api/types/HashSha1.js +5 -0
  531. package/dist/api/types/HashSha256.d.ts +7 -0
  532. package/dist/api/types/HashSha256.js +5 -0
  533. package/dist/api/types/HttpMethod.d.ts +18 -0
  534. package/dist/api/types/HttpMethod.js +17 -0
  535. package/dist/api/types/HttpRequestPart.d.ts +13 -0
  536. package/dist/api/types/HttpRequestPart.js +12 -0
  537. package/dist/api/types/LabelValue.d.ts +7 -0
  538. package/dist/api/types/LabelValue.js +5 -0
  539. package/dist/api/types/Labels.d.ts +12 -0
  540. package/dist/api/types/Labels.js +5 -0
  541. package/dist/api/types/Owner.d.ts +12 -0
  542. package/dist/api/types/Owner.js +5 -0
  543. package/dist/api/types/OwnerField.d.ts +19 -0
  544. package/dist/api/types/OwnerField.js +18 -0
  545. package/dist/api/types/OwnerFilter.d.ts +18 -0
  546. package/dist/api/types/OwnerFilter.js +5 -0
  547. package/dist/api/types/OwnerFilterData.d.ts +8 -0
  548. package/dist/api/types/OwnerFilterData.js +5 -0
  549. package/dist/api/types/OwnerInput.d.ts +14 -0
  550. package/dist/api/types/OwnerInput.js +5 -0
  551. package/dist/api/types/OwnerList.d.ts +10 -0
  552. package/dist/api/types/OwnerList.js +5 -0
  553. package/dist/api/types/OwnerResource.d.ts +19 -0
  554. package/dist/api/types/OwnerResource.js +5 -0
  555. package/dist/api/types/OwnerSort.d.ts +11 -0
  556. package/dist/api/types/OwnerSort.js +5 -0
  557. package/dist/api/types/Pet.d.ts +14 -0
  558. package/dist/api/types/Pet.js +5 -0
  559. package/dist/api/types/PetField.d.ts +20 -0
  560. package/dist/api/types/PetField.js +19 -0
  561. package/dist/api/types/PetFilter.d.ts +18 -0
  562. package/dist/api/types/PetFilter.js +5 -0
  563. package/dist/api/types/PetFilterData.d.ts +9 -0
  564. package/dist/api/types/PetFilterData.js +5 -0
  565. package/dist/api/types/PetInput.d.ts +13 -0
  566. package/dist/api/types/PetInput.js +5 -0
  567. package/dist/api/types/PetList.d.ts +10 -0
  568. package/dist/api/types/PetList.js +5 -0
  569. package/dist/api/types/PetResource.d.ts +19 -0
  570. package/dist/api/types/PetResource.js +5 -0
  571. package/dist/api/types/PetSort.d.ts +11 -0
  572. package/dist/api/types/PetSort.js +5 -0
  573. package/dist/api/types/ProblemBodyContent.d.ts +23 -0
  574. package/dist/api/types/ProblemBodyContent.js +5 -0
  575. package/dist/api/types/ProblemForbidden.d.ts +23 -0
  576. package/dist/api/types/ProblemForbidden.js +5 -0
  577. package/dist/api/types/ProblemInternalServerError.d.ts +23 -0
  578. package/dist/api/types/ProblemInternalServerError.js +5 -0
  579. package/dist/api/types/ProblemNotFoundBlob.d.ts +24 -0
  580. package/dist/api/types/ProblemNotFoundBlob.js +5 -0
  581. package/dist/api/types/ProblemNotFoundResource.d.ts +24 -0
  582. package/dist/api/types/ProblemNotFoundResource.js +5 -0
  583. package/dist/api/types/ProblemNotFoundRevision.d.ts +24 -0
  584. package/dist/api/types/ProblemNotFoundRevision.js +5 -0
  585. package/dist/api/types/ProblemNullUnicode.d.ts +25 -0
  586. package/dist/api/types/ProblemNullUnicode.js +5 -0
  587. package/dist/api/types/ProblemResourceConflict.d.ts +25 -0
  588. package/dist/api/types/ProblemResourceConflict.js +5 -0
  589. package/dist/api/types/ProblemResourceMethodNotAllowed.d.ts +26 -0
  590. package/dist/api/types/ProblemResourceMethodNotAllowed.js +5 -0
  591. package/dist/api/types/ProblemUnauthorized.d.ts +23 -0
  592. package/dist/api/types/ProblemUnauthorized.js +5 -0
  593. package/dist/api/types/ProblemUnsupportedMediaType.d.ts +24 -0
  594. package/dist/api/types/ProblemUnsupportedMediaType.js +5 -0
  595. package/dist/api/types/ProblemValidation.d.ts +25 -0
  596. package/dist/api/types/ProblemValidation.js +5 -0
  597. package/dist/api/types/RequestedETag.d.ts +12 -0
  598. package/dist/api/types/RequestedETag.js +5 -0
  599. package/dist/api/types/RequestedRevision.d.ts +12 -0
  600. package/dist/api/types/RequestedRevision.js +5 -0
  601. package/dist/api/types/Resource.d.ts +33 -0
  602. package/dist/api/types/Resource.js +5 -0
  603. package/dist/api/types/ResourceId.d.ts +8 -0
  604. package/dist/api/types/ResourceId.js +5 -0
  605. package/dist/api/types/ResourceKind.d.ts +11 -0
  606. package/dist/api/types/ResourceKind.js +5 -0
  607. package/dist/api/types/ResourceName.d.ts +7 -0
  608. package/dist/api/types/ResourceName.js +5 -0
  609. package/dist/api/types/ResourceVersion.d.ts +8 -0
  610. package/dist/api/types/ResourceVersion.js +5 -0
  611. package/dist/api/types/Revision.d.ts +7 -0
  612. package/dist/api/types/Revision.js +5 -0
  613. package/dist/api/types/SortOrder.d.ts +11 -0
  614. package/dist/api/types/SortOrder.js +10 -0
  615. package/dist/api/types/Species.d.ts +13 -0
  616. package/dist/api/types/Species.js +11 -0
  617. package/dist/api/types/Timestamp.d.ts +7 -0
  618. package/dist/api/types/Timestamp.js +5 -0
  619. package/dist/api/types/UploadResponse.d.ts +13 -0
  620. package/dist/api/types/UploadResponse.js +5 -0
  621. package/dist/api/types/Uri.d.ts +12 -0
  622. package/dist/api/types/Uri.js +5 -0
  623. package/dist/api/types/UriReference.d.ts +7 -0
  624. package/dist/api/types/UriReference.js +5 -0
  625. package/dist/api/types/ValidationError.d.ts +14 -0
  626. package/dist/api/types/ValidationError.js +5 -0
  627. package/dist/api/types/index.d.ts +91 -0
  628. package/dist/api/types/index.js +107 -0
  629. package/dist/core/fetcher/APIResponse.d.ts +10 -0
  630. package/dist/core/fetcher/APIResponse.js +2 -0
  631. package/dist/core/fetcher/Fetcher.d.ts +35 -0
  632. package/dist/core/fetcher/Fetcher.js +164 -0
  633. package/dist/core/fetcher/Supplier.d.ts +4 -0
  634. package/dist/core/fetcher/Supplier.js +22 -0
  635. package/dist/core/fetcher/getHeader.d.ts +1 -0
  636. package/dist/core/fetcher/getHeader.js +12 -0
  637. package/dist/core/fetcher/index.d.ts +5 -0
  638. package/dist/core/fetcher/index.js +9 -0
  639. package/dist/core/index.d.ts +3 -0
  640. package/dist/core/index.js +32 -0
  641. package/dist/core/runtime/index.d.ts +1 -0
  642. package/dist/core/runtime/index.js +5 -0
  643. package/dist/core/runtime/runtime.d.ts +8 -0
  644. package/dist/core/runtime/runtime.js +82 -0
  645. package/dist/core/schemas/Schema.d.ts +81 -0
  646. package/dist/core/schemas/Schema.js +21 -0
  647. package/dist/core/schemas/builders/date/date.d.ts +2 -0
  648. package/dist/core/schemas/builders/date/date.js +63 -0
  649. package/dist/core/schemas/builders/date/index.d.ts +1 -0
  650. package/dist/core/schemas/builders/date/index.js +5 -0
  651. package/dist/core/schemas/builders/enum/enum.d.ts +2 -0
  652. package/dist/core/schemas/builders/enum/enum.js +39 -0
  653. package/dist/core/schemas/builders/enum/index.d.ts +1 -0
  654. package/dist/core/schemas/builders/enum/index.js +5 -0
  655. package/dist/core/schemas/builders/index.d.ts +13 -0
  656. package/dist/core/schemas/builders/index.js +29 -0
  657. package/dist/core/schemas/builders/lazy/index.d.ts +3 -0
  658. package/dist/core/schemas/builders/lazy/index.js +7 -0
  659. package/dist/core/schemas/builders/lazy/lazy.d.ts +5 -0
  660. package/dist/core/schemas/builders/lazy/lazy.js +36 -0
  661. package/dist/core/schemas/builders/lazy/lazyObject.d.ts +3 -0
  662. package/dist/core/schemas/builders/lazy/lazyObject.js +21 -0
  663. package/dist/core/schemas/builders/list/index.d.ts +1 -0
  664. package/dist/core/schemas/builders/list/index.js +5 -0
  665. package/dist/core/schemas/builders/list/list.d.ts +2 -0
  666. package/dist/core/schemas/builders/list/list.js +68 -0
  667. package/dist/core/schemas/builders/literals/booleanLiteral.d.ts +2 -0
  668. package/dist/core/schemas/builders/literals/booleanLiteral.js +29 -0
  669. package/dist/core/schemas/builders/literals/index.d.ts +2 -0
  670. package/dist/core/schemas/builders/literals/index.js +7 -0
  671. package/dist/core/schemas/builders/literals/stringLiteral.d.ts +2 -0
  672. package/dist/core/schemas/builders/literals/stringLiteral.js +29 -0
  673. package/dist/core/schemas/builders/object/index.d.ts +6 -0
  674. package/dist/core/schemas/builders/object/index.js +11 -0
  675. package/dist/core/schemas/builders/object/object.d.ts +3 -0
  676. package/dist/core/schemas/builders/object/object.js +258 -0
  677. package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.d.ts +6 -0
  678. package/dist/core/schemas/builders/object/objectWithoutOptionalProperties.js +8 -0
  679. package/dist/core/schemas/builders/object/property.d.ts +8 -0
  680. package/dist/core/schemas/builders/object/property.js +16 -0
  681. package/dist/core/schemas/builders/object/types.d.ts +26 -0
  682. package/dist/core/schemas/builders/object/types.js +2 -0
  683. package/dist/core/schemas/builders/object-like/getObjectLikeUtils.d.ts +9 -0
  684. package/dist/core/schemas/builders/object-like/getObjectLikeUtils.js +63 -0
  685. package/dist/core/schemas/builders/object-like/index.d.ts +2 -0
  686. package/dist/core/schemas/builders/object-like/index.js +6 -0
  687. package/dist/core/schemas/builders/object-like/types.d.ts +7 -0
  688. package/dist/core/schemas/builders/object-like/types.js +2 -0
  689. package/dist/core/schemas/builders/primitives/any.d.ts +1 -0
  690. package/dist/core/schemas/builders/primitives/any.js +6 -0
  691. package/dist/core/schemas/builders/primitives/boolean.d.ts +1 -0
  692. package/dist/core/schemas/builders/primitives/boolean.js +25 -0
  693. package/dist/core/schemas/builders/primitives/index.d.ts +5 -0
  694. package/dist/core/schemas/builders/primitives/index.js +13 -0
  695. package/dist/core/schemas/builders/primitives/number.d.ts +1 -0
  696. package/dist/core/schemas/builders/primitives/number.js +25 -0
  697. package/dist/core/schemas/builders/primitives/string.d.ts +1 -0
  698. package/dist/core/schemas/builders/primitives/string.js +25 -0
  699. package/dist/core/schemas/builders/primitives/unknown.d.ts +1 -0
  700. package/dist/core/schemas/builders/primitives/unknown.js +6 -0
  701. package/dist/core/schemas/builders/record/index.d.ts +2 -0
  702. package/dist/core/schemas/builders/record/index.js +5 -0
  703. package/dist/core/schemas/builders/record/record.d.ts +3 -0
  704. package/dist/core/schemas/builders/record/record.js +106 -0
  705. package/dist/core/schemas/builders/record/types.d.ts +4 -0
  706. package/dist/core/schemas/builders/record/types.js +2 -0
  707. package/dist/core/schemas/builders/schema-utils/JsonError.d.ts +5 -0
  708. package/dist/core/schemas/builders/schema-utils/JsonError.js +12 -0
  709. package/dist/core/schemas/builders/schema-utils/ParseError.d.ts +5 -0
  710. package/dist/core/schemas/builders/schema-utils/ParseError.js +12 -0
  711. package/dist/core/schemas/builders/schema-utils/getSchemaUtils.d.ts +17 -0
  712. package/dist/core/schemas/builders/schema-utils/getSchemaUtils.js +85 -0
  713. package/dist/core/schemas/builders/schema-utils/index.d.ts +4 -0
  714. package/dist/core/schemas/builders/schema-utils/index.js +11 -0
  715. package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.d.ts +2 -0
  716. package/dist/core/schemas/builders/schema-utils/stringifyValidationErrors.js +10 -0
  717. package/dist/core/schemas/builders/set/index.d.ts +1 -0
  718. package/dist/core/schemas/builders/set/index.js +5 -0
  719. package/dist/core/schemas/builders/set/set.d.ts +2 -0
  720. package/dist/core/schemas/builders/set/set.js +53 -0
  721. package/dist/core/schemas/builders/undiscriminated-union/index.d.ts +2 -0
  722. package/dist/core/schemas/builders/undiscriminated-union/index.js +5 -0
  723. package/dist/core/schemas/builders/undiscriminated-union/types.d.ts +4 -0
  724. package/dist/core/schemas/builders/undiscriminated-union/types.js +2 -0
  725. package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.d.ts +3 -0
  726. package/dist/core/schemas/builders/undiscriminated-union/undiscriminatedUnion.js +51 -0
  727. package/dist/core/schemas/builders/union/discriminant.d.ts +5 -0
  728. package/dist/core/schemas/builders/union/discriminant.js +10 -0
  729. package/dist/core/schemas/builders/union/index.d.ts +4 -0
  730. package/dist/core/schemas/builders/union/index.js +7 -0
  731. package/dist/core/schemas/builders/union/types.d.ts +13 -0
  732. package/dist/core/schemas/builders/union/types.js +2 -0
  733. package/dist/core/schemas/builders/union/union.d.ts +4 -0
  734. package/dist/core/schemas/builders/union/union.js +141 -0
  735. package/dist/core/schemas/index.d.ts +2 -0
  736. package/dist/core/schemas/index.js +17 -0
  737. package/dist/core/schemas/utils/MaybePromise.d.ts +1 -0
  738. package/dist/core/schemas/utils/MaybePromise.js +2 -0
  739. package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.d.ts +7 -0
  740. package/dist/core/schemas/utils/addQuestionMarksToNullableProperties.js +2 -0
  741. package/dist/core/schemas/utils/createIdentitySchemaCreator.d.ts +2 -0
  742. package/dist/core/schemas/utils/createIdentitySchemaCreator.js +16 -0
  743. package/dist/core/schemas/utils/entries.d.ts +1 -0
  744. package/dist/core/schemas/utils/entries.js +7 -0
  745. package/dist/core/schemas/utils/filterObject.d.ts +1 -0
  746. package/dist/core/schemas/utils/filterObject.js +14 -0
  747. package/dist/core/schemas/utils/getErrorMessageForIncorrectType.d.ts +1 -0
  748. package/dist/core/schemas/utils/getErrorMessageForIncorrectType.js +24 -0
  749. package/dist/core/schemas/utils/isPlainObject.d.ts +1 -0
  750. package/dist/core/schemas/utils/isPlainObject.js +18 -0
  751. package/dist/core/schemas/utils/keys.d.ts +1 -0
  752. package/dist/core/schemas/utils/keys.js +7 -0
  753. package/dist/core/schemas/utils/maybeSkipValidation.d.ts +2 -0
  754. package/dist/core/schemas/utils/maybeSkipValidation.js +37 -0
  755. package/dist/core/schemas/utils/partition.d.ts +1 -0
  756. package/dist/core/schemas/utils/partition.js +16 -0
  757. package/dist/environments.d.ts +7 -0
  758. package/dist/environments.js +9 -0
  759. package/dist/errors/TruvityError.d.ts +12 -0
  760. package/dist/errors/TruvityError.js +32 -0
  761. package/dist/errors/TruvityTimeoutError.d.ts +6 -0
  762. package/dist/errors/TruvityTimeoutError.js +13 -0
  763. package/dist/errors/index.d.ts +2 -0
  764. package/dist/errors/index.js +7 -0
  765. package/dist/index.d.ts +4 -0
  766. package/dist/index.js +34 -0
  767. package/dist/serialization/index.d.ts +2 -0
  768. package/dist/serialization/index.js +18 -0
  769. package/dist/serialization/resources/index.d.ts +4 -0
  770. package/dist/serialization/resources/index.js +33 -0
  771. package/dist/serialization/resources/owners/client/index.d.ts +1 -0
  772. package/dist/serialization/resources/owners/client/index.js +17 -0
  773. package/dist/serialization/resources/owners/client/requests/OwnerSearch.d.ts +13 -0
  774. package/dist/serialization/resources/owners/client/requests/OwnerSearch.js +47 -0
  775. package/dist/serialization/resources/owners/client/requests/index.d.ts +1 -0
  776. package/dist/serialization/resources/owners/client/requests/index.js +5 -0
  777. package/dist/serialization/resources/owners/index.d.ts +1 -0
  778. package/dist/serialization/resources/owners/index.js +17 -0
  779. package/dist/serialization/resources/pets/client/index.d.ts +1 -0
  780. package/dist/serialization/resources/pets/client/index.js +17 -0
  781. package/dist/serialization/resources/pets/client/requests/PetSearch.d.ts +13 -0
  782. package/dist/serialization/resources/pets/client/requests/PetSearch.js +47 -0
  783. package/dist/serialization/resources/pets/client/requests/UploadRequest.d.ts +12 -0
  784. package/dist/serialization/resources/pets/client/requests/UploadRequest.js +42 -0
  785. package/dist/serialization/resources/pets/client/requests/index.d.ts +2 -0
  786. package/dist/serialization/resources/pets/client/requests/index.js +7 -0
  787. package/dist/serialization/resources/pets/index.d.ts +1 -0
  788. package/dist/serialization/resources/pets/index.js +17 -0
  789. package/dist/serialization/types/AnnotationValue.d.ts +10 -0
  790. package/dist/serialization/types/AnnotationValue.js +31 -0
  791. package/dist/serialization/types/Annotations.d.ts +10 -0
  792. package/dist/serialization/types/Annotations.js +40 -0
  793. package/dist/serialization/types/BadRequestErrorBody.d.ts +19 -0
  794. package/dist/serialization/types/BadRequestErrorBody.js +49 -0
  795. package/dist/serialization/types/BlobId.d.ts +10 -0
  796. package/dist/serialization/types/BlobId.js +31 -0
  797. package/dist/serialization/types/Checksum.d.ts +22 -0
  798. package/dist/serialization/types/Checksum.js +50 -0
  799. package/dist/serialization/types/ChecksumAlgorithm.d.ts +10 -0
  800. package/dist/serialization/types/ChecksumAlgorithm.js +31 -0
  801. package/dist/serialization/types/ChecksumCrc32.d.ts +12 -0
  802. package/dist/serialization/types/ChecksumCrc32.js +42 -0
  803. package/dist/serialization/types/ChecksumCrc32C.d.ts +12 -0
  804. package/dist/serialization/types/ChecksumCrc32C.js +42 -0
  805. package/dist/serialization/types/ChecksumSha1.d.ts +12 -0
  806. package/dist/serialization/types/ChecksumSha1.js +42 -0
  807. package/dist/serialization/types/ChecksumSha256.d.ts +12 -0
  808. package/dist/serialization/types/ChecksumSha256.js +42 -0
  809. package/dist/serialization/types/ContentType.d.ts +10 -0
  810. package/dist/serialization/types/ContentType.js +31 -0
  811. package/dist/serialization/types/Download.d.ts +10 -0
  812. package/dist/serialization/types/Download.js +31 -0
  813. package/dist/serialization/types/ETag.d.ts +10 -0
  814. package/dist/serialization/types/ETag.js +31 -0
  815. package/dist/serialization/types/FilterId.d.ts +22 -0
  816. package/dist/serialization/types/FilterId.js +50 -0
  817. package/dist/serialization/types/FilterIdEqual.d.ts +12 -0
  818. package/dist/serialization/types/FilterIdEqual.js +33 -0
  819. package/dist/serialization/types/FilterIdIn.d.ts +12 -0
  820. package/dist/serialization/types/FilterIdIn.js +33 -0
  821. package/dist/serialization/types/FilterIdNotEqual.d.ts +12 -0
  822. package/dist/serialization/types/FilterIdNotEqual.js +33 -0
  823. package/dist/serialization/types/FilterIdNotIn.d.ts +12 -0
  824. package/dist/serialization/types/FilterIdNotIn.js +33 -0
  825. package/dist/serialization/types/FilterInteger.d.ts +31 -0
  826. package/dist/serialization/types/FilterInteger.js +53 -0
  827. package/dist/serialization/types/FilterIntegerBetween.d.ts +13 -0
  828. package/dist/serialization/types/FilterIntegerBetween.js +34 -0
  829. package/dist/serialization/types/FilterIntegerEqual.d.ts +12 -0
  830. package/dist/serialization/types/FilterIntegerEqual.js +33 -0
  831. package/dist/serialization/types/FilterIntegerGreaterThan.d.ts +12 -0
  832. package/dist/serialization/types/FilterIntegerGreaterThan.js +33 -0
  833. package/dist/serialization/types/FilterIntegerGreaterThanOrEqual.d.ts +12 -0
  834. package/dist/serialization/types/FilterIntegerGreaterThanOrEqual.js +33 -0
  835. package/dist/serialization/types/FilterIntegerLessThan.d.ts +12 -0
  836. package/dist/serialization/types/FilterIntegerLessThan.js +33 -0
  837. package/dist/serialization/types/FilterIntegerLessThanOrEqual.d.ts +12 -0
  838. package/dist/serialization/types/FilterIntegerLessThanOrEqual.js +33 -0
  839. package/dist/serialization/types/FilterIntegerNotEqual.d.ts +12 -0
  840. package/dist/serialization/types/FilterIntegerNotEqual.js +33 -0
  841. package/dist/serialization/types/FilterString.d.ts +16 -0
  842. package/dist/serialization/types/FilterString.js +48 -0
  843. package/dist/serialization/types/FilterStringEqual.d.ts +12 -0
  844. package/dist/serialization/types/FilterStringEqual.js +33 -0
  845. package/dist/serialization/types/FilterStringNotEqual.d.ts +12 -0
  846. package/dist/serialization/types/FilterStringNotEqual.js +33 -0
  847. package/dist/serialization/types/FilterTimestamp.d.ts +31 -0
  848. package/dist/serialization/types/FilterTimestamp.js +53 -0
  849. package/dist/serialization/types/FilterTimestampBetween.d.ts +13 -0
  850. package/dist/serialization/types/FilterTimestampBetween.js +34 -0
  851. package/dist/serialization/types/FilterTimestampEqual.d.ts +12 -0
  852. package/dist/serialization/types/FilterTimestampEqual.js +33 -0
  853. package/dist/serialization/types/FilterTimestampGreaterThan.d.ts +12 -0
  854. package/dist/serialization/types/FilterTimestampGreaterThan.js +33 -0
  855. package/dist/serialization/types/FilterTimestampGreaterThanOrEqual.d.ts +12 -0
  856. package/dist/serialization/types/FilterTimestampGreaterThanOrEqual.js +33 -0
  857. package/dist/serialization/types/FilterTimestampIsNotNull.d.ts +11 -0
  858. package/dist/serialization/types/FilterTimestampIsNotNull.js +31 -0
  859. package/dist/serialization/types/FilterTimestampIsNull.d.ts +11 -0
  860. package/dist/serialization/types/FilterTimestampIsNull.js +31 -0
  861. package/dist/serialization/types/FilterTimestampLessThan.d.ts +12 -0
  862. package/dist/serialization/types/FilterTimestampLessThan.js +33 -0
  863. package/dist/serialization/types/FilterTimestampLessThanOrEqual.d.ts +12 -0
  864. package/dist/serialization/types/FilterTimestampLessThanOrEqual.js +33 -0
  865. package/dist/serialization/types/FilterTimestampNotEqual.d.ts +12 -0
  866. package/dist/serialization/types/FilterTimestampNotEqual.js +33 -0
  867. package/dist/serialization/types/FilterTimestampOptional.d.ts +37 -0
  868. package/dist/serialization/types/FilterTimestampOptional.js +55 -0
  869. package/dist/serialization/types/HashCrc32.d.ts +10 -0
  870. package/dist/serialization/types/HashCrc32.js +31 -0
  871. package/dist/serialization/types/HashCrc32C.d.ts +10 -0
  872. package/dist/serialization/types/HashCrc32C.js +31 -0
  873. package/dist/serialization/types/HashSha1.d.ts +10 -0
  874. package/dist/serialization/types/HashSha1.js +31 -0
  875. package/dist/serialization/types/HashSha256.d.ts +10 -0
  876. package/dist/serialization/types/HashSha256.js +31 -0
  877. package/dist/serialization/types/HttpMethod.d.ts +10 -0
  878. package/dist/serialization/types/HttpMethod.js +31 -0
  879. package/dist/serialization/types/HttpRequestPart.d.ts +10 -0
  880. package/dist/serialization/types/HttpRequestPart.js +31 -0
  881. package/dist/serialization/types/LabelValue.d.ts +10 -0
  882. package/dist/serialization/types/LabelValue.js +31 -0
  883. package/dist/serialization/types/Labels.d.ts +10 -0
  884. package/dist/serialization/types/Labels.js +40 -0
  885. package/dist/serialization/types/Owner.d.ts +13 -0
  886. package/dist/serialization/types/Owner.js +34 -0
  887. package/dist/serialization/types/OwnerField.d.ts +10 -0
  888. package/dist/serialization/types/OwnerField.js +42 -0
  889. package/dist/serialization/types/OwnerFilter.d.ts +20 -0
  890. package/dist/serialization/types/OwnerFilter.js +50 -0
  891. package/dist/serialization/types/OwnerFilterData.d.ts +13 -0
  892. package/dist/serialization/types/OwnerFilterData.js +43 -0
  893. package/dist/serialization/types/OwnerInput.d.ts +14 -0
  894. package/dist/serialization/types/OwnerInput.js +44 -0
  895. package/dist/serialization/types/OwnerList.d.ts +12 -0
  896. package/dist/serialization/types/OwnerList.js +42 -0
  897. package/dist/serialization/types/OwnerResource.d.ts +21 -0
  898. package/dist/serialization/types/OwnerResource.js +51 -0
  899. package/dist/serialization/types/OwnerSort.d.ts +13 -0
  900. package/dist/serialization/types/OwnerSort.js +43 -0
  901. package/dist/serialization/types/Pet.d.ts +14 -0
  902. package/dist/serialization/types/Pet.js +44 -0
  903. package/dist/serialization/types/PetField.d.ts +10 -0
  904. package/dist/serialization/types/PetField.js +43 -0
  905. package/dist/serialization/types/PetFilter.d.ts +20 -0
  906. package/dist/serialization/types/PetFilter.js +50 -0
  907. package/dist/serialization/types/PetFilterData.d.ts +14 -0
  908. package/dist/serialization/types/PetFilterData.js +44 -0
  909. package/dist/serialization/types/PetInput.d.ts +13 -0
  910. package/dist/serialization/types/PetInput.js +43 -0
  911. package/dist/serialization/types/PetList.d.ts +12 -0
  912. package/dist/serialization/types/PetList.js +42 -0
  913. package/dist/serialization/types/PetResource.d.ts +21 -0
  914. package/dist/serialization/types/PetResource.js +51 -0
  915. package/dist/serialization/types/PetSort.d.ts +13 -0
  916. package/dist/serialization/types/PetSort.js +43 -0
  917. package/dist/serialization/types/ProblemBodyContent.d.ts +16 -0
  918. package/dist/serialization/types/ProblemBodyContent.js +46 -0
  919. package/dist/serialization/types/ProblemForbidden.d.ts +16 -0
  920. package/dist/serialization/types/ProblemForbidden.js +46 -0
  921. package/dist/serialization/types/ProblemInternalServerError.d.ts +16 -0
  922. package/dist/serialization/types/ProblemInternalServerError.js +46 -0
  923. package/dist/serialization/types/ProblemNotFoundBlob.d.ts +17 -0
  924. package/dist/serialization/types/ProblemNotFoundBlob.js +47 -0
  925. package/dist/serialization/types/ProblemNotFoundResource.d.ts +17 -0
  926. package/dist/serialization/types/ProblemNotFoundResource.js +47 -0
  927. package/dist/serialization/types/ProblemNotFoundRevision.d.ts +17 -0
  928. package/dist/serialization/types/ProblemNotFoundRevision.js +47 -0
  929. package/dist/serialization/types/ProblemNullUnicode.d.ts +17 -0
  930. package/dist/serialization/types/ProblemNullUnicode.js +47 -0
  931. package/dist/serialization/types/ProblemResourceConflict.d.ts +18 -0
  932. package/dist/serialization/types/ProblemResourceConflict.js +48 -0
  933. package/dist/serialization/types/ProblemResourceMethodNotAllowed.d.ts +19 -0
  934. package/dist/serialization/types/ProblemResourceMethodNotAllowed.js +49 -0
  935. package/dist/serialization/types/ProblemUnauthorized.d.ts +16 -0
  936. package/dist/serialization/types/ProblemUnauthorized.js +46 -0
  937. package/dist/serialization/types/ProblemUnsupportedMediaType.d.ts +17 -0
  938. package/dist/serialization/types/ProblemUnsupportedMediaType.js +47 -0
  939. package/dist/serialization/types/ProblemValidation.d.ts +18 -0
  940. package/dist/serialization/types/ProblemValidation.js +48 -0
  941. package/dist/serialization/types/RequestedETag.d.ts +14 -0
  942. package/dist/serialization/types/RequestedETag.js +44 -0
  943. package/dist/serialization/types/RequestedRevision.d.ts +14 -0
  944. package/dist/serialization/types/RequestedRevision.js +44 -0
  945. package/dist/serialization/types/Resource.d.ts +20 -0
  946. package/dist/serialization/types/Resource.js +50 -0
  947. package/dist/serialization/types/ResourceId.d.ts +10 -0
  948. package/dist/serialization/types/ResourceId.js +31 -0
  949. package/dist/serialization/types/ResourceKind.d.ts +13 -0
  950. package/dist/serialization/types/ResourceKind.js +43 -0
  951. package/dist/serialization/types/ResourceName.d.ts +10 -0
  952. package/dist/serialization/types/ResourceName.js +31 -0
  953. package/dist/serialization/types/ResourceVersion.d.ts +10 -0
  954. package/dist/serialization/types/ResourceVersion.js +31 -0
  955. package/dist/serialization/types/Revision.d.ts +10 -0
  956. package/dist/serialization/types/Revision.js +31 -0
  957. package/dist/serialization/types/SortOrder.d.ts +10 -0
  958. package/dist/serialization/types/SortOrder.js +31 -0
  959. package/dist/serialization/types/Species.d.ts +10 -0
  960. package/dist/serialization/types/Species.js +35 -0
  961. package/dist/serialization/types/Timestamp.d.ts +10 -0
  962. package/dist/serialization/types/Timestamp.js +31 -0
  963. package/dist/serialization/types/UploadResponse.d.ts +15 -0
  964. package/dist/serialization/types/UploadResponse.js +45 -0
  965. package/dist/serialization/types/Uri.d.ts +10 -0
  966. package/dist/serialization/types/Uri.js +31 -0
  967. package/dist/serialization/types/UriReference.d.ts +10 -0
  968. package/dist/serialization/types/UriReference.js +31 -0
  969. package/dist/serialization/types/ValidationError.d.ts +14 -0
  970. package/dist/serialization/types/ValidationError.js +46 -0
  971. package/dist/serialization/types/index.d.ts +91 -0
  972. package/dist/serialization/types/index.js +107 -0
  973. package/environments.d.ts +7 -0
  974. package/environments.js +9 -0
  975. package/errors/TruvityError.d.ts +12 -0
  976. package/errors/TruvityError.js +32 -0
  977. package/errors/TruvityTimeoutError.d.ts +6 -0
  978. package/errors/TruvityTimeoutError.js +13 -0
  979. package/errors/index.d.ts +2 -0
  980. package/errors/index.js +7 -0
  981. package/index.d.ts +4 -0
  982. package/index.js +34 -0
  983. package/jest.config.js +5 -0
  984. package/package.json +31 -0
  985. package/serialization/index.d.ts +2 -0
  986. package/serialization/index.js +18 -0
  987. package/serialization/resources/index.d.ts +4 -0
  988. package/serialization/resources/index.js +33 -0
  989. package/serialization/resources/owners/client/index.d.ts +1 -0
  990. package/serialization/resources/owners/client/index.js +17 -0
  991. package/serialization/resources/owners/client/requests/OwnerSearch.d.ts +13 -0
  992. package/serialization/resources/owners/client/requests/OwnerSearch.js +47 -0
  993. package/serialization/resources/owners/client/requests/index.d.ts +1 -0
  994. package/serialization/resources/owners/client/requests/index.js +5 -0
  995. package/serialization/resources/owners/index.d.ts +1 -0
  996. package/serialization/resources/owners/index.js +17 -0
  997. package/serialization/resources/pets/client/index.d.ts +1 -0
  998. package/serialization/resources/pets/client/index.js +17 -0
  999. package/serialization/resources/pets/client/requests/PetSearch.d.ts +13 -0
  1000. package/serialization/resources/pets/client/requests/PetSearch.js +47 -0
  1001. package/serialization/resources/pets/client/requests/UploadRequest.d.ts +12 -0
  1002. package/serialization/resources/pets/client/requests/UploadRequest.js +42 -0
  1003. package/serialization/resources/pets/client/requests/index.d.ts +2 -0
  1004. package/serialization/resources/pets/client/requests/index.js +7 -0
  1005. package/serialization/resources/pets/index.d.ts +1 -0
  1006. package/serialization/resources/pets/index.js +17 -0
  1007. package/serialization/types/AnnotationValue.d.ts +10 -0
  1008. package/serialization/types/AnnotationValue.js +31 -0
  1009. package/serialization/types/Annotations.d.ts +10 -0
  1010. package/serialization/types/Annotations.js +40 -0
  1011. package/serialization/types/BadRequestErrorBody.d.ts +19 -0
  1012. package/serialization/types/BadRequestErrorBody.js +49 -0
  1013. package/serialization/types/BlobId.d.ts +10 -0
  1014. package/serialization/types/BlobId.js +31 -0
  1015. package/serialization/types/Checksum.d.ts +22 -0
  1016. package/serialization/types/Checksum.js +50 -0
  1017. package/serialization/types/ChecksumAlgorithm.d.ts +10 -0
  1018. package/serialization/types/ChecksumAlgorithm.js +31 -0
  1019. package/serialization/types/ChecksumCrc32.d.ts +12 -0
  1020. package/serialization/types/ChecksumCrc32.js +42 -0
  1021. package/serialization/types/ChecksumCrc32C.d.ts +12 -0
  1022. package/serialization/types/ChecksumCrc32C.js +42 -0
  1023. package/serialization/types/ChecksumSha1.d.ts +12 -0
  1024. package/serialization/types/ChecksumSha1.js +42 -0
  1025. package/serialization/types/ChecksumSha256.d.ts +12 -0
  1026. package/serialization/types/ChecksumSha256.js +42 -0
  1027. package/serialization/types/ContentType.d.ts +10 -0
  1028. package/serialization/types/ContentType.js +31 -0
  1029. package/serialization/types/Download.d.ts +10 -0
  1030. package/serialization/types/Download.js +31 -0
  1031. package/serialization/types/ETag.d.ts +10 -0
  1032. package/serialization/types/ETag.js +31 -0
  1033. package/serialization/types/FilterId.d.ts +22 -0
  1034. package/serialization/types/FilterId.js +50 -0
  1035. package/serialization/types/FilterIdEqual.d.ts +12 -0
  1036. package/serialization/types/FilterIdEqual.js +33 -0
  1037. package/serialization/types/FilterIdIn.d.ts +12 -0
  1038. package/serialization/types/FilterIdIn.js +33 -0
  1039. package/serialization/types/FilterIdNotEqual.d.ts +12 -0
  1040. package/serialization/types/FilterIdNotEqual.js +33 -0
  1041. package/serialization/types/FilterIdNotIn.d.ts +12 -0
  1042. package/serialization/types/FilterIdNotIn.js +33 -0
  1043. package/serialization/types/FilterInteger.d.ts +31 -0
  1044. package/serialization/types/FilterInteger.js +53 -0
  1045. package/serialization/types/FilterIntegerBetween.d.ts +13 -0
  1046. package/serialization/types/FilterIntegerBetween.js +34 -0
  1047. package/serialization/types/FilterIntegerEqual.d.ts +12 -0
  1048. package/serialization/types/FilterIntegerEqual.js +33 -0
  1049. package/serialization/types/FilterIntegerGreaterThan.d.ts +12 -0
  1050. package/serialization/types/FilterIntegerGreaterThan.js +33 -0
  1051. package/serialization/types/FilterIntegerGreaterThanOrEqual.d.ts +12 -0
  1052. package/serialization/types/FilterIntegerGreaterThanOrEqual.js +33 -0
  1053. package/serialization/types/FilterIntegerLessThan.d.ts +12 -0
  1054. package/serialization/types/FilterIntegerLessThan.js +33 -0
  1055. package/serialization/types/FilterIntegerLessThanOrEqual.d.ts +12 -0
  1056. package/serialization/types/FilterIntegerLessThanOrEqual.js +33 -0
  1057. package/serialization/types/FilterIntegerNotEqual.d.ts +12 -0
  1058. package/serialization/types/FilterIntegerNotEqual.js +33 -0
  1059. package/serialization/types/FilterString.d.ts +16 -0
  1060. package/serialization/types/FilterString.js +48 -0
  1061. package/serialization/types/FilterStringEqual.d.ts +12 -0
  1062. package/serialization/types/FilterStringEqual.js +33 -0
  1063. package/serialization/types/FilterStringNotEqual.d.ts +12 -0
  1064. package/serialization/types/FilterStringNotEqual.js +33 -0
  1065. package/serialization/types/FilterTimestamp.d.ts +31 -0
  1066. package/serialization/types/FilterTimestamp.js +53 -0
  1067. package/serialization/types/FilterTimestampBetween.d.ts +13 -0
  1068. package/serialization/types/FilterTimestampBetween.js +34 -0
  1069. package/serialization/types/FilterTimestampEqual.d.ts +12 -0
  1070. package/serialization/types/FilterTimestampEqual.js +33 -0
  1071. package/serialization/types/FilterTimestampGreaterThan.d.ts +12 -0
  1072. package/serialization/types/FilterTimestampGreaterThan.js +33 -0
  1073. package/serialization/types/FilterTimestampGreaterThanOrEqual.d.ts +12 -0
  1074. package/serialization/types/FilterTimestampGreaterThanOrEqual.js +33 -0
  1075. package/serialization/types/FilterTimestampIsNotNull.d.ts +11 -0
  1076. package/serialization/types/FilterTimestampIsNotNull.js +31 -0
  1077. package/serialization/types/FilterTimestampIsNull.d.ts +11 -0
  1078. package/serialization/types/FilterTimestampIsNull.js +31 -0
  1079. package/serialization/types/FilterTimestampLessThan.d.ts +12 -0
  1080. package/serialization/types/FilterTimestampLessThan.js +33 -0
  1081. package/serialization/types/FilterTimestampLessThanOrEqual.d.ts +12 -0
  1082. package/serialization/types/FilterTimestampLessThanOrEqual.js +33 -0
  1083. package/serialization/types/FilterTimestampNotEqual.d.ts +12 -0
  1084. package/serialization/types/FilterTimestampNotEqual.js +33 -0
  1085. package/serialization/types/FilterTimestampOptional.d.ts +37 -0
  1086. package/serialization/types/FilterTimestampOptional.js +55 -0
  1087. package/serialization/types/HashCrc32.d.ts +10 -0
  1088. package/serialization/types/HashCrc32.js +31 -0
  1089. package/serialization/types/HashCrc32C.d.ts +10 -0
  1090. package/serialization/types/HashCrc32C.js +31 -0
  1091. package/serialization/types/HashSha1.d.ts +10 -0
  1092. package/serialization/types/HashSha1.js +31 -0
  1093. package/serialization/types/HashSha256.d.ts +10 -0
  1094. package/serialization/types/HashSha256.js +31 -0
  1095. package/serialization/types/HttpMethod.d.ts +10 -0
  1096. package/serialization/types/HttpMethod.js +31 -0
  1097. package/serialization/types/HttpRequestPart.d.ts +10 -0
  1098. package/serialization/types/HttpRequestPart.js +31 -0
  1099. package/serialization/types/LabelValue.d.ts +10 -0
  1100. package/serialization/types/LabelValue.js +31 -0
  1101. package/serialization/types/Labels.d.ts +10 -0
  1102. package/serialization/types/Labels.js +40 -0
  1103. package/serialization/types/Owner.d.ts +13 -0
  1104. package/serialization/types/Owner.js +34 -0
  1105. package/serialization/types/OwnerField.d.ts +10 -0
  1106. package/serialization/types/OwnerField.js +42 -0
  1107. package/serialization/types/OwnerFilter.d.ts +20 -0
  1108. package/serialization/types/OwnerFilter.js +50 -0
  1109. package/serialization/types/OwnerFilterData.d.ts +13 -0
  1110. package/serialization/types/OwnerFilterData.js +43 -0
  1111. package/serialization/types/OwnerInput.d.ts +14 -0
  1112. package/serialization/types/OwnerInput.js +44 -0
  1113. package/serialization/types/OwnerList.d.ts +12 -0
  1114. package/serialization/types/OwnerList.js +42 -0
  1115. package/serialization/types/OwnerResource.d.ts +21 -0
  1116. package/serialization/types/OwnerResource.js +51 -0
  1117. package/serialization/types/OwnerSort.d.ts +13 -0
  1118. package/serialization/types/OwnerSort.js +43 -0
  1119. package/serialization/types/Pet.d.ts +14 -0
  1120. package/serialization/types/Pet.js +44 -0
  1121. package/serialization/types/PetField.d.ts +10 -0
  1122. package/serialization/types/PetField.js +43 -0
  1123. package/serialization/types/PetFilter.d.ts +20 -0
  1124. package/serialization/types/PetFilter.js +50 -0
  1125. package/serialization/types/PetFilterData.d.ts +14 -0
  1126. package/serialization/types/PetFilterData.js +44 -0
  1127. package/serialization/types/PetInput.d.ts +13 -0
  1128. package/serialization/types/PetInput.js +43 -0
  1129. package/serialization/types/PetList.d.ts +12 -0
  1130. package/serialization/types/PetList.js +42 -0
  1131. package/serialization/types/PetResource.d.ts +21 -0
  1132. package/serialization/types/PetResource.js +51 -0
  1133. package/serialization/types/PetSort.d.ts +13 -0
  1134. package/serialization/types/PetSort.js +43 -0
  1135. package/serialization/types/ProblemBodyContent.d.ts +16 -0
  1136. package/serialization/types/ProblemBodyContent.js +46 -0
  1137. package/serialization/types/ProblemForbidden.d.ts +16 -0
  1138. package/serialization/types/ProblemForbidden.js +46 -0
  1139. package/serialization/types/ProblemInternalServerError.d.ts +16 -0
  1140. package/serialization/types/ProblemInternalServerError.js +46 -0
  1141. package/serialization/types/ProblemNotFoundBlob.d.ts +17 -0
  1142. package/serialization/types/ProblemNotFoundBlob.js +47 -0
  1143. package/serialization/types/ProblemNotFoundResource.d.ts +17 -0
  1144. package/serialization/types/ProblemNotFoundResource.js +47 -0
  1145. package/serialization/types/ProblemNotFoundRevision.d.ts +17 -0
  1146. package/serialization/types/ProblemNotFoundRevision.js +47 -0
  1147. package/serialization/types/ProblemNullUnicode.d.ts +17 -0
  1148. package/serialization/types/ProblemNullUnicode.js +47 -0
  1149. package/serialization/types/ProblemResourceConflict.d.ts +18 -0
  1150. package/serialization/types/ProblemResourceConflict.js +48 -0
  1151. package/serialization/types/ProblemResourceMethodNotAllowed.d.ts +19 -0
  1152. package/serialization/types/ProblemResourceMethodNotAllowed.js +49 -0
  1153. package/serialization/types/ProblemUnauthorized.d.ts +16 -0
  1154. package/serialization/types/ProblemUnauthorized.js +46 -0
  1155. package/serialization/types/ProblemUnsupportedMediaType.d.ts +17 -0
  1156. package/serialization/types/ProblemUnsupportedMediaType.js +47 -0
  1157. package/serialization/types/ProblemValidation.d.ts +18 -0
  1158. package/serialization/types/ProblemValidation.js +48 -0
  1159. package/serialization/types/RequestedETag.d.ts +14 -0
  1160. package/serialization/types/RequestedETag.js +44 -0
  1161. package/serialization/types/RequestedRevision.d.ts +14 -0
  1162. package/serialization/types/RequestedRevision.js +44 -0
  1163. package/serialization/types/Resource.d.ts +20 -0
  1164. package/serialization/types/Resource.js +50 -0
  1165. package/serialization/types/ResourceId.d.ts +10 -0
  1166. package/serialization/types/ResourceId.js +31 -0
  1167. package/serialization/types/ResourceKind.d.ts +13 -0
  1168. package/serialization/types/ResourceKind.js +43 -0
  1169. package/serialization/types/ResourceName.d.ts +10 -0
  1170. package/serialization/types/ResourceName.js +31 -0
  1171. package/serialization/types/ResourceVersion.d.ts +10 -0
  1172. package/serialization/types/ResourceVersion.js +31 -0
  1173. package/serialization/types/Revision.d.ts +10 -0
  1174. package/serialization/types/Revision.js +31 -0
  1175. package/serialization/types/SortOrder.d.ts +10 -0
  1176. package/serialization/types/SortOrder.js +31 -0
  1177. package/serialization/types/Species.d.ts +10 -0
  1178. package/serialization/types/Species.js +35 -0
  1179. package/serialization/types/Timestamp.d.ts +10 -0
  1180. package/serialization/types/Timestamp.js +31 -0
  1181. package/serialization/types/UploadResponse.d.ts +15 -0
  1182. package/serialization/types/UploadResponse.js +45 -0
  1183. package/serialization/types/Uri.d.ts +10 -0
  1184. package/serialization/types/Uri.js +31 -0
  1185. package/serialization/types/UriReference.d.ts +10 -0
  1186. package/serialization/types/UriReference.js +31 -0
  1187. package/serialization/types/ValidationError.d.ts +14 -0
  1188. package/serialization/types/ValidationError.js +46 -0
  1189. package/serialization/types/index.d.ts +91 -0
  1190. package/serialization/types/index.js +107 -0
  1191. package/tests/client.test.ts +11 -0
@@ -0,0 +1,861 @@
1
+ "use strict";
2
+ /**
3
+ * This file was auto-generated by Fern from our API Definition.
4
+ */
5
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
6
+ if (k2 === undefined) k2 = k;
7
+ var desc = Object.getOwnPropertyDescriptor(m, k);
8
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
9
+ desc = { enumerable: true, get: function() { return m[k]; } };
10
+ }
11
+ Object.defineProperty(o, k2, desc);
12
+ }) : (function(o, m, k, k2) {
13
+ if (k2 === undefined) k2 = k;
14
+ o[k2] = m[k];
15
+ }));
16
+ var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
17
+ Object.defineProperty(o, "default", { enumerable: true, value: v });
18
+ }) : function(o, v) {
19
+ o["default"] = v;
20
+ });
21
+ var __importStar = (this && this.__importStar) || function (mod) {
22
+ if (mod && mod.__esModule) return mod;
23
+ var result = {};
24
+ if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
25
+ __setModuleDefault(result, mod);
26
+ return result;
27
+ };
28
+ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
29
+ function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
30
+ return new (P || (P = Promise))(function (resolve, reject) {
31
+ function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
32
+ function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
33
+ function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
34
+ step((generator = generator.apply(thisArg, _arguments || [])).next());
35
+ });
36
+ };
37
+ var __rest = (this && this.__rest) || function (s, e) {
38
+ var t = {};
39
+ for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p) && e.indexOf(p) < 0)
40
+ t[p] = s[p];
41
+ if (s != null && typeof Object.getOwnPropertySymbols === "function")
42
+ for (var i = 0, p = Object.getOwnPropertySymbols(s); i < p.length; i++) {
43
+ if (e.indexOf(p[i]) < 0 && Object.prototype.propertyIsEnumerable.call(s, p[i]))
44
+ t[p[i]] = s[p[i]];
45
+ }
46
+ return t;
47
+ };
48
+ var __importDefault = (this && this.__importDefault) || function (mod) {
49
+ return (mod && mod.__esModule) ? mod : { "default": mod };
50
+ };
51
+ Object.defineProperty(exports, "__esModule", { value: true });
52
+ exports.Pets = void 0;
53
+ const environments = __importStar(require("../../../../environments"));
54
+ const core = __importStar(require("../../../../core"));
55
+ const Truvity = __importStar(require("../../.."));
56
+ const serializers = __importStar(require("../../../../serialization"));
57
+ const url_join_1 = __importDefault(require("url-join"));
58
+ const errors = __importStar(require("../../../../errors"));
59
+ /**
60
+ * Pets API for RESTful PetStore.
61
+ */
62
+ class Pets {
63
+ constructor(_options = {}) {
64
+ this._options = _options;
65
+ }
66
+ /**
67
+ * Create pet's resource.
68
+ * @throws {@link Truvity.BadRequestError}
69
+ * @throws {@link Truvity.UnauthorizedError}
70
+ * @throws {@link Truvity.ForbiddenError}
71
+ * @throws {@link Truvity.NotFoundError}
72
+ * @throws {@link Truvity.InternalServerError}
73
+ *
74
+ * @example
75
+ * await truvity.pets.petCreate({
76
+ * blobId: "blob_id",
77
+ * body: {}
78
+ * })
79
+ */
80
+ petCreate(request, requestOptions) {
81
+ var _a, _b;
82
+ return __awaiter(this, void 0, void 0, function* () {
83
+ const { blobId, idempotencyKey, body: _body } = request;
84
+ const _queryParams = {};
85
+ _queryParams["blob_id"] = blobId;
86
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
87
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, "pets"),
88
+ method: "POST",
89
+ headers: {
90
+ "X-Fern-Language": "JavaScript",
91
+ "X-Fern-SDK-Name": "@truvity/sdk",
92
+ "X-Fern-SDK-Version": "0.0.1",
93
+ "X-Fern-Runtime": core.RUNTIME.type,
94
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
95
+ "Idempotency-Key": idempotencyKey != null ? idempotencyKey : undefined,
96
+ },
97
+ contentType: "application/json",
98
+ queryParameters: _queryParams,
99
+ body: yield serializers.PetInput.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
100
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
101
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
102
+ });
103
+ if (_response.ok) {
104
+ return yield serializers.PetResource.parseOrThrow(_response.body, {
105
+ unrecognizedObjectKeys: "passthrough",
106
+ allowUnrecognizedUnionMembers: true,
107
+ allowUnrecognizedEnumValues: true,
108
+ breadcrumbsPrefix: ["response"],
109
+ });
110
+ }
111
+ if (_response.error.reason === "status-code") {
112
+ switch (_response.error.statusCode) {
113
+ case 400:
114
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
115
+ unrecognizedObjectKeys: "passthrough",
116
+ allowUnrecognizedUnionMembers: true,
117
+ allowUnrecognizedEnumValues: true,
118
+ breadcrumbsPrefix: ["response"],
119
+ }));
120
+ case 401:
121
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
122
+ unrecognizedObjectKeys: "passthrough",
123
+ allowUnrecognizedUnionMembers: true,
124
+ allowUnrecognizedEnumValues: true,
125
+ breadcrumbsPrefix: ["response"],
126
+ }));
127
+ case 403:
128
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
129
+ unrecognizedObjectKeys: "passthrough",
130
+ allowUnrecognizedUnionMembers: true,
131
+ allowUnrecognizedEnumValues: true,
132
+ breadcrumbsPrefix: ["response"],
133
+ }));
134
+ case 404:
135
+ throw new Truvity.NotFoundError(_response.error.body);
136
+ case 500:
137
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
138
+ unrecognizedObjectKeys: "passthrough",
139
+ allowUnrecognizedUnionMembers: true,
140
+ allowUnrecognizedEnumValues: true,
141
+ breadcrumbsPrefix: ["response"],
142
+ }));
143
+ default:
144
+ throw new errors.TruvityError({
145
+ statusCode: _response.error.statusCode,
146
+ body: _response.error.body,
147
+ });
148
+ }
149
+ }
150
+ switch (_response.error.reason) {
151
+ case "non-json":
152
+ throw new errors.TruvityError({
153
+ statusCode: _response.error.statusCode,
154
+ body: _response.error.rawBody,
155
+ });
156
+ case "timeout":
157
+ throw new errors.TruvityTimeoutError();
158
+ case "unknown":
159
+ throw new errors.TruvityError({
160
+ message: _response.error.errorMessage,
161
+ });
162
+ }
163
+ });
164
+ }
165
+ /**
166
+ * Take a look at [GET with body payload](https://opensource.zalando.com/restful-api-guidelines/#get-with-body)
167
+ *
168
+ * - no resources created: Returns all pets matching the query passed as request input payload.
169
+ * @throws {@link Truvity.BadRequestError}
170
+ * @throws {@link Truvity.UnauthorizedError}
171
+ * @throws {@link Truvity.ForbiddenError}
172
+ * @throws {@link Truvity.InternalServerError}
173
+ *
174
+ * @example
175
+ * await truvity.pets.petSearch()
176
+ */
177
+ petSearch(request = {}, requestOptions) {
178
+ var _a, _b;
179
+ return __awaiter(this, void 0, void 0, function* () {
180
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
181
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, "pets/search"),
182
+ method: "POST",
183
+ headers: {
184
+ "X-Fern-Language": "JavaScript",
185
+ "X-Fern-SDK-Name": "@truvity/sdk",
186
+ "X-Fern-SDK-Version": "0.0.1",
187
+ "X-Fern-Runtime": core.RUNTIME.type,
188
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
189
+ },
190
+ contentType: "application/json",
191
+ body: yield serializers.PetSearch.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
192
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
193
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
194
+ });
195
+ if (_response.ok) {
196
+ return yield serializers.PetList.parseOrThrow(_response.body, {
197
+ unrecognizedObjectKeys: "passthrough",
198
+ allowUnrecognizedUnionMembers: true,
199
+ allowUnrecognizedEnumValues: true,
200
+ breadcrumbsPrefix: ["response"],
201
+ });
202
+ }
203
+ if (_response.error.reason === "status-code") {
204
+ switch (_response.error.statusCode) {
205
+ case 400:
206
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
207
+ unrecognizedObjectKeys: "passthrough",
208
+ allowUnrecognizedUnionMembers: true,
209
+ allowUnrecognizedEnumValues: true,
210
+ breadcrumbsPrefix: ["response"],
211
+ }));
212
+ case 401:
213
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
214
+ unrecognizedObjectKeys: "passthrough",
215
+ allowUnrecognizedUnionMembers: true,
216
+ allowUnrecognizedEnumValues: true,
217
+ breadcrumbsPrefix: ["response"],
218
+ }));
219
+ case 403:
220
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
221
+ unrecognizedObjectKeys: "passthrough",
222
+ allowUnrecognizedUnionMembers: true,
223
+ allowUnrecognizedEnumValues: true,
224
+ breadcrumbsPrefix: ["response"],
225
+ }));
226
+ case 500:
227
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
228
+ unrecognizedObjectKeys: "passthrough",
229
+ allowUnrecognizedUnionMembers: true,
230
+ allowUnrecognizedEnumValues: true,
231
+ breadcrumbsPrefix: ["response"],
232
+ }));
233
+ default:
234
+ throw new errors.TruvityError({
235
+ statusCode: _response.error.statusCode,
236
+ body: _response.error.body,
237
+ });
238
+ }
239
+ }
240
+ switch (_response.error.reason) {
241
+ case "non-json":
242
+ throw new errors.TruvityError({
243
+ statusCode: _response.error.statusCode,
244
+ body: _response.error.rawBody,
245
+ });
246
+ case "timeout":
247
+ throw new errors.TruvityTimeoutError();
248
+ case "unknown":
249
+ throw new errors.TruvityError({
250
+ message: _response.error.errorMessage,
251
+ });
252
+ }
253
+ });
254
+ }
255
+ /**
256
+ * Upload of pet's blob.
257
+ * @throws {@link Truvity.BadRequestError}
258
+ * @throws {@link Truvity.UnauthorizedError}
259
+ * @throws {@link Truvity.ForbiddenError}
260
+ * @throws {@link Truvity.InternalServerError}
261
+ *
262
+ * @example
263
+ * await truvity.pets.petUpload()
264
+ */
265
+ petUpload(request = {}, requestOptions) {
266
+ var _a, _b;
267
+ return __awaiter(this, void 0, void 0, function* () {
268
+ const { idempotencyKey } = request, _body = __rest(request, ["idempotencyKey"]);
269
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
270
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, "pets/upload"),
271
+ method: "POST",
272
+ headers: {
273
+ "X-Fern-Language": "JavaScript",
274
+ "X-Fern-SDK-Name": "@truvity/sdk",
275
+ "X-Fern-SDK-Version": "0.0.1",
276
+ "X-Fern-Runtime": core.RUNTIME.type,
277
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
278
+ "Idempotency-Key": idempotencyKey != null ? idempotencyKey : undefined,
279
+ },
280
+ contentType: "application/json",
281
+ body: yield serializers.UploadRequest.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
282
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
283
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
284
+ });
285
+ if (_response.ok) {
286
+ return yield serializers.UploadResponse.parseOrThrow(_response.body, {
287
+ unrecognizedObjectKeys: "passthrough",
288
+ allowUnrecognizedUnionMembers: true,
289
+ allowUnrecognizedEnumValues: true,
290
+ breadcrumbsPrefix: ["response"],
291
+ });
292
+ }
293
+ if (_response.error.reason === "status-code") {
294
+ switch (_response.error.statusCode) {
295
+ case 400:
296
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
297
+ unrecognizedObjectKeys: "passthrough",
298
+ allowUnrecognizedUnionMembers: true,
299
+ allowUnrecognizedEnumValues: true,
300
+ breadcrumbsPrefix: ["response"],
301
+ }));
302
+ case 401:
303
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
304
+ unrecognizedObjectKeys: "passthrough",
305
+ allowUnrecognizedUnionMembers: true,
306
+ allowUnrecognizedEnumValues: true,
307
+ breadcrumbsPrefix: ["response"],
308
+ }));
309
+ case 403:
310
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
311
+ unrecognizedObjectKeys: "passthrough",
312
+ allowUnrecognizedUnionMembers: true,
313
+ allowUnrecognizedEnumValues: true,
314
+ breadcrumbsPrefix: ["response"],
315
+ }));
316
+ case 500:
317
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
318
+ unrecognizedObjectKeys: "passthrough",
319
+ allowUnrecognizedUnionMembers: true,
320
+ allowUnrecognizedEnumValues: true,
321
+ breadcrumbsPrefix: ["response"],
322
+ }));
323
+ default:
324
+ throw new errors.TruvityError({
325
+ statusCode: _response.error.statusCode,
326
+ body: _response.error.body,
327
+ });
328
+ }
329
+ }
330
+ switch (_response.error.reason) {
331
+ case "non-json":
332
+ throw new errors.TruvityError({
333
+ statusCode: _response.error.statusCode,
334
+ body: _response.error.rawBody,
335
+ });
336
+ case "timeout":
337
+ throw new errors.TruvityTimeoutError();
338
+ case "unknown":
339
+ throw new errors.TruvityError({
340
+ message: _response.error.errorMessage,
341
+ });
342
+ }
343
+ });
344
+ }
345
+ /**
346
+ * Read the latest revision of the pet's resource.
347
+ * @throws {@link Truvity.BadRequestError}
348
+ * @throws {@link Truvity.UnauthorizedError}
349
+ * @throws {@link Truvity.ForbiddenError}
350
+ * @throws {@link Truvity.NotFoundError}
351
+ * @throws {@link Truvity.InternalServerError}
352
+ *
353
+ * @example
354
+ * await truvity.pets.petLatest("id")
355
+ */
356
+ petLatest(id, request = {}, requestOptions) {
357
+ var _a, _b;
358
+ return __awaiter(this, void 0, void 0, function* () {
359
+ const { ifNoneMatch } = request;
360
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
361
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, `pets/${yield serializers.ResourceId.jsonOrThrow(id)}`),
362
+ method: "GET",
363
+ headers: {
364
+ "X-Fern-Language": "JavaScript",
365
+ "X-Fern-SDK-Name": "@truvity/sdk",
366
+ "X-Fern-SDK-Version": "0.0.1",
367
+ "X-Fern-Runtime": core.RUNTIME.type,
368
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
369
+ "If-None-Match": ifNoneMatch != null ? ifNoneMatch : undefined,
370
+ },
371
+ contentType: "application/json",
372
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
373
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
374
+ });
375
+ if (_response.ok) {
376
+ return yield serializers.PetResource.parseOrThrow(_response.body, {
377
+ unrecognizedObjectKeys: "passthrough",
378
+ allowUnrecognizedUnionMembers: true,
379
+ allowUnrecognizedEnumValues: true,
380
+ breadcrumbsPrefix: ["response"],
381
+ });
382
+ }
383
+ if (_response.error.reason === "status-code") {
384
+ switch (_response.error.statusCode) {
385
+ case 400:
386
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
387
+ unrecognizedObjectKeys: "passthrough",
388
+ allowUnrecognizedUnionMembers: true,
389
+ allowUnrecognizedEnumValues: true,
390
+ breadcrumbsPrefix: ["response"],
391
+ }));
392
+ case 401:
393
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
394
+ unrecognizedObjectKeys: "passthrough",
395
+ allowUnrecognizedUnionMembers: true,
396
+ allowUnrecognizedEnumValues: true,
397
+ breadcrumbsPrefix: ["response"],
398
+ }));
399
+ case 403:
400
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
401
+ unrecognizedObjectKeys: "passthrough",
402
+ allowUnrecognizedUnionMembers: true,
403
+ allowUnrecognizedEnumValues: true,
404
+ breadcrumbsPrefix: ["response"],
405
+ }));
406
+ case 404:
407
+ throw new Truvity.NotFoundError(_response.error.body);
408
+ case 500:
409
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
410
+ unrecognizedObjectKeys: "passthrough",
411
+ allowUnrecognizedUnionMembers: true,
412
+ allowUnrecognizedEnumValues: true,
413
+ breadcrumbsPrefix: ["response"],
414
+ }));
415
+ default:
416
+ throw new errors.TruvityError({
417
+ statusCode: _response.error.statusCode,
418
+ body: _response.error.body,
419
+ });
420
+ }
421
+ }
422
+ switch (_response.error.reason) {
423
+ case "non-json":
424
+ throw new errors.TruvityError({
425
+ statusCode: _response.error.statusCode,
426
+ body: _response.error.rawBody,
427
+ });
428
+ case "timeout":
429
+ throw new errors.TruvityTimeoutError();
430
+ case "unknown":
431
+ throw new errors.TruvityError({
432
+ message: _response.error.errorMessage,
433
+ });
434
+ }
435
+ });
436
+ }
437
+ /**
438
+ * Update pet's resource.
439
+ * @throws {@link Truvity.BadRequestError}
440
+ * @throws {@link Truvity.UnauthorizedError}
441
+ * @throws {@link Truvity.ForbiddenError}
442
+ * @throws {@link Truvity.NotFoundError}
443
+ * @throws {@link Truvity.InternalServerError}
444
+ *
445
+ * @example
446
+ * await truvity.pets.petUpdate("id", {
447
+ * ifMatch: "If-Match",
448
+ * body: {}
449
+ * })
450
+ */
451
+ petUpdate(id, request, requestOptions) {
452
+ var _a, _b;
453
+ return __awaiter(this, void 0, void 0, function* () {
454
+ const { blobId, idempotencyKey, ifMatch, body: _body } = request;
455
+ const _queryParams = {};
456
+ if (blobId != null) {
457
+ _queryParams["blob_id"] = blobId;
458
+ }
459
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
460
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, `pets/${yield serializers.ResourceId.jsonOrThrow(id)}`),
461
+ method: "PUT",
462
+ headers: {
463
+ "X-Fern-Language": "JavaScript",
464
+ "X-Fern-SDK-Name": "@truvity/sdk",
465
+ "X-Fern-SDK-Version": "0.0.1",
466
+ "X-Fern-Runtime": core.RUNTIME.type,
467
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
468
+ "Idempotency-Key": idempotencyKey != null ? idempotencyKey : undefined,
469
+ "If-Match": ifMatch,
470
+ },
471
+ contentType: "application/json",
472
+ queryParameters: _queryParams,
473
+ body: yield serializers.PetInput.jsonOrThrow(_body, { unrecognizedObjectKeys: "strip" }),
474
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
475
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
476
+ });
477
+ if (_response.ok) {
478
+ return yield serializers.PetResource.parseOrThrow(_response.body, {
479
+ unrecognizedObjectKeys: "passthrough",
480
+ allowUnrecognizedUnionMembers: true,
481
+ allowUnrecognizedEnumValues: true,
482
+ breadcrumbsPrefix: ["response"],
483
+ });
484
+ }
485
+ if (_response.error.reason === "status-code") {
486
+ switch (_response.error.statusCode) {
487
+ case 400:
488
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
489
+ unrecognizedObjectKeys: "passthrough",
490
+ allowUnrecognizedUnionMembers: true,
491
+ allowUnrecognizedEnumValues: true,
492
+ breadcrumbsPrefix: ["response"],
493
+ }));
494
+ case 401:
495
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
496
+ unrecognizedObjectKeys: "passthrough",
497
+ allowUnrecognizedUnionMembers: true,
498
+ allowUnrecognizedEnumValues: true,
499
+ breadcrumbsPrefix: ["response"],
500
+ }));
501
+ case 403:
502
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
503
+ unrecognizedObjectKeys: "passthrough",
504
+ allowUnrecognizedUnionMembers: true,
505
+ allowUnrecognizedEnumValues: true,
506
+ breadcrumbsPrefix: ["response"],
507
+ }));
508
+ case 404:
509
+ throw new Truvity.NotFoundError(_response.error.body);
510
+ case 500:
511
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
512
+ unrecognizedObjectKeys: "passthrough",
513
+ allowUnrecognizedUnionMembers: true,
514
+ allowUnrecognizedEnumValues: true,
515
+ breadcrumbsPrefix: ["response"],
516
+ }));
517
+ default:
518
+ throw new errors.TruvityError({
519
+ statusCode: _response.error.statusCode,
520
+ body: _response.error.body,
521
+ });
522
+ }
523
+ }
524
+ switch (_response.error.reason) {
525
+ case "non-json":
526
+ throw new errors.TruvityError({
527
+ statusCode: _response.error.statusCode,
528
+ body: _response.error.rawBody,
529
+ });
530
+ case "timeout":
531
+ throw new errors.TruvityTimeoutError();
532
+ case "unknown":
533
+ throw new errors.TruvityError({
534
+ message: _response.error.errorMessage,
535
+ });
536
+ }
537
+ });
538
+ }
539
+ /**
540
+ * Delete pet's resource.
541
+ * @throws {@link Truvity.BadRequestError}
542
+ * @throws {@link Truvity.UnauthorizedError}
543
+ * @throws {@link Truvity.ForbiddenError}
544
+ * @throws {@link Truvity.NotFoundError}
545
+ * @throws {@link Truvity.InternalServerError}
546
+ *
547
+ * @example
548
+ * await truvity.pets.petDelete("id", {
549
+ * ifMatch: "If-Match"
550
+ * })
551
+ */
552
+ petDelete(id, request, requestOptions) {
553
+ var _a, _b;
554
+ return __awaiter(this, void 0, void 0, function* () {
555
+ const { idempotencyKey, ifMatch } = request;
556
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
557
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, `pets/${yield serializers.ResourceId.jsonOrThrow(id)}`),
558
+ method: "DELETE",
559
+ headers: {
560
+ "X-Fern-Language": "JavaScript",
561
+ "X-Fern-SDK-Name": "@truvity/sdk",
562
+ "X-Fern-SDK-Version": "0.0.1",
563
+ "X-Fern-Runtime": core.RUNTIME.type,
564
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
565
+ "Idempotency-Key": idempotencyKey != null ? idempotencyKey : undefined,
566
+ "If-Match": ifMatch,
567
+ },
568
+ contentType: "application/json",
569
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
570
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
571
+ });
572
+ if (_response.ok) {
573
+ return;
574
+ }
575
+ if (_response.error.reason === "status-code") {
576
+ switch (_response.error.statusCode) {
577
+ case 400:
578
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
579
+ unrecognizedObjectKeys: "passthrough",
580
+ allowUnrecognizedUnionMembers: true,
581
+ allowUnrecognizedEnumValues: true,
582
+ breadcrumbsPrefix: ["response"],
583
+ }));
584
+ case 401:
585
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
586
+ unrecognizedObjectKeys: "passthrough",
587
+ allowUnrecognizedUnionMembers: true,
588
+ allowUnrecognizedEnumValues: true,
589
+ breadcrumbsPrefix: ["response"],
590
+ }));
591
+ case 403:
592
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
593
+ unrecognizedObjectKeys: "passthrough",
594
+ allowUnrecognizedUnionMembers: true,
595
+ allowUnrecognizedEnumValues: true,
596
+ breadcrumbsPrefix: ["response"],
597
+ }));
598
+ case 404:
599
+ throw new Truvity.NotFoundError(_response.error.body);
600
+ case 500:
601
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
602
+ unrecognizedObjectKeys: "passthrough",
603
+ allowUnrecognizedUnionMembers: true,
604
+ allowUnrecognizedEnumValues: true,
605
+ breadcrumbsPrefix: ["response"],
606
+ }));
607
+ default:
608
+ throw new errors.TruvityError({
609
+ statusCode: _response.error.statusCode,
610
+ body: _response.error.body,
611
+ });
612
+ }
613
+ }
614
+ switch (_response.error.reason) {
615
+ case "non-json":
616
+ throw new errors.TruvityError({
617
+ statusCode: _response.error.statusCode,
618
+ body: _response.error.rawBody,
619
+ });
620
+ case "timeout":
621
+ throw new errors.TruvityTimeoutError();
622
+ case "unknown":
623
+ throw new errors.TruvityError({
624
+ message: _response.error.errorMessage,
625
+ });
626
+ }
627
+ });
628
+ }
629
+ /**
630
+ * History of the pets' resources.
631
+ * @throws {@link Truvity.BadRequestError}
632
+ * @throws {@link Truvity.UnauthorizedError}
633
+ * @throws {@link Truvity.ForbiddenError}
634
+ * @throws {@link Truvity.NotFoundError}
635
+ * @throws {@link Truvity.InternalServerError}
636
+ *
637
+ * @example
638
+ * await truvity.pets.petHistory("id")
639
+ */
640
+ petHistory(id, request = {}, requestOptions) {
641
+ var _a, _b;
642
+ return __awaiter(this, void 0, void 0, function* () {
643
+ const { ifNoneMatch } = request;
644
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
645
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, `pets/${yield serializers.ResourceId.jsonOrThrow(id)}/revisions`),
646
+ method: "GET",
647
+ headers: {
648
+ "X-Fern-Language": "JavaScript",
649
+ "X-Fern-SDK-Name": "@truvity/sdk",
650
+ "X-Fern-SDK-Version": "0.0.1",
651
+ "X-Fern-Runtime": core.RUNTIME.type,
652
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
653
+ "If-None-Match": ifNoneMatch != null ? ifNoneMatch : undefined,
654
+ },
655
+ contentType: "application/json",
656
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
657
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
658
+ });
659
+ if (_response.ok) {
660
+ return yield serializers.PetList.parseOrThrow(_response.body, {
661
+ unrecognizedObjectKeys: "passthrough",
662
+ allowUnrecognizedUnionMembers: true,
663
+ allowUnrecognizedEnumValues: true,
664
+ breadcrumbsPrefix: ["response"],
665
+ });
666
+ }
667
+ if (_response.error.reason === "status-code") {
668
+ switch (_response.error.statusCode) {
669
+ case 400:
670
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
671
+ unrecognizedObjectKeys: "passthrough",
672
+ allowUnrecognizedUnionMembers: true,
673
+ allowUnrecognizedEnumValues: true,
674
+ breadcrumbsPrefix: ["response"],
675
+ }));
676
+ case 401:
677
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
678
+ unrecognizedObjectKeys: "passthrough",
679
+ allowUnrecognizedUnionMembers: true,
680
+ allowUnrecognizedEnumValues: true,
681
+ breadcrumbsPrefix: ["response"],
682
+ }));
683
+ case 403:
684
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
685
+ unrecognizedObjectKeys: "passthrough",
686
+ allowUnrecognizedUnionMembers: true,
687
+ allowUnrecognizedEnumValues: true,
688
+ breadcrumbsPrefix: ["response"],
689
+ }));
690
+ case 404:
691
+ throw new Truvity.NotFoundError(_response.error.body);
692
+ case 500:
693
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
694
+ unrecognizedObjectKeys: "passthrough",
695
+ allowUnrecognizedUnionMembers: true,
696
+ allowUnrecognizedEnumValues: true,
697
+ breadcrumbsPrefix: ["response"],
698
+ }));
699
+ default:
700
+ throw new errors.TruvityError({
701
+ statusCode: _response.error.statusCode,
702
+ body: _response.error.body,
703
+ });
704
+ }
705
+ }
706
+ switch (_response.error.reason) {
707
+ case "non-json":
708
+ throw new errors.TruvityError({
709
+ statusCode: _response.error.statusCode,
710
+ body: _response.error.rawBody,
711
+ });
712
+ case "timeout":
713
+ throw new errors.TruvityTimeoutError();
714
+ case "unknown":
715
+ throw new errors.TruvityError({
716
+ message: _response.error.errorMessage,
717
+ });
718
+ }
719
+ });
720
+ }
721
+ /**
722
+ * Read the specific version of the pet's resource.
723
+ * @throws {@link Truvity.BadRequestError}
724
+ * @throws {@link Truvity.UnauthorizedError}
725
+ * @throws {@link Truvity.ForbiddenError}
726
+ * @throws {@link Truvity.NotFoundError}
727
+ * @throws {@link Truvity.InternalServerError}
728
+ *
729
+ * @example
730
+ * await truvity.pets.petRevision("id", 1)
731
+ */
732
+ petRevision(id, revision, request = {}, requestOptions) {
733
+ var _a, _b;
734
+ return __awaiter(this, void 0, void 0, function* () {
735
+ const { ifNoneMatch } = request;
736
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
737
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, `pets/${yield serializers.ResourceId.jsonOrThrow(id)}/revisions/${yield serializers.Revision.jsonOrThrow(revision)}`),
738
+ method: "GET",
739
+ headers: {
740
+ "X-Fern-Language": "JavaScript",
741
+ "X-Fern-SDK-Name": "@truvity/sdk",
742
+ "X-Fern-SDK-Version": "0.0.1",
743
+ "X-Fern-Runtime": core.RUNTIME.type,
744
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
745
+ "If-None-Match": ifNoneMatch != null ? ifNoneMatch : undefined,
746
+ },
747
+ contentType: "application/json",
748
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
749
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
750
+ });
751
+ if (_response.ok) {
752
+ return yield serializers.PetResource.parseOrThrow(_response.body, {
753
+ unrecognizedObjectKeys: "passthrough",
754
+ allowUnrecognizedUnionMembers: true,
755
+ allowUnrecognizedEnumValues: true,
756
+ breadcrumbsPrefix: ["response"],
757
+ });
758
+ }
759
+ if (_response.error.reason === "status-code") {
760
+ switch (_response.error.statusCode) {
761
+ case 400:
762
+ throw new Truvity.BadRequestError(yield serializers.BadRequestErrorBody.parseOrThrow(_response.error.body, {
763
+ unrecognizedObjectKeys: "passthrough",
764
+ allowUnrecognizedUnionMembers: true,
765
+ allowUnrecognizedEnumValues: true,
766
+ breadcrumbsPrefix: ["response"],
767
+ }));
768
+ case 401:
769
+ throw new Truvity.UnauthorizedError(yield serializers.ProblemUnauthorized.parseOrThrow(_response.error.body, {
770
+ unrecognizedObjectKeys: "passthrough",
771
+ allowUnrecognizedUnionMembers: true,
772
+ allowUnrecognizedEnumValues: true,
773
+ breadcrumbsPrefix: ["response"],
774
+ }));
775
+ case 403:
776
+ throw new Truvity.ForbiddenError(yield serializers.ProblemForbidden.parseOrThrow(_response.error.body, {
777
+ unrecognizedObjectKeys: "passthrough",
778
+ allowUnrecognizedUnionMembers: true,
779
+ allowUnrecognizedEnumValues: true,
780
+ breadcrumbsPrefix: ["response"],
781
+ }));
782
+ case 404:
783
+ throw new Truvity.NotFoundError(_response.error.body);
784
+ case 500:
785
+ throw new Truvity.InternalServerError(yield serializers.ProblemInternalServerError.parseOrThrow(_response.error.body, {
786
+ unrecognizedObjectKeys: "passthrough",
787
+ allowUnrecognizedUnionMembers: true,
788
+ allowUnrecognizedEnumValues: true,
789
+ breadcrumbsPrefix: ["response"],
790
+ }));
791
+ default:
792
+ throw new errors.TruvityError({
793
+ statusCode: _response.error.statusCode,
794
+ body: _response.error.body,
795
+ });
796
+ }
797
+ }
798
+ switch (_response.error.reason) {
799
+ case "non-json":
800
+ throw new errors.TruvityError({
801
+ statusCode: _response.error.statusCode,
802
+ body: _response.error.rawBody,
803
+ });
804
+ case "timeout":
805
+ throw new errors.TruvityTimeoutError();
806
+ case "unknown":
807
+ throw new errors.TruvityError({
808
+ message: _response.error.errorMessage,
809
+ });
810
+ }
811
+ });
812
+ }
813
+ /**
814
+ * Download of pet's blob.
815
+ */
816
+ petDownload(id, revision, request = {}, requestOptions) {
817
+ var _a, _b;
818
+ return __awaiter(this, void 0, void 0, function* () {
819
+ const { ifNoneMatch } = request;
820
+ const _response = yield ((_a = this._options.fetcher) !== null && _a !== void 0 ? _a : core.fetcher)({
821
+ url: (0, url_join_1.default)((_b = (yield core.Supplier.get(this._options.environment))) !== null && _b !== void 0 ? _b : environments.TruvityEnvironment.Default, `pets/${yield serializers.ResourceId.jsonOrThrow(id)}/revisions/${yield serializers.Revision.jsonOrThrow(revision)}/download`),
822
+ method: "GET",
823
+ headers: {
824
+ "X-Fern-Language": "JavaScript",
825
+ "X-Fern-SDK-Name": "@truvity/sdk",
826
+ "X-Fern-SDK-Version": "0.0.1",
827
+ "X-Fern-Runtime": core.RUNTIME.type,
828
+ "X-Fern-Runtime-Version": core.RUNTIME.version,
829
+ "If-None-Match": ifNoneMatch != null ? ifNoneMatch : undefined,
830
+ },
831
+ contentType: "application/json",
832
+ responseType: "streaming",
833
+ timeoutMs: (requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
834
+ maxRetries: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries,
835
+ });
836
+ if (_response.ok) {
837
+ return _response.body;
838
+ }
839
+ if (_response.error.reason === "status-code") {
840
+ throw new errors.TruvityError({
841
+ statusCode: _response.error.statusCode,
842
+ body: _response.error.body,
843
+ });
844
+ }
845
+ switch (_response.error.reason) {
846
+ case "non-json":
847
+ throw new errors.TruvityError({
848
+ statusCode: _response.error.statusCode,
849
+ body: _response.error.rawBody,
850
+ });
851
+ case "timeout":
852
+ throw new errors.TruvityTimeoutError();
853
+ case "unknown":
854
+ throw new errors.TruvityError({
855
+ message: _response.error.errorMessage,
856
+ });
857
+ }
858
+ });
859
+ }
860
+ }
861
+ exports.Pets = Pets;