@scalar/snippetz 0.5.5 → 0.6.2

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 (702) hide show
  1. package/dist/clients/index.js +5 -5
  2. package/dist/clients/index.js.map +1 -1
  3. package/dist/httpsnippet-lite/helpers/code-builder.d.ts +51 -0
  4. package/dist/httpsnippet-lite/helpers/code-builder.d.ts.map +1 -0
  5. package/dist/httpsnippet-lite/{esm/helpers → helpers}/code-builder.js +29 -0
  6. package/dist/httpsnippet-lite/helpers/code-builder.js.map +7 -0
  7. package/dist/httpsnippet-lite/{esm/helpers → helpers}/escape.d.ts +22 -3
  8. package/dist/httpsnippet-lite/helpers/escape.d.ts.map +1 -0
  9. package/dist/httpsnippet-lite/helpers/escape.js.map +7 -0
  10. package/dist/httpsnippet-lite/helpers/headers.d.ts +15 -0
  11. package/dist/httpsnippet-lite/helpers/headers.d.ts.map +1 -0
  12. package/dist/httpsnippet-lite/{esm/helpers → helpers}/headers.js +2 -13
  13. package/dist/httpsnippet-lite/helpers/headers.js.map +7 -0
  14. package/dist/httpsnippet-lite/helpers/reducer.d.ts +2 -0
  15. package/dist/httpsnippet-lite/helpers/reducer.d.ts.map +1 -0
  16. package/dist/httpsnippet-lite/helpers/reducer.js +1 -0
  17. package/dist/httpsnippet-lite/{esm/helpers → helpers}/shell.d.ts +2 -2
  18. package/dist/httpsnippet-lite/helpers/shell.d.ts.map +1 -0
  19. package/dist/httpsnippet-lite/{esm/helpers → helpers}/shell.js +4 -4
  20. package/dist/httpsnippet-lite/helpers/shell.js.map +7 -0
  21. package/dist/httpsnippet-lite/helpers/snippet-request.d.ts +33 -0
  22. package/dist/httpsnippet-lite/helpers/snippet-request.d.ts.map +1 -0
  23. package/dist/httpsnippet-lite/helpers/snippet-request.js +1 -0
  24. package/dist/httpsnippet-lite/helpers/url.d.ts +4 -0
  25. package/dist/httpsnippet-lite/helpers/url.d.ts.map +1 -0
  26. package/dist/httpsnippet-lite/helpers/url.js +9 -0
  27. package/dist/httpsnippet-lite/helpers/url.js.map +7 -0
  28. package/dist/httpsnippet-lite/targets/c/libcurl/client.d.ts +3 -0
  29. package/dist/httpsnippet-lite/targets/c/libcurl/client.d.ts.map +1 -0
  30. package/dist/httpsnippet-lite/{esm/targets → targets}/c/libcurl/client.js +7 -13
  31. package/dist/httpsnippet-lite/targets/c/libcurl/client.js.map +7 -0
  32. package/dist/httpsnippet-lite/targets/clojure/clj_http/client.d.ts +12 -0
  33. package/dist/httpsnippet-lite/targets/clojure/clj_http/client.d.ts.map +1 -0
  34. package/dist/httpsnippet-lite/{esm/targets → targets}/clojure/clj_http/client.js +7 -3
  35. package/dist/httpsnippet-lite/targets/clojure/clj_http/client.js.map +7 -0
  36. package/dist/httpsnippet-lite/targets/csharp/restsharp/client.d.ts +3 -0
  37. package/dist/httpsnippet-lite/targets/csharp/restsharp/client.d.ts.map +1 -0
  38. package/dist/httpsnippet-lite/{esm/targets → targets}/csharp/restsharp/client.js +8 -18
  39. package/dist/httpsnippet-lite/targets/csharp/restsharp/client.js.map +7 -0
  40. package/dist/httpsnippet-lite/targets/go/native/client.d.ts +12 -0
  41. package/dist/httpsnippet-lite/targets/go/native/client.d.ts.map +1 -0
  42. package/dist/httpsnippet-lite/{esm/targets → targets}/go/native/client.js +14 -35
  43. package/dist/httpsnippet-lite/targets/go/native/client.js.map +7 -0
  44. package/dist/httpsnippet-lite/targets/java/asynchttp/client.d.ts +12 -0
  45. package/dist/httpsnippet-lite/targets/java/asynchttp/client.d.ts.map +1 -0
  46. package/dist/httpsnippet-lite/{esm/targets → targets}/java/asynchttp/client.js +1 -4
  47. package/dist/httpsnippet-lite/targets/java/asynchttp/client.js.map +7 -0
  48. package/dist/httpsnippet-lite/targets/java/nethttp/client.d.ts +3 -0
  49. package/dist/httpsnippet-lite/targets/java/nethttp/client.d.ts.map +1 -0
  50. package/dist/httpsnippet-lite/{esm/targets → targets}/java/nethttp/client.js +3 -6
  51. package/dist/httpsnippet-lite/targets/java/nethttp/client.js.map +7 -0
  52. package/dist/httpsnippet-lite/targets/java/okhttp/client.d.ts +12 -0
  53. package/dist/httpsnippet-lite/targets/java/okhttp/client.d.ts.map +1 -0
  54. package/dist/httpsnippet-lite/{esm/targets → targets}/java/okhttp/client.js +5 -8
  55. package/dist/httpsnippet-lite/targets/java/okhttp/client.js.map +7 -0
  56. package/dist/httpsnippet-lite/targets/java/unirest/client.d.ts +12 -0
  57. package/dist/httpsnippet-lite/targets/java/unirest/client.d.ts.map +1 -0
  58. package/dist/httpsnippet-lite/{esm/targets → targets}/java/unirest/client.js +4 -8
  59. package/dist/httpsnippet-lite/targets/java/unirest/client.js.map +7 -0
  60. package/dist/httpsnippet-lite/targets/javascript/axios/client.d.ts +12 -0
  61. package/dist/httpsnippet-lite/targets/javascript/axios/client.d.ts.map +1 -0
  62. package/dist/httpsnippet-lite/{esm/targets → targets}/javascript/axios/client.js +6 -10
  63. package/dist/httpsnippet-lite/targets/javascript/axios/client.js.map +7 -0
  64. package/dist/httpsnippet-lite/targets/javascript/jquery/client.d.ts +3 -0
  65. package/dist/httpsnippet-lite/targets/javascript/jquery/client.d.ts.map +1 -0
  66. package/dist/httpsnippet-lite/{esm/targets → targets}/javascript/jquery/client.js +5 -11
  67. package/dist/httpsnippet-lite/targets/javascript/jquery/client.js.map +7 -0
  68. package/dist/httpsnippet-lite/targets/javascript/xhr/client.d.ts +3 -0
  69. package/dist/httpsnippet-lite/targets/javascript/xhr/client.d.ts.map +1 -0
  70. package/dist/httpsnippet-lite/{esm/targets → targets}/javascript/xhr/client.js +7 -15
  71. package/dist/httpsnippet-lite/targets/javascript/xhr/client.js.map +7 -0
  72. package/dist/httpsnippet-lite/targets/kotlin/okhttp/client.d.ts +12 -0
  73. package/dist/httpsnippet-lite/targets/kotlin/okhttp/client.d.ts.map +1 -0
  74. package/dist/httpsnippet-lite/{esm/targets → targets}/kotlin/okhttp/client.js +6 -9
  75. package/dist/httpsnippet-lite/targets/kotlin/okhttp/client.js.map +7 -0
  76. package/dist/httpsnippet-lite/targets/node/axios/client.d.ts +3 -0
  77. package/dist/httpsnippet-lite/targets/node/axios/client.d.ts.map +1 -0
  78. package/dist/httpsnippet-lite/{esm/targets → targets}/node/axios/client.js +3 -5
  79. package/dist/httpsnippet-lite/targets/node/axios/client.js.map +7 -0
  80. package/dist/httpsnippet-lite/{esm/targets → targets}/objc/helpers.d.ts +5 -11
  81. package/dist/httpsnippet-lite/targets/objc/helpers.d.ts.map +1 -0
  82. package/dist/httpsnippet-lite/{esm/targets → targets}/objc/helpers.js +7 -10
  83. package/dist/httpsnippet-lite/targets/objc/helpers.js.map +7 -0
  84. package/dist/httpsnippet-lite/targets/objc/nsurlsession/client.d.ts +12 -0
  85. package/dist/httpsnippet-lite/targets/objc/nsurlsession/client.d.ts.map +1 -0
  86. package/dist/httpsnippet-lite/{esm/targets → targets}/objc/nsurlsession/client.js +14 -51
  87. package/dist/httpsnippet-lite/targets/objc/nsurlsession/client.js.map +7 -0
  88. package/dist/httpsnippet-lite/targets/ocaml/cohttp/client.d.ts +3 -0
  89. package/dist/httpsnippet-lite/targets/ocaml/cohttp/client.d.ts.map +1 -0
  90. package/dist/httpsnippet-lite/{esm/targets → targets}/ocaml/cohttp/client.js +3 -5
  91. package/dist/httpsnippet-lite/targets/ocaml/cohttp/client.js.map +7 -0
  92. package/dist/httpsnippet-lite/targets/powershell/common.d.ts +3 -0
  93. package/dist/httpsnippet-lite/targets/powershell/common.d.ts.map +1 -0
  94. package/dist/httpsnippet-lite/{esm/targets → targets}/powershell/common.js +6 -12
  95. package/dist/httpsnippet-lite/targets/powershell/common.js.map +7 -0
  96. package/dist/httpsnippet-lite/targets/powershell/restmethod/client.d.ts +3 -0
  97. package/dist/httpsnippet-lite/targets/powershell/restmethod/client.d.ts.map +1 -0
  98. package/dist/httpsnippet-lite/targets/powershell/restmethod/client.js.map +7 -0
  99. package/dist/httpsnippet-lite/targets/powershell/webrequest/client.d.ts +3 -0
  100. package/dist/httpsnippet-lite/targets/powershell/webrequest/client.d.ts.map +1 -0
  101. package/dist/httpsnippet-lite/targets/powershell/webrequest/client.js.map +7 -0
  102. package/dist/httpsnippet-lite/targets/python/python3/client.d.ts +12 -0
  103. package/dist/httpsnippet-lite/targets/python/python3/client.d.ts.map +1 -0
  104. package/dist/httpsnippet-lite/{esm/targets → targets}/python/python3/client.js +4 -8
  105. package/dist/httpsnippet-lite/targets/python/python3/client.js.map +7 -0
  106. package/dist/httpsnippet-lite/targets/r/httr/client.d.ts +12 -0
  107. package/dist/httpsnippet-lite/targets/r/httr/client.d.ts.map +1 -0
  108. package/dist/httpsnippet-lite/{esm/targets → targets}/r/httr/client.js +5 -12
  109. package/dist/httpsnippet-lite/targets/r/httr/client.js.map +7 -0
  110. package/dist/httpsnippet-lite/targets/ruby/native/client.d.ts +3 -0
  111. package/dist/httpsnippet-lite/targets/ruby/native/client.d.ts.map +1 -0
  112. package/dist/httpsnippet-lite/{esm/targets → targets}/ruby/native/client.js +2 -2
  113. package/dist/httpsnippet-lite/targets/ruby/native/client.js.map +7 -0
  114. package/dist/httpsnippet-lite/targets/shell/httpie/client.d.ts +12 -0
  115. package/dist/httpsnippet-lite/targets/shell/httpie/client.d.ts.map +1 -0
  116. package/dist/httpsnippet-lite/{esm/targets → targets}/shell/httpie/client.js +11 -11
  117. package/dist/httpsnippet-lite/targets/shell/httpie/client.js.map +7 -0
  118. package/dist/httpsnippet-lite/targets/shell/wget/client.d.ts +12 -0
  119. package/dist/httpsnippet-lite/targets/shell/wget/client.d.ts.map +1 -0
  120. package/dist/httpsnippet-lite/{esm/targets → targets}/shell/wget/client.js +6 -6
  121. package/dist/httpsnippet-lite/targets/shell/wget/client.js.map +7 -0
  122. package/dist/httpsnippet-lite/targets/swift/helpers.d.ts +15 -0
  123. package/dist/httpsnippet-lite/targets/swift/helpers.d.ts.map +1 -0
  124. package/dist/httpsnippet-lite/{esm/targets → targets}/swift/helpers.js +9 -16
  125. package/dist/httpsnippet-lite/targets/swift/helpers.js.map +7 -0
  126. package/dist/httpsnippet-lite/targets/swift/nsurlsession/client.d.ts +12 -0
  127. package/dist/httpsnippet-lite/targets/swift/nsurlsession/client.d.ts.map +1 -0
  128. package/dist/httpsnippet-lite/{esm/targets → targets}/swift/nsurlsession/client.js +11 -32
  129. package/dist/httpsnippet-lite/targets/swift/nsurlsession/client.js.map +7 -0
  130. package/dist/httpsnippet-lite/targets/target.d.ts +19 -0
  131. package/dist/httpsnippet-lite/targets/target.d.ts.map +1 -0
  132. package/dist/httpsnippet-lite/targets/target.js +1 -0
  133. package/dist/index.d.ts +2 -2
  134. package/dist/index.d.ts.map +1 -1
  135. package/dist/index.js +8 -2
  136. package/dist/index.js.map +2 -2
  137. package/dist/plugins/c/libcurl/index.d.ts +1 -1
  138. package/dist/plugins/c/libcurl/index.d.ts.map +1 -1
  139. package/dist/plugins/c/libcurl/index.js +4 -1
  140. package/dist/plugins/c/libcurl/index.js.map +2 -2
  141. package/dist/plugins/c/libcurl/libcurl.js +1 -1
  142. package/dist/plugins/c/libcurl/libcurl.js.map +1 -1
  143. package/dist/plugins/clojure/clj_http/clj_http.d.ts.map +1 -1
  144. package/dist/plugins/clojure/clj_http/clj_http.js +1 -1
  145. package/dist/plugins/clojure/clj_http/clj_http.js.map +2 -2
  146. package/dist/plugins/clojure/clj_http/index.d.ts +1 -1
  147. package/dist/plugins/clojure/clj_http/index.d.ts.map +1 -1
  148. package/dist/plugins/clojure/clj_http/index.js +4 -1
  149. package/dist/plugins/clojure/clj_http/index.js.map +2 -2
  150. package/dist/plugins/csharp/httpclient/index.d.ts +1 -1
  151. package/dist/plugins/csharp/httpclient/index.d.ts.map +1 -1
  152. package/dist/plugins/csharp/httpclient/index.js +4 -1
  153. package/dist/plugins/csharp/httpclient/index.js.map +2 -2
  154. package/dist/plugins/csharp/restsharp/index.d.ts +1 -1
  155. package/dist/plugins/csharp/restsharp/index.d.ts.map +1 -1
  156. package/dist/plugins/csharp/restsharp/index.js +4 -1
  157. package/dist/plugins/csharp/restsharp/index.js.map +2 -2
  158. package/dist/plugins/csharp/restsharp/restsharp.d.ts.map +1 -1
  159. package/dist/plugins/csharp/restsharp/restsharp.js +1 -1
  160. package/dist/plugins/csharp/restsharp/restsharp.js.map +2 -2
  161. package/dist/plugins/dart/http/index.d.ts +1 -1
  162. package/dist/plugins/dart/http/index.d.ts.map +1 -1
  163. package/dist/plugins/dart/http/index.js +4 -1
  164. package/dist/plugins/dart/http/index.js.map +2 -2
  165. package/dist/plugins/fsharp/httpclient/index.d.ts +1 -1
  166. package/dist/plugins/fsharp/httpclient/index.d.ts.map +1 -1
  167. package/dist/plugins/fsharp/httpclient/index.js +4 -1
  168. package/dist/plugins/fsharp/httpclient/index.js.map +2 -2
  169. package/dist/plugins/go/native/index.d.ts +1 -1
  170. package/dist/plugins/go/native/index.d.ts.map +1 -1
  171. package/dist/plugins/go/native/index.js +4 -1
  172. package/dist/plugins/go/native/index.js.map +2 -2
  173. package/dist/plugins/go/native/native.d.ts.map +1 -1
  174. package/dist/plugins/go/native/native.js +1 -1
  175. package/dist/plugins/go/native/native.js.map +2 -2
  176. package/dist/plugins/http/http11/index.d.ts +1 -1
  177. package/dist/plugins/http/http11/index.d.ts.map +1 -1
  178. package/dist/plugins/http/http11/index.js +4 -1
  179. package/dist/plugins/http/http11/index.js.map +2 -2
  180. package/dist/plugins/java/asynchttp/asynchttp.d.ts.map +1 -1
  181. package/dist/plugins/java/asynchttp/asynchttp.js +1 -1
  182. package/dist/plugins/java/asynchttp/asynchttp.js.map +2 -2
  183. package/dist/plugins/java/asynchttp/index.d.ts +1 -1
  184. package/dist/plugins/java/asynchttp/index.d.ts.map +1 -1
  185. package/dist/plugins/java/asynchttp/index.js +4 -1
  186. package/dist/plugins/java/asynchttp/index.js.map +2 -2
  187. package/dist/plugins/java/nethttp/index.d.ts +1 -1
  188. package/dist/plugins/java/nethttp/index.d.ts.map +1 -1
  189. package/dist/plugins/java/nethttp/index.js +4 -1
  190. package/dist/plugins/java/nethttp/index.js.map +2 -2
  191. package/dist/plugins/java/nethttp/nethttp.d.ts.map +1 -1
  192. package/dist/plugins/java/nethttp/nethttp.js +1 -1
  193. package/dist/plugins/java/nethttp/nethttp.js.map +2 -2
  194. package/dist/plugins/java/okhttp/index.d.ts +1 -1
  195. package/dist/plugins/java/okhttp/index.d.ts.map +1 -1
  196. package/dist/plugins/java/okhttp/index.js +4 -1
  197. package/dist/plugins/java/okhttp/index.js.map +2 -2
  198. package/dist/plugins/java/okhttp/okhttp.d.ts.map +1 -1
  199. package/dist/plugins/java/okhttp/okhttp.js +1 -1
  200. package/dist/plugins/java/okhttp/okhttp.js.map +2 -2
  201. package/dist/plugins/java/unirest/index.d.ts +1 -1
  202. package/dist/plugins/java/unirest/index.d.ts.map +1 -1
  203. package/dist/plugins/java/unirest/index.js +4 -1
  204. package/dist/plugins/java/unirest/index.js.map +2 -2
  205. package/dist/plugins/java/unirest/unirest.d.ts.map +1 -1
  206. package/dist/plugins/java/unirest/unirest.js +1 -1
  207. package/dist/plugins/java/unirest/unirest.js.map +2 -2
  208. package/dist/plugins/js/axios/axios.js +1 -1
  209. package/dist/plugins/js/axios/axios.js.map +1 -1
  210. package/dist/plugins/js/fetch/fetch.js +1 -1
  211. package/dist/plugins/js/fetch/fetch.js.map +2 -2
  212. package/dist/plugins/js/jquery/index.d.ts +1 -1
  213. package/dist/plugins/js/jquery/index.d.ts.map +1 -1
  214. package/dist/plugins/js/jquery/index.js +4 -1
  215. package/dist/plugins/js/jquery/index.js.map +2 -2
  216. package/dist/plugins/js/jquery/jquery.d.ts.map +1 -1
  217. package/dist/plugins/js/jquery/jquery.js +1 -1
  218. package/dist/plugins/js/jquery/jquery.js.map +2 -2
  219. package/dist/plugins/js/ofetch/index.d.ts +1 -1
  220. package/dist/plugins/js/ofetch/index.d.ts.map +1 -1
  221. package/dist/plugins/js/ofetch/index.js +4 -1
  222. package/dist/plugins/js/ofetch/index.js.map +2 -2
  223. package/dist/plugins/js/xhr/index.d.ts +1 -1
  224. package/dist/plugins/js/xhr/index.d.ts.map +1 -1
  225. package/dist/plugins/js/xhr/index.js +4 -1
  226. package/dist/plugins/js/xhr/index.js.map +2 -2
  227. package/dist/plugins/js/xhr/xhr.d.ts.map +1 -1
  228. package/dist/plugins/js/xhr/xhr.js +1 -1
  229. package/dist/plugins/js/xhr/xhr.js.map +2 -2
  230. package/dist/plugins/kotlin/okhttp/index.d.ts +1 -1
  231. package/dist/plugins/kotlin/okhttp/index.d.ts.map +1 -1
  232. package/dist/plugins/kotlin/okhttp/index.js +4 -1
  233. package/dist/plugins/kotlin/okhttp/index.js.map +2 -2
  234. package/dist/plugins/kotlin/okhttp/okhttp.d.ts.map +1 -1
  235. package/dist/plugins/kotlin/okhttp/okhttp.js +1 -1
  236. package/dist/plugins/kotlin/okhttp/okhttp.js.map +2 -2
  237. package/dist/plugins/node/axios/axios.js +1 -1
  238. package/dist/plugins/node/axios/axios.js.map +1 -1
  239. package/dist/plugins/node/axios/index.d.ts +1 -1
  240. package/dist/plugins/node/axios/index.d.ts.map +1 -1
  241. package/dist/plugins/node/axios/index.js +4 -1
  242. package/dist/plugins/node/axios/index.js.map +2 -2
  243. package/dist/plugins/node/fetch/fetch.js +1 -1
  244. package/dist/plugins/node/fetch/fetch.js.map +2 -2
  245. package/dist/plugins/node/fetch/index.d.ts +1 -1
  246. package/dist/plugins/node/fetch/index.d.ts.map +1 -1
  247. package/dist/plugins/node/fetch/index.js +4 -1
  248. package/dist/plugins/node/fetch/index.js.map +2 -2
  249. package/dist/plugins/node/ofetch/index.d.ts +1 -1
  250. package/dist/plugins/node/ofetch/index.d.ts.map +1 -1
  251. package/dist/plugins/node/ofetch/index.js +4 -1
  252. package/dist/plugins/node/ofetch/index.js.map +2 -2
  253. package/dist/plugins/node/undici/index.d.ts +1 -1
  254. package/dist/plugins/node/undici/index.d.ts.map +1 -1
  255. package/dist/plugins/node/undici/index.js +4 -1
  256. package/dist/plugins/node/undici/index.js.map +2 -2
  257. package/dist/plugins/node/undici/undici.js +1 -1
  258. package/dist/plugins/node/undici/undici.js.map +2 -2
  259. package/dist/plugins/objc/nsurlsession/index.d.ts +1 -1
  260. package/dist/plugins/objc/nsurlsession/index.d.ts.map +1 -1
  261. package/dist/plugins/objc/nsurlsession/index.js +4 -1
  262. package/dist/plugins/objc/nsurlsession/index.js.map +2 -2
  263. package/dist/plugins/objc/nsurlsession/nsurlsession.d.ts.map +1 -1
  264. package/dist/plugins/objc/nsurlsession/nsurlsession.js +1 -1
  265. package/dist/plugins/objc/nsurlsession/nsurlsession.js.map +2 -2
  266. package/dist/plugins/ocaml/cohttp/cohttp.d.ts.map +1 -1
  267. package/dist/plugins/ocaml/cohttp/cohttp.js +1 -1
  268. package/dist/plugins/ocaml/cohttp/cohttp.js.map +2 -2
  269. package/dist/plugins/ocaml/cohttp/index.d.ts +1 -1
  270. package/dist/plugins/ocaml/cohttp/index.d.ts.map +1 -1
  271. package/dist/plugins/ocaml/cohttp/index.js +4 -1
  272. package/dist/plugins/ocaml/cohttp/index.js.map +2 -2
  273. package/dist/plugins/php/curl/index.d.ts +1 -1
  274. package/dist/plugins/php/curl/index.d.ts.map +1 -1
  275. package/dist/plugins/php/curl/index.js +4 -1
  276. package/dist/plugins/php/curl/index.js.map +2 -2
  277. package/dist/plugins/php/guzzle/index.d.ts +1 -1
  278. package/dist/plugins/php/guzzle/index.d.ts.map +1 -1
  279. package/dist/plugins/php/guzzle/index.js +4 -1
  280. package/dist/plugins/php/guzzle/index.js.map +2 -2
  281. package/dist/plugins/powershell/restmethod/index.d.ts +1 -1
  282. package/dist/plugins/powershell/restmethod/index.d.ts.map +1 -1
  283. package/dist/plugins/powershell/restmethod/index.js +4 -1
  284. package/dist/plugins/powershell/restmethod/index.js.map +2 -2
  285. package/dist/plugins/powershell/restmethod/restmethod.d.ts.map +1 -1
  286. package/dist/plugins/powershell/restmethod/restmethod.js +1 -1
  287. package/dist/plugins/powershell/restmethod/restmethod.js.map +2 -2
  288. package/dist/plugins/powershell/webrequest/index.d.ts +1 -1
  289. package/dist/plugins/powershell/webrequest/index.d.ts.map +1 -1
  290. package/dist/plugins/powershell/webrequest/index.js +4 -1
  291. package/dist/plugins/powershell/webrequest/index.js.map +2 -2
  292. package/dist/plugins/powershell/webrequest/webrequest.d.ts.map +1 -1
  293. package/dist/plugins/powershell/webrequest/webrequest.js +1 -1
  294. package/dist/plugins/powershell/webrequest/webrequest.js.map +2 -2
  295. package/dist/plugins/python/httpx/async.d.ts.map +1 -1
  296. package/dist/plugins/python/httpx/async.js.map +2 -2
  297. package/dist/plugins/python/httpx/index.d.ts +2 -2
  298. package/dist/plugins/python/httpx/index.d.ts.map +1 -1
  299. package/dist/plugins/python/httpx/index.js +6 -2
  300. package/dist/plugins/python/httpx/index.js.map +2 -2
  301. package/dist/plugins/python/httpx/sync.d.ts.map +1 -1
  302. package/dist/plugins/python/httpx/sync.js.map +2 -2
  303. package/dist/plugins/python/python3/index.d.ts +1 -1
  304. package/dist/plugins/python/python3/index.d.ts.map +1 -1
  305. package/dist/plugins/python/python3/index.js +4 -1
  306. package/dist/plugins/python/python3/index.js.map +2 -2
  307. package/dist/plugins/python/python3/python3.d.ts.map +1 -1
  308. package/dist/plugins/python/python3/python3.js +1 -1
  309. package/dist/plugins/python/python3/python3.js.map +2 -2
  310. package/dist/plugins/python/requests/index.d.ts +1 -1
  311. package/dist/plugins/python/requests/index.d.ts.map +1 -1
  312. package/dist/plugins/python/requests/index.js +4 -1
  313. package/dist/plugins/python/requests/index.js.map +2 -2
  314. package/dist/plugins/python/requests/requests.d.ts.map +1 -1
  315. package/dist/plugins/python/requests/requests.js.map +2 -2
  316. package/dist/plugins/r/httr/httr.d.ts.map +1 -1
  317. package/dist/plugins/r/httr/httr.js +1 -1
  318. package/dist/plugins/r/httr/httr.js.map +2 -2
  319. package/dist/plugins/r/httr/index.d.ts +1 -1
  320. package/dist/plugins/r/httr/index.d.ts.map +1 -1
  321. package/dist/plugins/r/httr/index.js +4 -1
  322. package/dist/plugins/r/httr/index.js.map +2 -2
  323. package/dist/plugins/ruby/native/index.d.ts +1 -1
  324. package/dist/plugins/ruby/native/index.d.ts.map +1 -1
  325. package/dist/plugins/ruby/native/index.js +4 -1
  326. package/dist/plugins/ruby/native/index.js.map +2 -2
  327. package/dist/plugins/ruby/native/native.d.ts.map +1 -1
  328. package/dist/plugins/ruby/native/native.js +1 -1
  329. package/dist/plugins/ruby/native/native.js.map +2 -2
  330. package/dist/plugins/rust/reqwest/index.d.ts +1 -1
  331. package/dist/plugins/rust/reqwest/index.d.ts.map +1 -1
  332. package/dist/plugins/rust/reqwest/index.js +4 -1
  333. package/dist/plugins/rust/reqwest/index.js.map +2 -2
  334. package/dist/plugins/shell/curl/index.d.ts +1 -1
  335. package/dist/plugins/shell/curl/index.d.ts.map +1 -1
  336. package/dist/plugins/shell/curl/index.js +4 -1
  337. package/dist/plugins/shell/curl/index.js.map +2 -2
  338. package/dist/plugins/shell/httpie/httpie.d.ts.map +1 -1
  339. package/dist/plugins/shell/httpie/httpie.js +1 -1
  340. package/dist/plugins/shell/httpie/httpie.js.map +2 -2
  341. package/dist/plugins/shell/httpie/index.d.ts +1 -1
  342. package/dist/plugins/shell/httpie/index.d.ts.map +1 -1
  343. package/dist/plugins/shell/httpie/index.js +4 -1
  344. package/dist/plugins/shell/httpie/index.js.map +2 -2
  345. package/dist/plugins/shell/wget/index.d.ts +1 -1
  346. package/dist/plugins/shell/wget/index.d.ts.map +1 -1
  347. package/dist/plugins/shell/wget/index.js +4 -1
  348. package/dist/plugins/shell/wget/index.js.map +2 -2
  349. package/dist/plugins/shell/wget/wget.d.ts.map +1 -1
  350. package/dist/plugins/shell/wget/wget.js +1 -1
  351. package/dist/plugins/shell/wget/wget.js.map +2 -2
  352. package/dist/plugins/swift/nsurlsession/index.d.ts +1 -1
  353. package/dist/plugins/swift/nsurlsession/index.d.ts.map +1 -1
  354. package/dist/plugins/swift/nsurlsession/index.js +4 -1
  355. package/dist/plugins/swift/nsurlsession/index.js.map +2 -2
  356. package/dist/plugins/swift/nsurlsession/nsurlsession.d.ts.map +1 -1
  357. package/dist/plugins/swift/nsurlsession/nsurlsession.js +1 -1
  358. package/dist/plugins/swift/nsurlsession/nsurlsession.js.map +2 -2
  359. package/dist/snippetz.d.ts +2 -2
  360. package/dist/snippetz.d.ts.map +1 -1
  361. package/dist/snippetz.js.map +2 -2
  362. package/dist/utils/convertWithHttpSnippetLite.js +1 -1
  363. package/dist/utils/convertWithHttpSnippetLite.js.map +2 -2
  364. package/dist/utils/index.d.ts +1 -1
  365. package/dist/utils/index.d.ts.map +1 -1
  366. package/dist/utils/index.js +4 -1
  367. package/dist/utils/index.js.map +2 -2
  368. package/package.json +4 -3
  369. package/dist/httpsnippet-lite/esm/helpers/code-builder.d.ts +0 -8
  370. package/dist/httpsnippet-lite/esm/helpers/code-builder.d.ts.map +0 -1
  371. package/dist/httpsnippet-lite/esm/helpers/code-builder.js.map +0 -7
  372. package/dist/httpsnippet-lite/esm/helpers/escape.d.ts.map +0 -1
  373. package/dist/httpsnippet-lite/esm/helpers/escape.js.map +0 -7
  374. package/dist/httpsnippet-lite/esm/helpers/form-data.d.ts +0 -3
  375. package/dist/httpsnippet-lite/esm/helpers/form-data.d.ts.map +0 -1
  376. package/dist/httpsnippet-lite/esm/helpers/form-data.js +0 -59
  377. package/dist/httpsnippet-lite/esm/helpers/form-data.js.map +0 -7
  378. package/dist/httpsnippet-lite/esm/helpers/headers.d.ts +0 -17
  379. package/dist/httpsnippet-lite/esm/helpers/headers.d.ts.map +0 -1
  380. package/dist/httpsnippet-lite/esm/helpers/headers.js.map +0 -7
  381. package/dist/httpsnippet-lite/esm/helpers/reducer.d.ts +0 -2
  382. package/dist/httpsnippet-lite/esm/helpers/reducer.d.ts.map +0 -1
  383. package/dist/httpsnippet-lite/esm/helpers/reducer.js +0 -20
  384. package/dist/httpsnippet-lite/esm/helpers/reducer.js.map +0 -7
  385. package/dist/httpsnippet-lite/esm/helpers/shell.d.ts.map +0 -1
  386. package/dist/httpsnippet-lite/esm/helpers/shell.js.map +0 -7
  387. package/dist/httpsnippet-lite/esm/helpers/url.d.ts +0 -5
  388. package/dist/httpsnippet-lite/esm/helpers/url.d.ts.map +0 -1
  389. package/dist/httpsnippet-lite/esm/helpers/url.js +0 -20
  390. package/dist/httpsnippet-lite/esm/helpers/url.js.map +0 -7
  391. package/dist/httpsnippet-lite/esm/helpers/utils.d.ts +0 -3
  392. package/dist/httpsnippet-lite/esm/helpers/utils.d.ts.map +0 -1
  393. package/dist/httpsnippet-lite/esm/helpers/utils.js +0 -16
  394. package/dist/httpsnippet-lite/esm/helpers/utils.js.map +0 -7
  395. package/dist/httpsnippet-lite/esm/targets/c/libcurl/client.d.ts +0 -16
  396. package/dist/httpsnippet-lite/esm/targets/c/libcurl/client.d.ts.map +0 -1
  397. package/dist/httpsnippet-lite/esm/targets/c/libcurl/client.js.map +0 -7
  398. package/dist/httpsnippet-lite/esm/targets/c/target.d.ts +0 -26
  399. package/dist/httpsnippet-lite/esm/targets/c/target.d.ts.map +0 -1
  400. package/dist/httpsnippet-lite/esm/targets/c/target.js +0 -16
  401. package/dist/httpsnippet-lite/esm/targets/c/target.js.map +0 -7
  402. package/dist/httpsnippet-lite/esm/targets/clojure/clj_http/client.d.ts +0 -16
  403. package/dist/httpsnippet-lite/esm/targets/clojure/clj_http/client.d.ts.map +0 -1
  404. package/dist/httpsnippet-lite/esm/targets/clojure/clj_http/client.js.map +0 -7
  405. package/dist/httpsnippet-lite/esm/targets/clojure/target.d.ts +0 -26
  406. package/dist/httpsnippet-lite/esm/targets/clojure/target.d.ts.map +0 -1
  407. package/dist/httpsnippet-lite/esm/targets/clojure/target.js +0 -16
  408. package/dist/httpsnippet-lite/esm/targets/clojure/target.js.map +0 -7
  409. package/dist/httpsnippet-lite/esm/targets/csharp/restsharp/client.d.ts +0 -17
  410. package/dist/httpsnippet-lite/esm/targets/csharp/restsharp/client.d.ts.map +0 -1
  411. package/dist/httpsnippet-lite/esm/targets/csharp/restsharp/client.js.map +0 -7
  412. package/dist/httpsnippet-lite/esm/targets/csharp/target.d.ts +0 -27
  413. package/dist/httpsnippet-lite/esm/targets/csharp/target.d.ts.map +0 -1
  414. package/dist/httpsnippet-lite/esm/targets/csharp/target.js +0 -16
  415. package/dist/httpsnippet-lite/esm/targets/csharp/target.js.map +0 -7
  416. package/dist/httpsnippet-lite/esm/targets/go/native/client.d.ts +0 -15
  417. package/dist/httpsnippet-lite/esm/targets/go/native/client.d.ts.map +0 -1
  418. package/dist/httpsnippet-lite/esm/targets/go/native/client.js.map +0 -7
  419. package/dist/httpsnippet-lite/esm/targets/go/target.d.ts +0 -25
  420. package/dist/httpsnippet-lite/esm/targets/go/target.d.ts.map +0 -1
  421. package/dist/httpsnippet-lite/esm/targets/go/target.js +0 -16
  422. package/dist/httpsnippet-lite/esm/targets/go/target.js.map +0 -7
  423. package/dist/httpsnippet-lite/esm/targets/java/asynchttp/client.d.ts +0 -15
  424. package/dist/httpsnippet-lite/esm/targets/java/asynchttp/client.d.ts.map +0 -1
  425. package/dist/httpsnippet-lite/esm/targets/java/asynchttp/client.js.map +0 -7
  426. package/dist/httpsnippet-lite/esm/targets/java/nethttp/client.d.ts +0 -15
  427. package/dist/httpsnippet-lite/esm/targets/java/nethttp/client.d.ts.map +0 -1
  428. package/dist/httpsnippet-lite/esm/targets/java/nethttp/client.js.map +0 -7
  429. package/dist/httpsnippet-lite/esm/targets/java/okhttp/client.d.ts +0 -15
  430. package/dist/httpsnippet-lite/esm/targets/java/okhttp/client.d.ts.map +0 -1
  431. package/dist/httpsnippet-lite/esm/targets/java/okhttp/client.js.map +0 -7
  432. package/dist/httpsnippet-lite/esm/targets/java/target.d.ts +0 -67
  433. package/dist/httpsnippet-lite/esm/targets/java/target.d.ts.map +0 -1
  434. package/dist/httpsnippet-lite/esm/targets/java/target.js +0 -22
  435. package/dist/httpsnippet-lite/esm/targets/java/target.js.map +0 -7
  436. package/dist/httpsnippet-lite/esm/targets/java/unirest/client.d.ts +0 -15
  437. package/dist/httpsnippet-lite/esm/targets/java/unirest/client.d.ts.map +0 -1
  438. package/dist/httpsnippet-lite/esm/targets/java/unirest/client.js.map +0 -7
  439. package/dist/httpsnippet-lite/esm/targets/javascript/axios/client.d.ts +0 -16
  440. package/dist/httpsnippet-lite/esm/targets/javascript/axios/client.d.ts.map +0 -1
  441. package/dist/httpsnippet-lite/esm/targets/javascript/axios/client.js.map +0 -7
  442. package/dist/httpsnippet-lite/esm/targets/javascript/jquery/client.d.ts +0 -15
  443. package/dist/httpsnippet-lite/esm/targets/javascript/jquery/client.d.ts.map +0 -1
  444. package/dist/httpsnippet-lite/esm/targets/javascript/jquery/client.js.map +0 -7
  445. package/dist/httpsnippet-lite/esm/targets/javascript/target.d.ts +0 -55
  446. package/dist/httpsnippet-lite/esm/targets/javascript/target.d.ts.map +0 -1
  447. package/dist/httpsnippet-lite/esm/targets/javascript/target.js +0 -22
  448. package/dist/httpsnippet-lite/esm/targets/javascript/target.js.map +0 -7
  449. package/dist/httpsnippet-lite/esm/targets/javascript/xhr/client.d.ts +0 -15
  450. package/dist/httpsnippet-lite/esm/targets/javascript/xhr/client.d.ts.map +0 -1
  451. package/dist/httpsnippet-lite/esm/targets/javascript/xhr/client.js.map +0 -7
  452. package/dist/httpsnippet-lite/esm/targets/kotlin/okhttp/client.d.ts +0 -15
  453. package/dist/httpsnippet-lite/esm/targets/kotlin/okhttp/client.d.ts.map +0 -1
  454. package/dist/httpsnippet-lite/esm/targets/kotlin/okhttp/client.js.map +0 -7
  455. package/dist/httpsnippet-lite/esm/targets/kotlin/target.d.ts +0 -25
  456. package/dist/httpsnippet-lite/esm/targets/kotlin/target.d.ts.map +0 -1
  457. package/dist/httpsnippet-lite/esm/targets/kotlin/target.js +0 -16
  458. package/dist/httpsnippet-lite/esm/targets/kotlin/target.js.map +0 -7
  459. package/dist/httpsnippet-lite/esm/targets/node/axios/client.d.ts +0 -16
  460. package/dist/httpsnippet-lite/esm/targets/node/axios/client.d.ts.map +0 -1
  461. package/dist/httpsnippet-lite/esm/targets/node/axios/client.js.map +0 -7
  462. package/dist/httpsnippet-lite/esm/targets/node/request/client.d.ts +0 -17
  463. package/dist/httpsnippet-lite/esm/targets/node/request/client.d.ts.map +0 -1
  464. package/dist/httpsnippet-lite/esm/targets/node/request/client.js +0 -100
  465. package/dist/httpsnippet-lite/esm/targets/node/request/client.js.map +0 -7
  466. package/dist/httpsnippet-lite/esm/targets/node/target.d.ts +0 -45
  467. package/dist/httpsnippet-lite/esm/targets/node/target.d.ts.map +0 -1
  468. package/dist/httpsnippet-lite/esm/targets/node/target.js +0 -24
  469. package/dist/httpsnippet-lite/esm/targets/node/target.js.map +0 -7
  470. package/dist/httpsnippet-lite/esm/targets/objc/helpers.d.ts.map +0 -1
  471. package/dist/httpsnippet-lite/esm/targets/objc/helpers.js.map +0 -7
  472. package/dist/httpsnippet-lite/esm/targets/objc/nsurlsession/client.d.ts +0 -15
  473. package/dist/httpsnippet-lite/esm/targets/objc/nsurlsession/client.d.ts.map +0 -1
  474. package/dist/httpsnippet-lite/esm/targets/objc/nsurlsession/client.js.map +0 -7
  475. package/dist/httpsnippet-lite/esm/targets/objc/target.d.ts +0 -25
  476. package/dist/httpsnippet-lite/esm/targets/objc/target.d.ts.map +0 -1
  477. package/dist/httpsnippet-lite/esm/targets/objc/target.js +0 -16
  478. package/dist/httpsnippet-lite/esm/targets/objc/target.js.map +0 -7
  479. package/dist/httpsnippet-lite/esm/targets/ocaml/cohttp/client.d.ts +0 -15
  480. package/dist/httpsnippet-lite/esm/targets/ocaml/cohttp/client.d.ts.map +0 -1
  481. package/dist/httpsnippet-lite/esm/targets/ocaml/cohttp/client.js.map +0 -7
  482. package/dist/httpsnippet-lite/esm/targets/ocaml/target.d.ts +0 -25
  483. package/dist/httpsnippet-lite/esm/targets/ocaml/target.d.ts.map +0 -1
  484. package/dist/httpsnippet-lite/esm/targets/ocaml/target.js +0 -16
  485. package/dist/httpsnippet-lite/esm/targets/ocaml/target.js.map +0 -7
  486. package/dist/httpsnippet-lite/esm/targets/php/helpers.d.ts +0 -3
  487. package/dist/httpsnippet-lite/esm/targets/php/helpers.d.ts.map +0 -1
  488. package/dist/httpsnippet-lite/esm/targets/php/helpers.js +0 -72
  489. package/dist/httpsnippet-lite/esm/targets/php/helpers.js.map +0 -7
  490. package/dist/httpsnippet-lite/esm/targets/php/http1/client.d.ts +0 -17
  491. package/dist/httpsnippet-lite/esm/targets/php/http1/client.d.ts.map +0 -1
  492. package/dist/httpsnippet-lite/esm/targets/php/http1/client.js +0 -85
  493. package/dist/httpsnippet-lite/esm/targets/php/http1/client.js.map +0 -7
  494. package/dist/httpsnippet-lite/esm/targets/php/http2/client.d.ts +0 -17
  495. package/dist/httpsnippet-lite/esm/targets/php/http2/client.d.ts.map +0 -1
  496. package/dist/httpsnippet-lite/esm/targets/php/http2/client.js +0 -127
  497. package/dist/httpsnippet-lite/esm/targets/php/http2/client.js.map +0 -7
  498. package/dist/httpsnippet-lite/esm/targets/php/target.d.ts +0 -45
  499. package/dist/httpsnippet-lite/esm/targets/php/target.d.ts.map +0 -1
  500. package/dist/httpsnippet-lite/esm/targets/php/target.js +0 -22
  501. package/dist/httpsnippet-lite/esm/targets/php/target.js.map +0 -7
  502. package/dist/httpsnippet-lite/esm/targets/powershell/common.d.ts +0 -10
  503. package/dist/httpsnippet-lite/esm/targets/powershell/common.d.ts.map +0 -1
  504. package/dist/httpsnippet-lite/esm/targets/powershell/common.js.map +0 -7
  505. package/dist/httpsnippet-lite/esm/targets/powershell/restmethod/client.d.ts +0 -18
  506. package/dist/httpsnippet-lite/esm/targets/powershell/restmethod/client.d.ts.map +0 -1
  507. package/dist/httpsnippet-lite/esm/targets/powershell/restmethod/client.js.map +0 -7
  508. package/dist/httpsnippet-lite/esm/targets/powershell/target.d.ts +0 -45
  509. package/dist/httpsnippet-lite/esm/targets/powershell/target.d.ts.map +0 -1
  510. package/dist/httpsnippet-lite/esm/targets/powershell/target.js +0 -18
  511. package/dist/httpsnippet-lite/esm/targets/powershell/target.js.map +0 -7
  512. package/dist/httpsnippet-lite/esm/targets/powershell/webrequest/client.d.ts +0 -18
  513. package/dist/httpsnippet-lite/esm/targets/powershell/webrequest/client.d.ts.map +0 -1
  514. package/dist/httpsnippet-lite/esm/targets/powershell/webrequest/client.js.map +0 -7
  515. package/dist/httpsnippet-lite/esm/targets/python/helpers.d.ts +0 -9
  516. package/dist/httpsnippet-lite/esm/targets/python/helpers.d.ts.map +0 -1
  517. package/dist/httpsnippet-lite/esm/targets/python/helpers.js +0 -68
  518. package/dist/httpsnippet-lite/esm/targets/python/helpers.js.map +0 -7
  519. package/dist/httpsnippet-lite/esm/targets/python/python3/client.d.ts +0 -19
  520. package/dist/httpsnippet-lite/esm/targets/python/python3/client.d.ts.map +0 -1
  521. package/dist/httpsnippet-lite/esm/targets/python/python3/client.js.map +0 -7
  522. package/dist/httpsnippet-lite/esm/targets/python/target.d.ts +0 -29
  523. package/dist/httpsnippet-lite/esm/targets/python/target.d.ts.map +0 -1
  524. package/dist/httpsnippet-lite/esm/targets/python/target.js +0 -16
  525. package/dist/httpsnippet-lite/esm/targets/python/target.js.map +0 -7
  526. package/dist/httpsnippet-lite/esm/targets/r/httr/client.d.ts +0 -17
  527. package/dist/httpsnippet-lite/esm/targets/r/httr/client.d.ts.map +0 -1
  528. package/dist/httpsnippet-lite/esm/targets/r/httr/client.js.map +0 -7
  529. package/dist/httpsnippet-lite/esm/targets/r/target.d.ts +0 -27
  530. package/dist/httpsnippet-lite/esm/targets/r/target.d.ts.map +0 -1
  531. package/dist/httpsnippet-lite/esm/targets/r/target.js +0 -16
  532. package/dist/httpsnippet-lite/esm/targets/r/target.js.map +0 -7
  533. package/dist/httpsnippet-lite/esm/targets/ruby/native/client.d.ts +0 -16
  534. package/dist/httpsnippet-lite/esm/targets/ruby/native/client.d.ts.map +0 -1
  535. package/dist/httpsnippet-lite/esm/targets/ruby/native/client.js.map +0 -7
  536. package/dist/httpsnippet-lite/esm/targets/ruby/target.d.ts +0 -26
  537. package/dist/httpsnippet-lite/esm/targets/ruby/target.d.ts.map +0 -1
  538. package/dist/httpsnippet-lite/esm/targets/ruby/target.js +0 -16
  539. package/dist/httpsnippet-lite/esm/targets/ruby/target.js.map +0 -7
  540. package/dist/httpsnippet-lite/esm/targets/shell/httpie/client.d.ts +0 -17
  541. package/dist/httpsnippet-lite/esm/targets/shell/httpie/client.d.ts.map +0 -1
  542. package/dist/httpsnippet-lite/esm/targets/shell/httpie/client.js.map +0 -7
  543. package/dist/httpsnippet-lite/esm/targets/shell/target.d.ts +0 -42
  544. package/dist/httpsnippet-lite/esm/targets/shell/target.d.ts.map +0 -1
  545. package/dist/httpsnippet-lite/esm/targets/shell/target.js +0 -20
  546. package/dist/httpsnippet-lite/esm/targets/shell/target.js.map +0 -7
  547. package/dist/httpsnippet-lite/esm/targets/shell/wget/client.d.ts +0 -15
  548. package/dist/httpsnippet-lite/esm/targets/shell/wget/client.d.ts.map +0 -1
  549. package/dist/httpsnippet-lite/esm/targets/shell/wget/client.js.map +0 -7
  550. package/dist/httpsnippet-lite/esm/targets/swift/helpers.d.ts +0 -17
  551. package/dist/httpsnippet-lite/esm/targets/swift/helpers.d.ts.map +0 -1
  552. package/dist/httpsnippet-lite/esm/targets/swift/helpers.js.map +0 -7
  553. package/dist/httpsnippet-lite/esm/targets/swift/nsurlsession/client.d.ts +0 -15
  554. package/dist/httpsnippet-lite/esm/targets/swift/nsurlsession/client.d.ts.map +0 -1
  555. package/dist/httpsnippet-lite/esm/targets/swift/nsurlsession/client.js.map +0 -7
  556. package/dist/httpsnippet-lite/esm/targets/swift/target.d.ts +0 -25
  557. package/dist/httpsnippet-lite/esm/targets/swift/target.d.ts.map +0 -1
  558. package/dist/httpsnippet-lite/esm/targets/swift/target.js +0 -16
  559. package/dist/httpsnippet-lite/esm/targets/swift/target.js.map +0 -7
  560. package/dist/httpsnippet-lite/types/helpers/code-builder.d.js +0 -1
  561. package/dist/httpsnippet-lite/types/helpers/escape.d.js +0 -1
  562. package/dist/httpsnippet-lite/types/helpers/form-data.d.js +0 -28
  563. package/dist/httpsnippet-lite/types/helpers/form-data.d.js.map +0 -7
  564. package/dist/httpsnippet-lite/types/helpers/headers.d.js +0 -1
  565. package/dist/httpsnippet-lite/types/helpers/reducer.d.js +0 -1
  566. package/dist/httpsnippet-lite/types/helpers/reducer.d.js.map +0 -7
  567. package/dist/httpsnippet-lite/types/helpers/shell.d.js +0 -1
  568. package/dist/httpsnippet-lite/types/helpers/shell.d.js.map +0 -7
  569. package/dist/httpsnippet-lite/types/helpers/url.d.js +0 -1
  570. package/dist/httpsnippet-lite/types/helpers/url.d.js.map +0 -7
  571. package/dist/httpsnippet-lite/types/helpers/utils.d.js +0 -1
  572. package/dist/httpsnippet-lite/types/helpers/utils.d.js.map +0 -7
  573. package/dist/httpsnippet-lite/types/httpsnippet.d.js +0 -19
  574. package/dist/httpsnippet-lite/types/httpsnippet.d.js.map +0 -7
  575. package/dist/httpsnippet-lite/types/targets/c/libcurl/client.d.js +0 -1
  576. package/dist/httpsnippet-lite/types/targets/c/libcurl/client.d.js.map +0 -7
  577. package/dist/httpsnippet-lite/types/targets/c/target.d.js +0 -1
  578. package/dist/httpsnippet-lite/types/targets/c/target.d.js.map +0 -7
  579. package/dist/httpsnippet-lite/types/targets/clojure/clj_http/client.d.js +0 -1
  580. package/dist/httpsnippet-lite/types/targets/clojure/clj_http/client.d.js.map +0 -7
  581. package/dist/httpsnippet-lite/types/targets/clojure/target.d.js +0 -1
  582. package/dist/httpsnippet-lite/types/targets/clojure/target.d.js.map +0 -7
  583. package/dist/httpsnippet-lite/types/targets/csharp/restsharp/client.d.js +0 -1
  584. package/dist/httpsnippet-lite/types/targets/csharp/restsharp/client.d.js.map +0 -7
  585. package/dist/httpsnippet-lite/types/targets/csharp/target.d.js +0 -1
  586. package/dist/httpsnippet-lite/types/targets/csharp/target.d.js.map +0 -7
  587. package/dist/httpsnippet-lite/types/targets/dart/http/client.d.js +0 -1
  588. package/dist/httpsnippet-lite/types/targets/dart/http/client.d.js.map +0 -7
  589. package/dist/httpsnippet-lite/types/targets/dart/target.d.js +0 -1
  590. package/dist/httpsnippet-lite/types/targets/dart/target.d.js.map +0 -7
  591. package/dist/httpsnippet-lite/types/targets/go/native/client.d.js +0 -1
  592. package/dist/httpsnippet-lite/types/targets/go/native/client.d.js.map +0 -7
  593. package/dist/httpsnippet-lite/types/targets/go/target.d.js +0 -1
  594. package/dist/httpsnippet-lite/types/targets/go/target.d.js.map +0 -7
  595. package/dist/httpsnippet-lite/types/targets/http/http1.1/client.d.js +0 -1
  596. package/dist/httpsnippet-lite/types/targets/http/http1.1/client.d.js.map +0 -7
  597. package/dist/httpsnippet-lite/types/targets/http/target.d.js +0 -1
  598. package/dist/httpsnippet-lite/types/targets/http/target.d.js.map +0 -7
  599. package/dist/httpsnippet-lite/types/targets/java/asynchttp/client.d.js +0 -1
  600. package/dist/httpsnippet-lite/types/targets/java/asynchttp/client.d.js.map +0 -7
  601. package/dist/httpsnippet-lite/types/targets/java/nethttp/client.d.js +0 -1
  602. package/dist/httpsnippet-lite/types/targets/java/nethttp/client.d.js.map +0 -7
  603. package/dist/httpsnippet-lite/types/targets/java/okhttp/client.d.js +0 -1
  604. package/dist/httpsnippet-lite/types/targets/java/okhttp/client.d.js.map +0 -7
  605. package/dist/httpsnippet-lite/types/targets/java/target.d.js +0 -1
  606. package/dist/httpsnippet-lite/types/targets/java/target.d.js.map +0 -7
  607. package/dist/httpsnippet-lite/types/targets/java/unirest/client.d.js +0 -1
  608. package/dist/httpsnippet-lite/types/targets/java/unirest/client.d.js.map +0 -7
  609. package/dist/httpsnippet-lite/types/targets/javascript/axios/client.d.js +0 -1
  610. package/dist/httpsnippet-lite/types/targets/javascript/axios/client.d.js.map +0 -7
  611. package/dist/httpsnippet-lite/types/targets/javascript/fetch/client.d.js +0 -1
  612. package/dist/httpsnippet-lite/types/targets/javascript/fetch/client.d.js.map +0 -7
  613. package/dist/httpsnippet-lite/types/targets/javascript/jquery/client.d.js +0 -1
  614. package/dist/httpsnippet-lite/types/targets/javascript/jquery/client.d.js.map +0 -7
  615. package/dist/httpsnippet-lite/types/targets/javascript/target.d.js +0 -1
  616. package/dist/httpsnippet-lite/types/targets/javascript/target.d.js.map +0 -7
  617. package/dist/httpsnippet-lite/types/targets/javascript/xhr/client.d.js +0 -1
  618. package/dist/httpsnippet-lite/types/targets/javascript/xhr/client.d.js.map +0 -7
  619. package/dist/httpsnippet-lite/types/targets/kotlin/okhttp/client.d.js +0 -1
  620. package/dist/httpsnippet-lite/types/targets/kotlin/okhttp/client.d.js.map +0 -7
  621. package/dist/httpsnippet-lite/types/targets/kotlin/target.d.js +0 -1
  622. package/dist/httpsnippet-lite/types/targets/kotlin/target.d.js.map +0 -7
  623. package/dist/httpsnippet-lite/types/targets/node/axios/client.d.js +0 -1
  624. package/dist/httpsnippet-lite/types/targets/node/axios/client.d.js.map +0 -7
  625. package/dist/httpsnippet-lite/types/targets/node/fetch/client.d.js +0 -1
  626. package/dist/httpsnippet-lite/types/targets/node/fetch/client.d.js.map +0 -7
  627. package/dist/httpsnippet-lite/types/targets/node/native/client.d.js +0 -1
  628. package/dist/httpsnippet-lite/types/targets/node/native/client.d.js.map +0 -7
  629. package/dist/httpsnippet-lite/types/targets/node/request/client.d.js +0 -1
  630. package/dist/httpsnippet-lite/types/targets/node/request/client.d.js.map +0 -7
  631. package/dist/httpsnippet-lite/types/targets/node/target.d.js +0 -1
  632. package/dist/httpsnippet-lite/types/targets/node/target.d.js.map +0 -7
  633. package/dist/httpsnippet-lite/types/targets/node/unirest/client.d.js +0 -1
  634. package/dist/httpsnippet-lite/types/targets/node/unirest/client.d.js.map +0 -7
  635. package/dist/httpsnippet-lite/types/targets/objc/helpers.d.js +0 -1
  636. package/dist/httpsnippet-lite/types/targets/objc/helpers.d.js.map +0 -7
  637. package/dist/httpsnippet-lite/types/targets/objc/nsurlsession/client.d.js +0 -1
  638. package/dist/httpsnippet-lite/types/targets/objc/nsurlsession/client.d.js.map +0 -7
  639. package/dist/httpsnippet-lite/types/targets/objc/target.d.js +0 -1
  640. package/dist/httpsnippet-lite/types/targets/objc/target.d.js.map +0 -7
  641. package/dist/httpsnippet-lite/types/targets/ocaml/cohttp/client.d.js +0 -1
  642. package/dist/httpsnippet-lite/types/targets/ocaml/cohttp/client.d.js.map +0 -7
  643. package/dist/httpsnippet-lite/types/targets/ocaml/target.d.js +0 -1
  644. package/dist/httpsnippet-lite/types/targets/ocaml/target.d.js.map +0 -7
  645. package/dist/httpsnippet-lite/types/targets/php/curl/client.d.js +0 -1
  646. package/dist/httpsnippet-lite/types/targets/php/curl/client.d.js.map +0 -7
  647. package/dist/httpsnippet-lite/types/targets/php/guzzle/client.d.js +0 -1
  648. package/dist/httpsnippet-lite/types/targets/php/guzzle/client.d.js.map +0 -7
  649. package/dist/httpsnippet-lite/types/targets/php/helpers.d.js +0 -1
  650. package/dist/httpsnippet-lite/types/targets/php/helpers.d.js.map +0 -7
  651. package/dist/httpsnippet-lite/types/targets/php/http1/client.d.js +0 -1
  652. package/dist/httpsnippet-lite/types/targets/php/http1/client.d.js.map +0 -7
  653. package/dist/httpsnippet-lite/types/targets/php/http2/client.d.js +0 -1
  654. package/dist/httpsnippet-lite/types/targets/php/http2/client.d.js.map +0 -7
  655. package/dist/httpsnippet-lite/types/targets/php/target.d.js +0 -1
  656. package/dist/httpsnippet-lite/types/targets/php/target.d.js.map +0 -7
  657. package/dist/httpsnippet-lite/types/targets/powershell/common.d.js +0 -1
  658. package/dist/httpsnippet-lite/types/targets/powershell/common.d.js.map +0 -7
  659. package/dist/httpsnippet-lite/types/targets/powershell/restmethod/client.d.js +0 -1
  660. package/dist/httpsnippet-lite/types/targets/powershell/restmethod/client.d.js.map +0 -7
  661. package/dist/httpsnippet-lite/types/targets/powershell/target.d.js +0 -1
  662. package/dist/httpsnippet-lite/types/targets/powershell/target.d.js.map +0 -7
  663. package/dist/httpsnippet-lite/types/targets/powershell/webrequest/client.d.js +0 -1
  664. package/dist/httpsnippet-lite/types/targets/powershell/webrequest/client.d.js.map +0 -7
  665. package/dist/httpsnippet-lite/types/targets/python/helpers.d.js +0 -1
  666. package/dist/httpsnippet-lite/types/targets/python/helpers.d.js.map +0 -7
  667. package/dist/httpsnippet-lite/types/targets/python/python3/client.d.js +0 -1
  668. package/dist/httpsnippet-lite/types/targets/python/python3/client.d.js.map +0 -7
  669. package/dist/httpsnippet-lite/types/targets/python/requests/client.d.js +0 -1
  670. package/dist/httpsnippet-lite/types/targets/python/requests/client.d.js.map +0 -7
  671. package/dist/httpsnippet-lite/types/targets/python/target.d.js +0 -1
  672. package/dist/httpsnippet-lite/types/targets/python/target.d.js.map +0 -7
  673. package/dist/httpsnippet-lite/types/targets/r/httr/client.d.js +0 -1
  674. package/dist/httpsnippet-lite/types/targets/r/httr/client.d.js.map +0 -7
  675. package/dist/httpsnippet-lite/types/targets/r/target.d.js +0 -1
  676. package/dist/httpsnippet-lite/types/targets/r/target.d.js.map +0 -7
  677. package/dist/httpsnippet-lite/types/targets/ruby/native/client.d.js +0 -1
  678. package/dist/httpsnippet-lite/types/targets/ruby/native/client.d.js.map +0 -7
  679. package/dist/httpsnippet-lite/types/targets/ruby/target.d.js +0 -1
  680. package/dist/httpsnippet-lite/types/targets/ruby/target.d.js.map +0 -7
  681. package/dist/httpsnippet-lite/types/targets/shell/curl/client.d.js +0 -1
  682. package/dist/httpsnippet-lite/types/targets/shell/curl/client.d.js.map +0 -7
  683. package/dist/httpsnippet-lite/types/targets/shell/httpie/client.d.js +0 -1
  684. package/dist/httpsnippet-lite/types/targets/shell/httpie/client.d.js.map +0 -7
  685. package/dist/httpsnippet-lite/types/targets/shell/target.d.js +0 -1
  686. package/dist/httpsnippet-lite/types/targets/shell/target.d.js.map +0 -7
  687. package/dist/httpsnippet-lite/types/targets/shell/wget/client.d.js +0 -1
  688. package/dist/httpsnippet-lite/types/targets/shell/wget/client.d.js.map +0 -7
  689. package/dist/httpsnippet-lite/types/targets/swift/helpers.d.js +0 -1
  690. package/dist/httpsnippet-lite/types/targets/swift/helpers.d.js.map +0 -7
  691. package/dist/httpsnippet-lite/types/targets/swift/nsurlsession/client.d.js +0 -1
  692. package/dist/httpsnippet-lite/types/targets/swift/nsurlsession/client.d.js.map +0 -7
  693. package/dist/httpsnippet-lite/types/targets/swift/target.d.js +0 -1
  694. package/dist/httpsnippet-lite/types/targets/swift/target.d.js.map +0 -7
  695. package/dist/httpsnippet-lite/types/targets/targets.d.js +0 -1
  696. package/dist/httpsnippet-lite/types/targets/targets.d.js.map +0 -7
  697. /package/dist/httpsnippet-lite/{esm/helpers → helpers}/escape.js +0 -0
  698. /package/dist/httpsnippet-lite/{types/helpers/code-builder.d.js.map → helpers/reducer.js.map} +0 -0
  699. /package/dist/httpsnippet-lite/{types/helpers/escape.d.js.map → helpers/snippet-request.js.map} +0 -0
  700. /package/dist/httpsnippet-lite/{esm/targets → targets}/powershell/restmethod/client.js +0 -0
  701. /package/dist/httpsnippet-lite/{esm/targets → targets}/powershell/webrequest/client.js +0 -0
  702. /package/dist/httpsnippet-lite/{types/helpers/headers.d.js.map → targets/target.js.map} +0 -0
