Cloud Deploy a FormFunction

Hello!:slight_smile:

I am trying to deploy a form function that takes two numbers, a basis and an exponent, and computes basis^exponent.

CloudDeploy[
 FormFunction[{"basis" -> "Number", "exponent" -> "Number"}, 
  f[basis, exponent]]]

The output for 3 and 2 is (basis^exponent)[<|"basis" -> 3, "exponent" -> 2|>] instead of 9.

Any hints?

Thanks!:slight_smile:

seems you just copied the lines somewhere and don’t know what f means here.
well, it should be a pure funtion object, please reference to ref/Function

CloudDeploy[
 FormFunction[{"basis" -> <|"Interpreter" -> "Number", "Input" :> 3|>,
    "exponent" -> <|"Interpreter" -> "Number", "Input" :> 2|>}, 
  #basis^#exponent &, 
  AppearanceRules -> <|"Title" -> "demo power function", 
    "Description" -> "Enter two number as prompted below"|>, 
  FormTheme -> "Red"]]

good luck.