1

I'm developing a ColdFusion site that needs to integrate Vidyo. I haven't found a ColdFusion based solution but I have found a Python version. However I'm having an issue trying to call the Python file to generate the tokens for the Vidyo session. I'm getting the following error:

An exception occurred when invoking an external process. The cause of this exception was that: java.io.IOException: Cannot run program "C:\Inetpub\vhosts\sitename\httpdocs\site.com\generateToken.py": CreateProcess error=193, %1 is not a valid Win32 application.
The error occurred on line 9.

Here is the code that the generates the error:

<cffunction name="generateToken" access="public" returntype="string" output="false">
    <cfargument name="userName" required="true" type="string">

    <cfexecute name = "C:\Inetpub\vhosts\sitename\httpdocs\site.com\generateToken.py"
        arguments="--key=3907f8fa000d4ae08e3a2a0507986d45 --appID=d85f88.vidyo.io --userName=#userName# --expiresInSecs=10000"
        variable="token"
        errorVariable="errorOut"
        timeout = "1">
    </cfexecute>

    <cfreturn token>
</cffunction>

I have never integrated with Python before so any help would be appreciated. Also if anyone knows of a pure ColdFusion integration with Vidyo I'd be willing to switch my direction.

Miguel-F
  • 13,450
  • 6
  • 38
  • 63
rfdbm
  • 11
  • 1
  • 1
    can you execute that script from your command line? – Dan Bracuk May 30 '18 at 13:01
  • 4
    I think you would need something like `` – Shawn May 30 '18 at 14:23
  • And make sure Python.exe is in the PATH for the server. – Shawn May 30 '18 at 14:24
  • 1
    "need something like..." In other words, the "name" should be the Python executable. The script, and everything else should be in "arguments". – SOS May 30 '18 at 19:34
  • 2
    "knows of a pure ColdFusion integration" Not pure CF, but as it runs on java, the java examples seem like a better fit. Especially using cfscript. They have java examples on this page https://developer.vidyo.io/documentation/4-1-11-4/getting-started#Tokens – SOS May 31 '18 at 02:34
  • I would agree with @Ageax that Java seems best. CF runs on top of Java and makes using Java objects and functions easy – David Faber Jun 04 '18 at 14:26

0 Answers0