@zaccharles do you have any plans to take the VTL evaluation engine you use for mapping tool and open it up as an API (and charge for usage)?
Similar to what AppSync has done, but you'd cover API Gateway as well.
@TastefulElk@rafalwilinski@lajacobsson Love AppSync or API Gateway but hate VTL? You're not the only one!
Check out the Mapping Tool by @zaccharles and finally cure those VTL blues ;-)
https://t.co/Kk3Sa2pjji
@Grenguar You should check out @mappingtool by @zaccharles, makes working with and debugging VTL much easier and works great for both AppSync and API Gateway
⚡️ Now supported:
- $util.transform.toDynamoDBFilterExpression()
- $util.transform.toDynamoDBConditionExpression()
🤥 The AWS docs (https://t.co/Bx6LFmbpQE) say they return a Map, but they actually return a String.
😶 toDynamoDBConditionExpression exists but is undocumented.
AWS AppSync added new VTL utility methods: $util.autoKsuid, $util.log.info and $util.log.error.
Mapping Tool now supports $util.autoKsuid() 🚀
This utility generates a "KSUID (K-Sortable Unique Identifier) base62 encoded as a String with a length of 27".
$util.log coming soon!
Sometimes it's hard to see the red/yellow/blue squiggly lines.
To make things easier, Mapping Tool now colors the margin and line number too! 🟥🟨🟦
Check out this contrived example:
AWS AppSync just added two new HTTP utility methods:
$util.http.addResponseHeader(String, Object)
> Adds a single custom header to the response.
$util.http.addResponseHeaders(Map)
> Adds multiple response headers to the response.
Docs have been updated: https://t.co/LmNmSTXFjr
One reason our emulation is so accurate is that we run the same VTL engine as AWS. Unfortunately that means Java, which can mean Lambda cold starts. 🥶
To keep things fun, if a cold start is detected, you can learn a phrase from one of 30 languages! 😀
I've been trying out @mappingtool by @zaccharles recently and it's definitely an upgrade on the VTL experience provided by the AppSync console.
If you're struggling with writing VTL templates (and you SHOULD prefer VTL over Lambda resolvers) then you should check it out.