4
$\begingroup$

I'm new to APIFunction and CloudDeploy, but essentially, here's my situation:

I have a function (let's call it TestFunc) that is of the following form:

TestFunc[l_List, a_Image]:= ...

I created an API function using this function as follows:

TestF = APIFunction[{"l" -> "List", "a" -> "Image"}, TestFunc[#l, #a] &]

And then cloud deployed TestF using the following:

CloudDeploy[TestF, Permissions -> "Public"]

As expected, I get the standard Wolfram Cloud website saying that at least one parameter could not be interpreted, and the two slots underneath (one for l, one for a), where I can input the parameters, are empty.

My question is: How (using what syntax) can I input a list of images for variable l, such as: {img1, img2, ...} and input one image for variable a so that a = img5 into input slots?

I've been reading the documentation for a while now, and have yet to stumble upon the answer for inputting images. My ultimate goal is for a user with the link to the cloud-deployed function to be able to input a list of images for l and the one image for a. Any help, or request for clarification/more details for this question, is very much appreciated!

$\endgroup$
  • $\begingroup$ Did you figure this out? I'd be curious too. $\endgroup$ – Levi Sep 7 '15 at 17:17
  • 1
    $\begingroup$ @Levi actually I did just a few days ago! I'll post it as a solution as soon as I get time. $\endgroup$ – pMarkov Sep 7 '15 at 18:13
  • $\begingroup$ @pMarkov, it would still be usefull to post the solution $\endgroup$ – Frank Martin Aug 19 '16 at 7:32

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.