This is the first time I am writing cfc which will capture JSON data from an external web server that will host the information.
Iām working with a new service that can be configured to send unsuccessful transaction information JSON packet to me via HTTP POST to the URL specified by me.
I decided that I installed CFC with remote access to capture and deserialize JSON data into something that we could then act on. However, I cannot figure out how to set up a function in CFC to receive data?
I set the url: www.mydomain.com/com/processRemote.cfc?method=catchJSONdata&ReturnFormat=json
To verify this, I set up a simple test page that should publish session data:
<cfhttp result="result" method="post" url="http://www.mydomain.com/com/processRemote.cfc?method=catchJSONdata&ReturnFormat=json"> <cfhttpparam type="header" name="content-type" value="application/json"/> <cfhttpparam type="body" value="#serializeJSON(session)#"/>
So, where did I get lost, is that the name cfargument that I would have in my cfc, which I would first store JSON data? I do not control a remote service that will send JSON data.
Thanks,
json coldfusion cfc
Steve
source share