@@ -1,26 +0,0 @@
1
- export declare const c: {
2
- info: {
3
- key: string;
4
- title: string;
5
- extname: string;
6
- default: string;
7
- };
8
- clientsById: {
9
- libcurl: {
10
- info: {
11
- key: string;
12
- title: string;
13
- link: string;
14
- description: string;
15
- };
16
- convert: ({ method, fullUrl, headersObj, allHeaders, postData }: {
17
- method: any;
18
- fullUrl: any;
19
- headersObj: any;
20
- allHeaders: any;
21
- postData: any;
22
- }) => any;
23
- };
24
- };
25
- };
26
- //# sourceMappingURL=target.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../../../../../src/httpsnippet-lite/esm/targets/c/target.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,CAAC;;;;;;;;;;;;;;;;;;;;;;;;CAUb,CAAA"}
@@ -1,16 +0,0 @@
1
- import { libcurl } from "./libcurl/client.js";
2
- const c = {
3
- info: {
4
- key: "c",
5
- title: "C",
6
- extname: ".c",
7
- default: "libcurl"
8
- },
9
- clientsById: {
10
- libcurl
11
- }
12
- };
13
- export {
14
- c
15
- };
16
- //# sourceMappingURL=target.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../src/httpsnippet-lite/esm/targets/c/target.ts"],
4
- "sourcesContent": ["// @ts-nocheck\nimport { libcurl } from './libcurl/client.js'\n\nexport const c = {\n info: {\n key: 'c',\n title: 'C',\n extname: '.c',\n default: 'libcurl',\n },\n clientsById: {\n libcurl,\n },\n}\n"],
5
- "mappings": "AACA,SAAS,eAAe;AAEjB,MAAM,IAAI;AAAA,EACf,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,SAAS;AAAA,IACT,SAAS;AAAA,EACX;AAAA,EACA,aAAa;AAAA,IACX;AAAA,EACF;AACF;",
6
- "names": []
7
- }
@@ -1,16 +0,0 @@
1
- export declare const clj_http: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ queryObj, method, postData, url, allHeaders }: {
9
- queryObj: any;
10
- method: any;
11
- postData: any;
12
- url: any;
13
- allHeaders: any;
14
- }, options: any) => any;
15
- };
16
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/clojure/clj_http/client.ts"],"names":[],"mappings":"AAuFA,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;CAqGpB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/clojure/clj_http/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\n/**\n * @description\n * HTTP code snippet generator for Clojure using clj-http.\n *\n * @author\n * @tggreene\n *\n * for any questions or issues regarding the generated code snippet, please open an issue mentioning the author.\n */\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { getHeader, getHeaderName } from '../../../helpers/headers.js'\n\nclass Keyword {\n constructor(name) {\n this.name = ''\n this.toString = () => `:${this.name}`\n this.name = name\n }\n}\nclass File {\n constructor(path) {\n this.path = ''\n this.toString = () => `(clojure.java.io/file \"${this.path}\")`\n this.path = path\n }\n}\nconst jsType = (input) => {\n if (input === undefined) {\n return null\n }\n if (input === null) {\n return 'null'\n }\n return input.constructor.name.toLowerCase()\n}\nconst objEmpty = (input) => {\n if (jsType(input) === 'object') {\n return Object.keys(input).length === 0\n }\n return false\n}\nconst filterEmpty = (input) => {\n Object.keys(input)\n .filter((x) => objEmpty(input[x]))\n .forEach((x) => {\n delete input[x]\n })\n return input\n}\nconst padBlock = (padSize, input) => {\n const padding = ' '.repeat(padSize)\n return input.replace(/\\n/g, `\\n${padding}`)\n}\nconst jsToEdn = (js) => {\n switch (jsType(js)) {\n case 'string':\n return `\"${js.replace(/\"/g, '\\\\\"')}\"`\n case 'file':\n return js.toString()\n case 'keyword':\n return js.toString()\n case 'null':\n return 'nil'\n case 'regexp':\n return `#\"${js.source}\"`\n case 'object': {\n // simple vertical format\n const obj = Object.keys(js)\n .reduce((accumulator, key) => {\n const val = padBlock(key.length + 2, jsToEdn(js[key]))\n return `${accumulator}:${key} ${val}\\n `\n }, '')\n .trim()\n return `{${padBlock(1, obj)}}`\n }\n case 'array': {\n // simple horizontal format\n const arr = js\n .reduce((accumulator, value) => `${accumulator} ${jsToEdn(value)}`, '')\n .trim()\n return `[${padBlock(1, arr)}]`\n }\n default: // 'number' 'boolean'\n return js.toString()\n }\n}\nexport const clj_http = {\n info: {\n key: 'clj_http',\n title: 'clj-http',\n link: 'https://github.com/dakrone/clj-http',\n description: 'An idiomatic clojure http client wrapping the apache client.',\n },\n convert: ({ queryObj, method, postData, url, allHeaders }, options) => {\n const { push, join } = new CodeBuilder({\n indent: options === null || options === void 0 ? void 0 : options.indent,\n })\n const methods = ['get', 'post', 'put', 'delete', 'patch', 'head', 'options']\n method = method.toLowerCase()\n if (!methods.includes(method)) {\n push('Method not supported')\n return join()\n }\n const params = {\n 'headers': allHeaders,\n 'query-params': queryObj,\n }\n\n // Remove query string from URL if queryObj has parameters\n if (queryObj && Object.keys(queryObj).length > 0) {\n url = url.split('?')[0]\n }\n\n switch (\n postData === null || postData === void 0 ? void 0 : postData.mimeType\n ) {\n case 'application/json':\n {\n params['content-type'] = new Keyword('json')\n params['form-params'] = postData.jsonObj\n const header = getHeaderName(params.headers, 'content-type')\n if (header) {\n delete params.headers[header]\n }\n }\n break\n case 'application/x-www-form-urlencoded':\n {\n params['form-params'] = postData.paramsObj\n const header = getHeaderName(params.headers, 'content-type')\n if (header) {\n delete params.headers[header]\n }\n }\n break\n case 'text/plain':\n {\n params.body = postData.text\n const header = getHeaderName(params.headers, 'content-type')\n if (header) {\n delete params.headers[header]\n }\n }\n break\n case 'multipart/form-data': {\n if (postData.params) {\n params.multipart = postData.params.map((param) => {\n if (param.fileName && !param.value) {\n return {\n name: param.name,\n content: new File(param.fileName),\n }\n }\n return {\n name: param.name,\n content: param.value,\n }\n })\n const header = getHeaderName(params.headers, 'content-type')\n if (header) {\n delete params.headers[header]\n }\n }\n break\n }\n }\n switch (getHeader(params.headers, 'accept')) {\n case 'application/json':\n {\n params.accept = new Keyword('json')\n const header = getHeaderName(params.headers, 'accept')\n if (header) {\n delete params.headers[header]\n }\n }\n break\n }\n push(\"(require '[clj-http.client :as client])\\n\")\n if (objEmpty(filterEmpty(params))) {\n push(`(client/${method} \"${url}\")`)\n } else {\n const padding = 11 + method.length + url.length\n const formattedParams = padBlock(padding, jsToEdn(filterEmpty(params)))\n push(`(client/${method} \"${url}\" ${formattedParams})`)\n }\n return join()\n },\n}\n"],
5
- "mappings": "AAUA,SAAS,mBAAmB;AAC5B,SAAS,WAAW,qBAAqB;AAEzC,MAAM,QAAQ;AAAA,EACZ,YAAY,MAAM;AAChB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AACA,SAAK,2CAA2C;AAChD,QAAI,SAAS,YAAY,MAAM,CAAC,GAAG;AACjC,WAAK,WAAW,MAAM,KAAK,GAAG,IAAI;AAAA,IACpC,OAAO;AACL,YAAM,UAAU,KAAK,OAAO,SAAS,IAAI;AACzC,YAAM,kBAAkB,SAAS,SAAS,QAAQ,YAAY,MAAM,CAAC,CAAC;AACtE,WAAK,WAAW,MAAM,KAAK,GAAG,KAAK,eAAe,GAAG;AAAA,IACvD;AACA,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }
@@ -1,26 +0,0 @@
1
- export declare const clojure: {
2
- info: {
3
- key: string;
4
- title: string;
5
- extname: string;
6
- default: string;
7
- };
8
- clientsById: {
9
- clj_http: {
10
- info: {
11
- key: string;
12
- title: string;
13
- link: string;
14
- description: string;
15
- };
16
- convert: ({ queryObj, method, postData, url, allHeaders }: {
17
- queryObj: any;
18
- method: any;
19
- postData: any;
20
- url: any;
21
- allHeaders: any;
22
- }, options: any) => any;
23
- };
24
- };
25
- };
26
- //# sourceMappingURL=target.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../../../../../src/httpsnippet-lite/esm/targets/clojure/target.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,OAAO;;;;;;;;;;;;;;;;;;;;;;;;CAUnB,CAAA"}
@@ -1,16 +0,0 @@
1
- import { clj_http } from "./clj_http/client.js";
2
- const clojure = {
3
- info: {
4
- key: "clojure",
5
- title: "Clojure",
6
- extname: ".clj",
7
- default: "clj_http"
8
- },
9
- clientsById: {
10
- clj_http
11
- }
12
- };
13
- export {
14
- clojure
15
- };
16
- //# sourceMappingURL=target.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../src/httpsnippet-lite/esm/targets/clojure/target.ts"],
4
- "sourcesContent": ["// @ts-nocheck\nimport { clj_http } from './clj_http/client.js'\n\nexport const clojure = {\n info: {\n key: 'clojure',\n title: 'Clojure',\n extname: '.clj',\n default: 'clj_http',\n },\n clientsById: {\n clj_http,\n },\n}\n"],
5
- "mappings": "AACA,SAAS,gBAAgB;AAElB,MAAM,UAAU;AAAA,EACrB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,SAAS;AAAA,IACT,SAAS;AAAA,EACX;AAAA,EACA,aAAa;AAAA,IACX;AAAA,EACF;AACF;",
6
- "names": []
7
- }
@@ -1,17 +0,0 @@
1
- export declare const restsharp: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ allHeaders, method, fullUrl, headersObj, cookies, postData }: {
9
- allHeaders: any;
10
- method: any;
11
- fullUrl: any;
12
- headersObj: any;
13
- cookies: any;
14
- postData: any;
15
- }) => any;
16
- };
17
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/csharp/restsharp/client.ts"],"names":[],"mappings":"AAKA,eAAO,MAAM,SAAS;;;;;;;;;;;;;;;CA4CrB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/csharp/restsharp/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { escapeForDoubleQuotes } from '../../../helpers/escape.js'\nimport { getHeader } from '../../../helpers/headers.js'\n\nexport const restsharp = {\n info: {\n key: 'restsharp',\n title: 'RestSharp',\n link: 'http://restsharp.org/',\n description: 'Simple REST and HTTP API Client for .NET',\n },\n convert: ({ allHeaders, method, fullUrl, headersObj, cookies, postData }) => {\n const { push, join } = new CodeBuilder()\n const isSupportedMethod = [\n 'GET',\n 'POST',\n 'PUT',\n 'DELETE',\n 'PATCH',\n 'HEAD',\n 'OPTIONS',\n ].includes(method.toUpperCase())\n if (!isSupportedMethod) {\n return 'Method not supported'\n }\n push(`var client = new RestClient(\"${fullUrl}\");`)\n push(`var request = new RestRequest(Method.${method.toUpperCase()});`)\n // Add headers, including the cookies\n Object.keys(headersObj).forEach((key) => {\n push(\n `request.AddHeader(\"${key}\", \"${escapeForDoubleQuotes(headersObj[key])}\");`,\n )\n })\n cookies === null || cookies === void 0\n ? void 0\n : cookies.forEach(({ name, value }) => {\n push(`request.AddCookie(\"${name}\", \"${value}\");`)\n })\n if (postData === null || postData === void 0 ? void 0 : postData.text) {\n const header = getHeader(allHeaders, 'content-type')\n const text = JSON.stringify(postData.text)\n push(\n `request.AddParameter(\"${header}\", ${text}, ParameterType.RequestBody);`,\n )\n }\n push('IRestResponse response = client.Execute(request);')\n return join()\n },\n}\n"],
5
- "mappings": "AACA,SAAS,mBAAmB;AAC5B,SAAS,6BAA6B;AACtC,SAAS,iBAAiB;AAEnB,MAAM,YAAY;AAAA,EACvB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,IACN,aAAa;AAAA,EACf;AAAA,EACA,SAAS,CAAC,EAAE,YAAY,QAAQ,SAAS,YAAY,SAAS,SAAS,MAAM;AAC3E,UAAM,EAAE,MAAM,KAAK,IAAI,IAAI,YAAY;AACvC,UAAM,oBAAoB;AAAA,MACxB;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,MACA;AAAA,IACF,EAAE,SAAS,OAAO,YAAY,CAAC;AAC/B,QAAI,CAAC,mBAAmB;AACtB,aAAO;AAAA,IACT;AACA,SAAK,gCAAgC,OAAO,KAAK;AACjD,SAAK,wCAAwC,OAAO,YAAY,CAAC,IAAI;AAErE,WAAO,KAAK,UAAU,EAAE,QAAQ,CAAC,QAAQ;AACvC;AAAA,QACE,sBAAsB,GAAG,OAAO,sBAAsB,WAAW,GAAG,CAAC,CAAC;AAAA,MACxE;AAAA,IACF,CAAC;AACD,gBAAY,QAAQ,YAAY,SAC5B,SACA,QAAQ,QAAQ,CAAC,EAAE,MAAM,MAAM,MAAM;AACnC,WAAK,sBAAsB,IAAI,OAAO,KAAK,KAAK;AAAA,IAClD,CAAC;AACL,QAAI,aAAa,QAAQ,aAAa,SAAS,SAAS,SAAS,MAAM;AACrE,YAAM,SAAS,UAAU,YAAY,cAAc;AACnD,YAAM,OAAO,KAAK,UAAU,SAAS,IAAI;AACzC;AAAA,QACE,yBAAyB,MAAM,MAAM,IAAI;AAAA,MAC3C;AAAA,IACF;AACA,SAAK,mDAAmD;AACxD,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }
@@ -1,27 +0,0 @@
1
- export declare const csharp: {
2
- info: {
3
- key: string;
4
- title: string;
5
- extname: string;
6
- default: string;
7
- };
8
- clientsById: {
9
- restsharp: {
10
- info: {
11
- key: string;
12
- title: string;
13
- link: string;
14
- description: string;
15
- };
16
- convert: ({ allHeaders, method, fullUrl, headersObj, cookies, postData }: {
17
- allHeaders: any;
18
- method: any;
19
- fullUrl: any;
20
- headersObj: any;
21
- cookies: any;
22
- postData: any;
23
- }) => any;
24
- };
25
- };
26
- };
27
- //# sourceMappingURL=target.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../../../../../src/httpsnippet-lite/esm/targets/csharp/target.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,MAAM;;;;;;;;;;;;;;;;;;;;;;;;;CAUlB,CAAA"}
@@ -1,16 +0,0 @@
1
- import { restsharp } from "./restsharp/client.js";
2
- const csharp = {
3
- info: {
4
- key: "csharp",
5
- title: "C#",
6
- extname: ".cs",
7
- default: "restsharp"
8
- },
9
- clientsById: {
10
- restsharp
11
- }
12
- };
13
- export {
14
- csharp
15
- };
16
- //# sourceMappingURL=target.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../src/httpsnippet-lite/esm/targets/csharp/target.ts"],
4
- "sourcesContent": ["// @ts-nocheck\nimport { restsharp } from './restsharp/client.js'\n\nexport const csharp = {\n info: {\n key: 'csharp',\n title: 'C#',\n extname: '.cs',\n default: 'restsharp',\n },\n clientsById: {\n restsharp,\n },\n}\n"],
5
- "mappings": "AACA,SAAS,iBAAiB;AAEnB,MAAM,SAAS;AAAA,EACpB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,SAAS;AAAA,IACT,SAAS;AAAA,EACX;AAAA,EACA,aAAa;AAAA,IACX;AAAA,EACF;AACF;",
6
- "names": []
7
- }
@@ -1,15 +0,0 @@
1
- export declare const native: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ postData, method, allHeaders, fullUrl }: {
9
- postData: any;
10
- method: any;
11
- allHeaders: any;
12
- fullUrl: any;
13
- }, options?: {}) => any;
14
- };
15
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/go/native/client.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,MAAM;;;;;;;;;;;;;CAoLlB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/go/native/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\n/**\n * @description\n * HTTP code snippet generator for native Go.\n *\n * @author\n * @montanaflynn\n *\n * for any questions or issues regarding the generated code snippet, please open an issue mentioning the author.\n */\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { escapeForDoubleQuotes } from '../../../helpers/escape.js'\n\nexport const native = {\n info: {\n key: 'native',\n title: 'NewRequest',\n link: 'http://golang.org/pkg/net/http/#NewRequest',\n description: 'Golang HTTP client request',\n },\n convert: ({ postData, method, allHeaders, fullUrl }, options = {}) => {\n const { blank, push, join, addPostProcessor } = new CodeBuilder({ indent: '\\t' })\n const {\n showBoilerplate = true,\n checkErrors = false,\n printBody = true,\n timeout = -1,\n insecureSkipVerify = false,\n } = options\n const errorPlaceholder = checkErrors ? 'err' : '_'\n const indent = showBoilerplate ? 1 : 0\n const errorCheck = () => {\n if (checkErrors) {\n push('if err != nil {', indent)\n push('panic(err)', indent + 1)\n push('}', indent)\n }\n }\n // Create boilerplate\n const imports = new Set()\n if (showBoilerplate) {\n push('package main')\n blank()\n\n push('import ()')\n addPostProcessor((code) => {\n const importArray = [...imports]\n importArray.sort()\n const importBlock = importArray.map((line) => `\\t\"${line}\"`).join('\\n')\n return code.replace(/import \\(\\)/, `import (\\n${importBlock}\\n)`)\n })\n\n imports.add('fmt')\n imports.add('net/http')\n\n blank()\n push('func main() {')\n }\n // Create an insecure transport for the client\n if (insecureSkipVerify) {\n imports.add('crypto/tls')\n push(\n 'insecureTransport := http.DefaultTransport.(*http.Transport).Clone()',\n indent,\n )\n push(\n 'insecureTransport.TLSClientConfig = &tls.Config{InsecureSkipVerify: true}',\n indent,\n )\n }\n // Create client\n const hasTimeout = timeout > 0\n const hasClient = hasTimeout || insecureSkipVerify\n const client = hasClient ? 'client' : 'http.DefaultClient'\n if (hasClient) {\n push('client := http.Client{', indent)\n if (hasTimeout) {\n imports.add('time')\n push(`Timeout: time.Duration(${timeout} * time.Second),`, indent + 1)\n }\n if (insecureSkipVerify) {\n push('Transport: insecureTransport,', indent + 1)\n }\n push('}', indent)\n blank()\n }\n push(`url := \"${fullUrl}\"`, indent)\n blank()\n // If we have body content or not create the var and reader or nil\n if (postData !== null && postData !== void 0 && (postData.params || postData.text)) {\n if (postData.mimeType === 'application/x-www-form-urlencoded' && postData.params) {\n imports.add('net/url')\n imports.add('strings')\n\n push('postData := url.Values{}', indent)\n postData.params.forEach((param) => {\n push(\n `postData.Set(\"${param.name}\", \"${escapeForDoubleQuotes(param.value)}\")`,\n indent,\n )\n })\n blank()\n push(\n `req, ${errorPlaceholder} := http.NewRequest(\"${method}\", url, strings.NewReader(postData.Encode()))`,\n indent,\n )\n } else if (postData.mimeType === 'multipart/form-data' && postData.params) {\n imports.add('bytes')\n imports.add('mime/multipart')\n\n push('payload := &bytes.Buffer{}', indent)\n push('writer := multipart.NewWriter(payload)', indent)\n postData.params.forEach((param) => {\n blank()\n if (param.fileName) {\n push(`part, ${errorPlaceholder} := writer.CreateFormFile(\"${param.name}\", \"${param.fileName}\")`, indent)\n errorCheck()\n blank()\n push(`f, ${errorPlaceholder} := os.Open(\"${param.fileName}\")`, indent)\n errorCheck()\n push('defer f.Close()', indent)\n blank()\n push(`_, ${errorPlaceholder} = io.Copy(part, f)`, indent)\n errorCheck()\n } else {\n push(`${errorPlaceholder} = writer.WriteField(\"${param.name}\", \"${escapeForDoubleQuotes(param.value)}\")`, indent)\n errorCheck()\n }\n })\n push('writer.Close()', indent)\n blank()\n push(\n `req, ${errorPlaceholder} := http.NewRequest(\"${method}\", url, payload)`,\n indent,\n )\n } else {\n imports.add('strings')\n\n push(\n `payload := strings.NewReader(${JSON.stringify(postData.text)})`,\n indent,\n )\n blank()\n push(\n `req, ${errorPlaceholder} := http.NewRequest(\"${method}\", url, payload)`,\n indent,\n )\n }\n } else {\n push(\n `req, ${errorPlaceholder} := http.NewRequest(\"${method}\", url, nil)`,\n indent,\n )\n }\n errorCheck()\n blank()\n // Add headers\n if (postData !== null && postData !== void 0 && postData.mimeType === 'multipart/form-data' && postData.params) {\n push(`req.Header.Set(\"Content-Type\", writer.FormDataContentType())`, indent)\n }\n if (Object.keys(allHeaders).length) {\n Object.keys(allHeaders).forEach((key) => {\n push(\n `req.Header.Add(\"${key}\", \"${escapeForDoubleQuotes(allHeaders[key])}\")`,\n indent,\n )\n })\n blank()\n }\n // Make request\n push(`res, ${errorPlaceholder} := ${client}.Do(req)`, indent)\n errorCheck()\n // Get Body\n if (printBody) {\n imports.add('io')\n blank()\n push('defer res.Body.Close()', indent)\n push(`body, ${errorPlaceholder} := io.ReadAll(res.Body)`, indent)\n errorCheck()\n }\n // Print it\n blank()\n push('fmt.Println(res)', indent)\n if (printBody) {\n push('fmt.Println(string(body))', indent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,4BAA4B,MAAM;AAChE,iBAAW;AAAA,IACb;AAEA,UAAM;AACN,SAAK,oBAAoB,MAAM;AAC/B,QAAI,WAAW;AACb,WAAK,6BAA6B,MAAM;AAAA,IAC1C;AAEA,QAAI,iBAAiB;AACnB,YAAM;AACN,WAAK,GAAG;AAAA,IACV;AACA,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }
@@ -1,25 +0,0 @@
1
- export declare const go: {
2
- info: {
3
- key: string;
4
- title: string;
5
- extname: string;
6
- default: string;
7
- };
8
- clientsById: {
9
- native: {
10
- info: {
11
- key: string;
12
- title: string;
13
- link: string;
14
- description: string;
15
- };
16
- convert: ({ postData, method, allHeaders, fullUrl }: {
17
- postData: any;
18
- method: any;
19
- allHeaders: any;
20
- fullUrl: any;
21
- }, options?: {}) => any;
22
- };
23
- };
24
- };
25
- //# sourceMappingURL=target.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../../../../../src/httpsnippet-lite/esm/targets/go/target.ts"],"names":[],"mappings":"AAGA,eAAO,MAAM,EAAE;;;;;;;;;;;;;;;;;;;;;;;CAUd,CAAA"}
@@ -1,16 +0,0 @@
1
- import { native } from "./native/client.js";
2
- const go = {
3
- info: {
4
- key: "go",
5
- title: "Go",
6
- extname: ".go",
7
- default: "native"
8
- },
9
- clientsById: {
10
- native
11
- }
12
- };
13
- export {
14
- go
15
- };
16
- //# sourceMappingURL=target.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../src/httpsnippet-lite/esm/targets/go/target.ts"],
4
- "sourcesContent": ["// @ts-nocheck\nimport { native } from './native/client.js'\n\nexport const go = {\n info: {\n key: 'go',\n title: 'Go',\n extname: '.go',\n default: 'native',\n },\n clientsById: {\n native,\n },\n}\n"],
5
- "mappings": "AACA,SAAS,cAAc;AAEhB,MAAM,KAAK;AAAA,EAChB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,SAAS;AAAA,IACT,SAAS;AAAA,EACX;AAAA,EACA,aAAa;AAAA,IACX;AAAA,EACF;AACF;",
6
- "names": []
7
- }
@@ -1,15 +0,0 @@
1
- export declare const asynchttp: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ method, allHeaders, postData, fullUrl }: {
9
- method: any;
10
- allHeaders: any;
11
- postData: any;
12
- fullUrl: any;
13
- }, options: any) => any;
14
- };
15
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/java/asynchttp/client.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,SAAS;;;;;;;;;;;;;CAiCrB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/java/asynchttp/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\n/**\n * @description\n * Asynchronous Http and WebSocket Client library for Java\n *\n * @author\n * @windard\n *\n * for any questions or issues regarding the generated code snippet, please open an issue mentioning the author.\n */\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { escapeForDoubleQuotes } from '../../../helpers/escape.js'\n\nexport const asynchttp = {\n info: {\n key: 'asynchttp',\n title: 'AsyncHttp',\n link: 'https://github.com/AsyncHttpClient/async-http-client',\n description: 'Asynchronous Http and WebSocket Client library for Java',\n },\n convert: ({ method, allHeaders, postData, fullUrl }, options) => {\n const opts = {\n indent: ' ',\n ...options,\n }\n const { blank, push, join } = new CodeBuilder({ indent: opts.indent })\n push('AsyncHttpClient client = new DefaultAsyncHttpClient();')\n push(`client.prepare(\"${method.toUpperCase()}\", \"${fullUrl}\")`)\n // Add headers, including the cookies\n Object.keys(allHeaders).forEach((key) => {\n push(\n `.setHeader(\"${key}\", \"${escapeForDoubleQuotes(allHeaders[key])}\")`,\n 1,\n )\n })\n if (postData === null || postData === void 0 ? void 0 : postData.text) {\n push(`.setBody(${JSON.stringify(postData.text)})`, 1)\n }\n push('.execute()', 1)\n push('.toCompletableFuture()', 1)\n push('.thenAccept(System.out::println)', 1)\n push('.join();', 1)\n blank()\n push('client.close();')\n return join()\n },\n}\n"],
5
- "mappings": "AAUA,SAAS,mBAAmB;AAC5B,SAAS,6BAA6B;AAE/B,MAAM,YAAY;AAAA,EACvB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,IACN,aAAa;AAAA,EACf;AAAA,EACA,SAAS,CAAC,EAAE,QAAQ,YAAY,UAAU,QAAQ,GAAG,YAAY;AAC/D,UAAM,OAAO;AAAA,MACX,QAAQ;AAAA,MACR,GAAG;AAAA,IACL;AACA,UAAM,EAAE,OAAO,MAAM,KAAK,IAAI,IAAI,YAAY,EAAE,QAAQ,KAAK,OAAO,CAAC;AACrE,SAAK,wDAAwD;AAC7D,SAAK,mBAAmB,OAAO,YAAY,CAAC,OAAO,OAAO,IAAI;AAE9D,WAAO,KAAK,UAAU,EAAE,QAAQ,CAAC,QAAQ;AACvC;AAAA,QACE,eAAe,GAAG,OAAO,sBAAsB,WAAW,GAAG,CAAC,CAAC;AAAA,QAC/D;AAAA,MACF;AAAA,IACF,CAAC;AACD,QAAI,aAAa,QAAQ,aAAa,SAAS,SAAS,SAAS,MAAM;AACrE,WAAK,YAAY,KAAK,UAAU,SAAS,IAAI,CAAC,KAAK,CAAC;AAAA,IACtD;AACA,SAAK,cAAc,CAAC;AACpB,SAAK,0BAA0B,CAAC;AAChC,SAAK,oCAAoC,CAAC;AAC1C,SAAK,YAAY,CAAC;AAClB,UAAM;AACN,SAAK,iBAAiB;AACtB,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }
@@ -1,15 +0,0 @@
1
- export declare const nethttp: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ allHeaders, fullUrl, method, postData }: {
9
- allHeaders: any;
10
- fullUrl: any;
11
- method: any;
12
- postData: any;
13
- }, options: any) => any;
14
- };
15
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/java/nethttp/client.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,OAAO;;;;;;;;;;;;;CAoCnB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/java/nethttp/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\n/**\n * @description\n * HTTP code snippet generator for Java using java.net.http.\n *\n * @author\n * @wtetsu\n *\n * for any questions or issues regarding the generated code snippet, please open an issue mentioning the author.\n */\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { escapeForDoubleQuotes } from '../../../helpers/escape.js'\n\nexport const nethttp = {\n info: {\n key: 'nethttp',\n title: 'java.net.http',\n link: 'https://openjdk.java.net/groups/net/httpclient/intro.html',\n description: 'Java Standardized HTTP Client API',\n },\n convert: ({ allHeaders, fullUrl, method, postData }, options) => {\n const opts = {\n indent: ' ',\n ...options,\n }\n const { push, join } = new CodeBuilder({ indent: opts.indent })\n push('HttpRequest request = HttpRequest.newBuilder()')\n push(`.uri(URI.create(\"${fullUrl}\"))`, 2)\n Object.keys(allHeaders).forEach((key) => {\n push(`.header(\"${key}\", \"${escapeForDoubleQuotes(allHeaders[key])}\")`, 2)\n })\n if (postData === null || postData === void 0 ? void 0 : postData.text) {\n push(\n `.method(\"${method.toUpperCase()}\", HttpRequest.BodyPublishers.ofString(${JSON.stringify(postData.text)}))`,\n 2,\n )\n } else {\n push(\n `.method(\"${method.toUpperCase()}\", HttpRequest.BodyPublishers.noBody())`,\n 2,\n )\n }\n push('.build();', 2)\n push(\n 'HttpResponse<String> response = HttpClient.newHttpClient().send(request, HttpResponse.BodyHandlers.ofString());',\n )\n push('System.out.println(response.body());')\n return join()\n },\n}\n"],
5
- "mappings": "AAUA,SAAS,mBAAmB;AAC5B,SAAS,6BAA6B;AAE/B,MAAM,UAAU;AAAA,EACrB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,IACN,aAAa;AAAA,EACf;AAAA,EACA,SAAS,CAAC,EAAE,YAAY,SAAS,QAAQ,SAAS,GAAG,YAAY;AAC/D,UAAM,OAAO;AAAA,MACX,QAAQ;AAAA,MACR,GAAG;AAAA,IACL;AACA,UAAM,EAAE,MAAM,KAAK,IAAI,IAAI,YAAY,EAAE,QAAQ,KAAK,OAAO,CAAC;AAC9D,SAAK,gDAAgD;AACrD,SAAK,oBAAoB,OAAO,OAAO,CAAC;AACxC,WAAO,KAAK,UAAU,EAAE,QAAQ,CAAC,QAAQ;AACvC,WAAK,YAAY,GAAG,OAAO,sBAAsB,WAAW,GAAG,CAAC,CAAC,MAAM,CAAC;AAAA,IAC1E,CAAC;AACD,QAAI,aAAa,QAAQ,aAAa,SAAS,SAAS,SAAS,MAAM;AACrE;AAAA,QACE,YAAY,OAAO,YAAY,CAAC,0CAA0C,KAAK,UAAU,SAAS,IAAI,CAAC;AAAA,QACvG;AAAA,MACF;AAAA,IACF,OAAO;AACL;AAAA,QACE,YAAY,OAAO,YAAY,CAAC;AAAA,QAChC;AAAA,MACF;AAAA,IACF;AACA,SAAK,aAAa,CAAC;AACnB;AAAA,MACE;AAAA,IACF;AACA,SAAK,sCAAsC;AAC3C,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }
@@ -1,15 +0,0 @@
1
- export declare const okhttp: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ postData, method, fullUrl, allHeaders }: {
9
- postData: any;
10
- method: any;
11
- fullUrl: any;
12
- allHeaders: any;
13
- }, options: any) => any;
14
- };
15
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/java/okhttp/client.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,MAAM;;;;;;;;;;;;;CA0ElB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/java/okhttp/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\n/**\n * @description\n * HTTP code snippet generator for Java using OkHttp.\n *\n * @author\n * @shashiranjan84\n *\n * for any questions or issues regarding the generated code snippet, please open an issue mentioning the author.\n */\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { escapeForDoubleQuotes } from '../../../helpers/escape.js'\n\nexport const okhttp = {\n info: {\n key: 'okhttp',\n title: 'OkHttp',\n link: 'http://square.github.io/okhttp/',\n description: 'An HTTP Request Client Library',\n },\n convert: ({ postData, method, fullUrl, allHeaders }, options) => {\n const opts = {\n indent: ' ',\n ...options,\n }\n const { push, blank, join } = new CodeBuilder({ indent: opts.indent })\n const methods = ['GET', 'POST', 'PUT', 'DELETE', 'PATCH', 'HEAD']\n const methodsWithBody = ['POST', 'PUT', 'DELETE', 'PATCH']\n push('OkHttpClient client = new OkHttpClient();')\n blank()\n if (postData !== null && postData !== void 0) {\n if (postData.mimeType === 'application/x-www-form-urlencoded' && postData.params) {\n push('FormBody formBody = new FormBody.Builder()')\n postData.params.forEach((param) => {\n push(`.addEncoded(\"${param.name}\", \"${param.value}\")`, 1)\n })\n push('.build();', 1)\n blank()\n } else if (postData.mimeType === 'multipart/form-data' && postData.params) {\n push(`MultipartBody body = new MultipartBody.Builder()`)\n push(`.setType(MultipartBody.FORM)`, 1)\n postData.params.forEach((param) => {\n if (param.fileName !== undefined) {\n push(\n `.addFormDataPart(\"${param.name}\", \"${param.fileName}\", RequestBody.create(MediaType.parse(\"application/octet-stream\"), new File(\"${param.fileName}\")))`,\n 1,\n )\n } else if (param.value !== undefined) {\n push(`.addFormDataPart(\"${param.name}\", \"${param.value}\")`, 1)\n }\n })\n push('.build();', 1)\n blank()\n } else {\n push(`MediaType mediaType = MediaType.parse(\"${postData.mimeType}\");`)\n push(`RequestBody body = RequestBody.create(mediaType, ${JSON.stringify(postData.text)});`)\n }\n }\n push('Request request = new Request.Builder()')\n push(`.url(\"${fullUrl}\")`, 1)\n if (!methods.includes(method.toUpperCase())) {\n if (postData === null || postData === void 0 ? void 0 : postData.text) {\n push(`.method(\"${method.toUpperCase()}\", body)`, 1)\n } else {\n push(`.method(\"${method.toUpperCase()}\", null)`, 1)\n }\n } else if (methodsWithBody.includes(method.toUpperCase())) {\n if (postData === null || postData === void 0 ? void 0 : postData.text || postData.params) {\n push(`.${method.toLowerCase()}(body)`, 1)\n } else {\n push(`.${method.toLowerCase()}(null)`, 1)\n }\n } else {\n push(`.${method.toLowerCase()}()`, 1)\n }\n // Add headers, including the cookies\n Object.keys(allHeaders).forEach((key) => {\n push(\n `.addHeader(\"${key}\", \"${escapeForDoubleQuotes(allHeaders[key])}\")`,\n 1,\n )\n })\n push('.build();', 1)\n blank()\n push('Response response = client.newCall(request).execute();')\n return join()\n },\n}\n"],
5
- "mappings": "AAUA,SAAS,mBAAmB;AAC5B,SAAS,6BAA6B;AAE/B,MAAM,SAAS;AAAA,EACpB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,IACN,aAAa;AAAA,EACf;AAAA,EACA,SAAS,CAAC,EAAE,UAAU,QAAQ,SAAS,WAAW,GAAG,YAAY;AAC/D,UAAM,OAAO;AAAA,MACX,QAAQ;AAAA,MACR,GAAG;AAAA,IACL;AACA,UAAM,EAAE,MAAM,OAAO,KAAK,IAAI,IAAI,YAAY,EAAE,QAAQ,KAAK,OAAO,CAAC;AACrE,UAAM,UAAU,CAAC,OAAO,QAAQ,OAAO,UAAU,SAAS,MAAM;AAChE,UAAM,kBAAkB,CAAC,QAAQ,OAAO,UAAU,OAAO;AACzD,SAAK,2CAA2C;AAChD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S,QAAQ,SAAS,QAAQ;AACxF,aAAK,IAAI,OAAO,YAAY,CAAC,UAAU,CAAC;AAAA,MAC1C,OAAO;AACL,aAAK,IAAI,OAAO,YAAY,CAAC,UAAU,CAAC;AAAA,MAC1C;AAAA,IACF,OAAO;AACL,WAAK,IAAI,OAAO,YAAY,CAAC,MAAM,CAAC;AAAA,IACtC;AAEA,WAAO,KAAK,UAAU,EAAE,QAAQ,CAAC,QAAQ;AACvC;AAAA,QACE,eAAe,GAAG,OAAO,sBAAsB,WAAW,GAAG,CAAC,CAAC;AAAA,QAC/D;AAAA,MACF;AAAA,IACF,CAAC;AACD,SAAK,aAAa,CAAC;AACnB,UAAM;AACN,SAAK,wDAAwD;AAC7D,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }
@@ -1,67 +0,0 @@
1
- export declare const java: {
2
- info: {
3
- key: string;
4
- title: string;
5
- extname: string;
6
- default: string;
7
- };
8
- clientsById: {
9
- asynchttp: {
10
- info: {
11
- key: string;
12
- title: string;
13
- link: string;
14
- description: string;
15
- };
16
- convert: ({ method, allHeaders, postData, fullUrl }: {
17
- method: any;
18
- allHeaders: any;
19
- postData: any;
20
- fullUrl: any;
21
- }, options: any) => any;
22
- };
23
- nethttp: {
24
- info: {
25
- key: string;
26
- title: string;
27
- link: string;
28
- description: string;
29
- };
30
- convert: ({ allHeaders, fullUrl, method, postData }: {
31
- allHeaders: any;
32
- fullUrl: any;
33
- method: any;
34
- postData: any;
35
- }, options: any) => any;
36
- };
37
- okhttp: {
38
- info: {
39
- key: string;
40
- title: string;
41
- link: string;
42
- description: string;
43
- };
44
- convert: ({ postData, method, fullUrl, allHeaders }: {
45
- postData: any;
46
- method: any;
47
- fullUrl: any;
48
- allHeaders: any;
49
- }, options: any) => any;
50
- };
51
- unirest: {
52
- info: {
53
- key: string;
54
- title: string;
55
- link: string;
56
- description: string;
57
- };
58
- convert: ({ method, allHeaders, postData, fullUrl }: {
59
- method: any;
60
- allHeaders: any;
61
- postData: any;
62
- fullUrl: any;
63
- }, options: any) => any;
64
- };
65
- };
66
- };
67
- //# sourceMappingURL=target.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"target.d.ts","sourceRoot":"","sources":["../../../../../src/httpsnippet-lite/esm/targets/java/target.ts"],"names":[],"mappings":"AAMA,eAAO,MAAM,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAahB,CAAA"}
@@ -1,22 +0,0 @@
1
- import { asynchttp } from "./asynchttp/client.js";
2
- import { nethttp } from "./nethttp/client.js";
3
- import { okhttp } from "./okhttp/client.js";
4
- import { unirest } from "./unirest/client.js";
5
- const java = {
6
- info: {
7
- key: "java",
8
- title: "Java",
9
- extname: ".java",
10
- default: "unirest"
11
- },
12
- clientsById: {
13
- asynchttp,
14
- nethttp,
15
- okhttp,
16
- unirest
17
- }
18
- };
19
- export {
20
- java
21
- };
22
- //# sourceMappingURL=target.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../src/httpsnippet-lite/esm/targets/java/target.ts"],
4
- "sourcesContent": ["// @ts-nocheck\nimport { asynchttp } from './asynchttp/client.js'\nimport { nethttp } from './nethttp/client.js'\nimport { okhttp } from './okhttp/client.js'\nimport { unirest } from './unirest/client.js'\n\nexport const java = {\n info: {\n key: 'java',\n title: 'Java',\n extname: '.java',\n default: 'unirest',\n },\n clientsById: {\n asynchttp,\n nethttp,\n okhttp,\n unirest,\n },\n}\n"],
5
- "mappings": "AACA,SAAS,iBAAiB;AAC1B,SAAS,eAAe;AACxB,SAAS,cAAc;AACvB,SAAS,eAAe;AAEjB,MAAM,OAAO;AAAA,EAClB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,SAAS;AAAA,IACT,SAAS;AAAA,EACX;AAAA,EACA,aAAa;AAAA,IACX;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,EACF;AACF;",
6
- "names": []
7
- }
@@ -1,15 +0,0 @@
1
- export declare const unirest: {
2
- info: {
3
- key: string;
4
- title: string;
5
- link: string;
6
- description: string;
7
- };
8
- convert: ({ method, allHeaders, postData, fullUrl }: {
9
- method: any;
10
- allHeaders: any;
11
- postData: any;
12
- fullUrl: any;
13
- }, options: any) => any;
14
- };
15
- //# sourceMappingURL=client.d.ts.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"client.d.ts","sourceRoot":"","sources":["../../../../../../src/httpsnippet-lite/esm/targets/java/unirest/client.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,OAAO;;;;;;;;;;;;;CAiCnB,CAAA"}
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../../../../../../src/httpsnippet-lite/esm/targets/java/unirest/client.ts"],
4
- "sourcesContent": ["// @ts-nocheck\n/**\n * @description\n * HTTP code snippet generator for Java using Unirest.\n *\n * @author\n * @shashiranjan84\n *\n * for any questions or issues regarding the generated code snippet, please open an issue mentioning the author.\n */\nimport { CodeBuilder } from '../../../helpers/code-builder.js'\nimport { escapeForDoubleQuotes } from '../../../helpers/escape.js'\n\nexport const unirest = {\n info: {\n key: 'unirest',\n title: 'Unirest',\n link: 'http://unirest.io/java.html',\n description: 'Lightweight HTTP Request Client Library',\n },\n convert: ({ method, allHeaders, postData, fullUrl }, options) => {\n const opts = {\n indent: ' ',\n ...options,\n }\n const { join, push } = new CodeBuilder({ indent: opts.indent })\n const methods = ['GET', 'POST', 'PUT', 'DELETE', 'PATCH', 'HEAD', 'OPTIONS']\n if (!methods.includes(method.toUpperCase())) {\n push(\n `HttpResponse<String> response = Unirest.customMethod(\"${method.toUpperCase()}\",\"${fullUrl}\")`,\n )\n } else {\n push(\n `HttpResponse<String> response = Unirest.${method.toLowerCase()}(\"${fullUrl}\")`,\n )\n }\n // Add headers, including the cookies\n Object.keys(allHeaders).forEach((key) => {\n push(`.header(\"${key}\", \"${escapeForDoubleQuotes(allHeaders[key])}\")`, 1)\n })\n if (postData === null || postData === void 0 ? void 0 : postData.text) {\n push(`.body(${JSON.stringify(postData.text)})`, 1)\n }\n push('.asString();', 1)\n return join()\n },\n}\n"],
5
- "mappings": "AAUA,SAAS,mBAAmB;AAC5B,SAAS,6BAA6B;AAE/B,MAAM,UAAU;AAAA,EACrB,MAAM;AAAA,IACJ,KAAK;AAAA,IACL,OAAO;AAAA,IACP,MAAM;AAAA,IACN,aAAa;AAAA,EACf;AAAA,EACA,SAAS,CAAC,EAAE,QAAQ,YAAY,UAAU,QAAQ,GAAG,YAAY;AAC/D,UAAM,OAAO;AAAA,MACX,QAAQ;AAAA,MACR,GAAG;AAAA,IACL;AACA,UAAM,EAAE,MAAM,KAAK,IAAI,IAAI,YAAY,EAAE,QAAQ,KAAK,OAAO,CAAC;AAC9D,UAAM,UAAU,CAAC,OAAO,QAAQ,OAAO,UAAU,SAAS,QAAQ,SAAS;AAC3E,QAAI,CAAC,QAAQ,SAAS,OAAO,YAAY,CAAC,GAAG;AAC3C;AAAA,QACE,yDAAyD,OAAO,YAAY,CAAC,MAAM,OAAO;AAAA,MAC5F;AAAA,IACF,OAAO;AACL;AAAA,QACE,2CAA2C,OAAO,YAAY,CAAC,KAAK,OAAO;AAAA,MAC7E;AAAA,IACF;AAEA,WAAO,KAAK,UAAU,EAAE,QAAQ,CAAC,QAAQ;AACvC,WAAK,YAAY,GAAG,OAAO,sBAAsB,WAAW,GAAG,CAAC,CAAC,MAAM,CAAC;AAAA,IAC1E,CAAC;AACD,QAAI,aAAa,QAAQ,aAAa,SAAS,SAAS,SAAS,MAAM;AACrE,WAAK,SAAS,KAAK,UAAU,SAAS,IAAI,CAAC,KAAK,CAAC;AAAA,IACnD;AACA,SAAK,gBAAgB,CAAC;AACtB,WAAO,KAAK;AAAA,EACd;AACF;",
6
- "names": []
7
- }