You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I was trying to model an existing API but I'm encountering a problem.
Example:
This is one of the urls: BASE_URL/somepath/SOME_STRING_VAR/ANOTHER_STRING_VAR.
The method is POST and it has a String body.
I was trying to model it like this:
enumSiteRoute{case somepath(var1:String, var2:String, body:String)}...letrouter=OneOf{Route(.case(SiteRoute.somepath)){Method.post
Path{"someroute"Parse(.string)Parse(.string)}Body(?)// I can't figure out what to put here.}}
Hi, I was trying to model an existing API but I'm encountering a problem.
Example:
This is one of the urls:
BASE_URL/somepath/SOME_STRING_VAR/ANOTHER_STRING_VAR
.The method is POST and it has a
String
body.I was trying to model it like this:
If I define the model like this, instead:
It throws me this compile error.
How can I solve this (theoretically shouldn't be) complicated task? I'm sure there's something I'm missing.
Thanks in advance.
The text was updated successfully, but these errors were encountered: