github polterguy/magic v9.9.5
Improvements in HTTP slots

latest releases: v17.3.9, v17.3.8, v17.3.7...
2 years ago

This release features automatic conversion from Lambda to JSON when invoking [http.post], [http.patch] and [http.put], significantly simplifying invoking HTTP endpoints requiring a [payload] argument. Example usage can be found below.

http.post:"https://jsonplaceholder.typicode.com/posts"
   payload
      userId:int:1
      id:int:1

In addition to the above simplifications, and expressions within your payload lambda will automatically be evaluated and [unwrap]'ed, such as the following illustrates.

.userId:int:1
http.post:"https://jsonplaceholder.typicode.com/posts"
   payload
      userId:x:@.userId
      id:int:1

In addition to the above change, a Hyperlambda HTTP endpoint can now explicitly declare no type checking for its [.arguments] collection using the following syntax.

.arguments:*

Notice the asterisk in the above [.arguments] node, which functions similarly to simply omitting the [.arguments] collection entirely, providing a slightly more semantically "correct" method to bypass type checking and argument conversions.

Don't miss a new magic release

NewReleases is sending notifications on new releases.