@voxgig/sdkgen 4.5.0 → 4.5.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.
- package/bin/voxgig-sdkgen +1 -1
- package/package.json +1 -1
- package/project/.sdk/tm/clojure/src/sdk/core.clj +6 -2
- package/project/.sdk/tm/csharp/utility/MakeOptions.cs +5 -0
- package/project/.sdk/tm/dart/lib/utility/MakeOptionsUtility.dart +4 -0
- package/project/.sdk/tm/elixir/lib/projectname/utility.ex +4 -1
- package/project/.sdk/tm/ocaml/sdk_runtime.ml +4 -1
- package/project/.sdk/tm/perl/utility/make_options.pm +4 -1
- package/project/.sdk/tm/rb/utility/make_options.rb +4 -1
- package/project/sdkgen-package.json +1 -1
package/bin/voxgig-sdkgen
CHANGED
package/package.json
CHANGED
|
@@ -1012,8 +1012,12 @@
|
|
|
1012
1012
|
config (or (oget ctx :config) (vs/jm))
|
|
1013
1013
|
cfgopts (let [c (vs/getprop config "options")] (if (vs/ismap c) c (vs/jm)))
|
|
1014
1014
|
optspec (vs/jm
|
|
1015
|
-
"apikey" "" "base" "http://localhost:8000" "prefix" "" "suffix" ""
|
|
1016
|
-
|
|
1015
|
+
"apikey" "" "secret" "" "base" "http://localhost:8000" "prefix" "" "suffix" ""
|
|
1016
|
+
;; `basic` and `secret`: HTTP Basic Auth needs a second
|
|
1017
|
+
;; credential and a flag to say the pair is Basic rather
|
|
1018
|
+
;; than a single bearer token. Absent from the shape, a
|
|
1019
|
+
;; client passing them is refused with "Unexpected keys".
|
|
1020
|
+
"auth" (vs/jm "prefix" "" "basic" false)
|
|
1017
1021
|
"headers" (vs/jm "`$CHILD`" "`$STRING`")
|
|
1018
1022
|
"allow" (vs/jm "method" "GET,PUT,POST,PATCH,DELETE,OPTIONS"
|
|
1019
1023
|
"op" "create,update,load,list,remove,command,direct,graphql")
|
|
@@ -150,12 +150,17 @@ public static partial class SdkUtility
|
|
|
150
150
|
var optspec = new Dictionary<string, object?>
|
|
151
151
|
{
|
|
152
152
|
["apikey"] = "",
|
|
153
|
+
["secret"] = "",
|
|
153
154
|
["base"] = "http://localhost:8000",
|
|
154
155
|
["prefix"] = "",
|
|
155
156
|
["suffix"] = "",
|
|
157
|
+
// `basic` and `secret`: HTTP Basic Auth needs a second credential
|
|
158
|
+
// and a flag to say the pair is Basic rather than a single bearer
|
|
159
|
+
// token.
|
|
156
160
|
["auth"] = new Dictionary<string, object?>
|
|
157
161
|
{
|
|
158
162
|
["prefix"] = "",
|
|
163
|
+
["basic"] = false,
|
|
159
164
|
},
|
|
160
165
|
["headers"] = new Dictionary<string, object?>
|
|
161
166
|
{
|
|
@@ -21,10 +21,14 @@ dynamic makeOptions(dynamic ctx) {
|
|
|
21
21
|
final optspec = {
|
|
22
22
|
'apikey': '',
|
|
23
23
|
'base': 'http://localhost:8000',
|
|
24
|
+
'secret': '',
|
|
24
25
|
'prefix': '',
|
|
25
26
|
'suffix': '',
|
|
27
|
+
// `basic` and `secret`: HTTP Basic Auth needs a second credential and a
|
|
28
|
+
// flag to say the pair is Basic rather than a single bearer token.
|
|
26
29
|
'auth': {
|
|
27
30
|
'prefix': '',
|
|
31
|
+
'basic': false,
|
|
28
32
|
},
|
|
29
33
|
'headers': {
|
|
30
34
|
'`\$CHILD`': '`\$STRING`',
|
|
@@ -285,10 +285,13 @@ defmodule ProjectName.Utility do
|
|
|
285
285
|
optspec =
|
|
286
286
|
H.deep(%{
|
|
287
287
|
"apikey" => "",
|
|
288
|
+
"secret" => "",
|
|
288
289
|
"base" => "http://localhost:8000",
|
|
289
290
|
"prefix" => "",
|
|
290
291
|
"suffix" => "",
|
|
291
|
-
|
|
292
|
+
# `basic` and `secret`: HTTP Basic Auth needs a second credential and
|
|
293
|
+
# a flag to say the pair is Basic rather than a single bearer token.
|
|
294
|
+
"auth" => %{"prefix" => "", "basic" => false},
|
|
292
295
|
"headers" => %{"`$CHILD`" => "`$STRING`"},
|
|
293
296
|
"allow" => %{
|
|
294
297
|
"method" => "GET,PUT,POST,PATCH,DELETE,OPTIONS",
|
|
@@ -937,10 +937,13 @@ let fetcher_util (ctx : ctx) (fullurl : string) (fetchdef : value) : (value * sd
|
|
|
937
937
|
let opt_spec_value () : value =
|
|
938
938
|
jo [
|
|
939
939
|
("apikey", Str "");
|
|
940
|
+
("secret", Str "");
|
|
940
941
|
("base", Str "http://localhost:8000");
|
|
941
942
|
("prefix", Str "");
|
|
942
943
|
("suffix", Str "");
|
|
943
|
-
(
|
|
944
|
+
(* `basic` and `secret`: HTTP Basic Auth needs a second credential and a
|
|
945
|
+
flag to say the pair is Basic rather than a single bearer token. *)
|
|
946
|
+
("auth", jo [("prefix", Str ""); ("basic", Bool false)]);
|
|
944
947
|
("headers", jo [("`$CHILD`", Str "`$STRING`")]);
|
|
945
948
|
("allow", jo [("method", Str "GET,PUT,POST,PATCH,DELETE,OPTIONS");
|
|
946
949
|
("op", Str "create,update,load,list,remove,command,direct,graphql")]);
|
|
@@ -108,9 +108,12 @@ $REGISTRY{make_options} = sub {
|
|
|
108
108
|
my $optspec = {
|
|
109
109
|
'apikey' => '',
|
|
110
110
|
'base' => 'http://localhost:8000',
|
|
111
|
+
'secret' => '',
|
|
111
112
|
'prefix' => '',
|
|
112
113
|
'suffix' => '',
|
|
113
|
-
|
|
114
|
+
# `basic` and `secret`: HTTP Basic Auth needs a second credential and a
|
|
115
|
+
# flag to say the pair is Basic rather than a single bearer token.
|
|
116
|
+
'auth' => { 'prefix' => '', 'basic' => $JF },
|
|
114
117
|
'headers' => { '`$CHILD`' => '`$STRING`' },
|
|
115
118
|
'allow' => {
|
|
116
119
|
'method' => 'GET,PUT,POST,PATCH,DELETE,OPTIONS',
|
|
@@ -69,9 +69,12 @@ module ProjectNameUtilities
|
|
|
69
69
|
optspec = {
|
|
70
70
|
"apikey" => "",
|
|
71
71
|
"base" => "http://localhost:8000",
|
|
72
|
+
"secret" => "",
|
|
72
73
|
"prefix" => "",
|
|
73
74
|
"suffix" => "",
|
|
74
|
-
|
|
75
|
+
# `basic` and `secret`: HTTP Basic Auth needs a second credential and
|
|
76
|
+
# a flag to say the pair is Basic rather than a single bearer token.
|
|
77
|
+
"auth" => { "prefix" => "", "basic" => false },
|
|
75
78
|
"headers" => { "`$CHILD`" => "`$STRING`" },
|
|
76
79
|
"allow" => {
|
|
77
80
|
"method" => "GET,PUT,POST,PATCH,DELETE,OPTIONS",
|