If you have questions or if you want to share your opinion about Aware IM post your message on this forum
#51371 by swiftinitpvtltd
Sat Aug 17, 2019 11:16 am
Support I have Outboundemail notification objects(not Outgoingemail BO mentioned in CRM) and I want to access it via API how do I do that? I see Inotification interface mentioned in programming reference but there is no sample to access it. Also in a process you can not pass Notification objects(only BO's you can pass)
#51379 by swiftinitpvtltd
Mon Aug 19, 2019 5:37 am
Thank you! The only issue is then I can not send notification objects to custom wrote plugins. Only BO's are allowed to be passed as parameters. if its not possible to send notification object then I will need to know how to refer to Notification IObject by just referring to text for example IObject outboundemail=(IObject)"MyOutboundEmail"; This throws error saying can not convert string to object.
#51405 by swiftinitpvtltd
Wed Aug 21, 2019 4:14 am
Please let me know on ow to send notification objects to custom wrote plugins. Right now you can not send it and then plugin can not access any object by reference. If you provide any sample in document to access IObject without sending it as Param(as its not available right now) that will be great.
#51407 by BobK
Wed Aug 21, 2019 1:49 pm
The following is from the "Programmers Reference" (the BOLD is mine):

3.1.9 INotification interface

The INotification interface extends the IObject interface and therefore shares most methods with the IEntity interface. Some specific methods are described below (these methods are not relevant to process extensions, however, they may be helpful when writing custom channels – see section 4.1)


I assume you are using a Custom Process. You may need to write a Custom Channel.

Unfortunately, I can not be much help on Custom Channels, I am struggling with writing my own first Custom Channel.

Has anyone out there successfully created their own Custom Channel?
#51411 by Jaymer
Wed Aug 21, 2019 5:13 pm
BobK wrote:Unfortunately, I can not be much help on Custom Channels, I am struggling with writing my own first Custom Channel.
?


Bob, what are you doing in aware where this is needed? Or helpful?
#51412 by BobK
Wed Aug 21, 2019 6:09 pm
Jaymer,

From the User Guide, I see that AwareIM can consume a third party RESTful web service and send JSON in the body of the request. That is great and I will need to do that, but have not gotten that far yet.

Unfortunately, when AwareIM exposes a RESTful web service for some third party to consume, the input parameters must be included in the URL and can not be in the body of the request. I need to be able to receive JSON in the body of the request.

If someone could tell me that I am wrong and AwareIM can receive JSON in the body, I would be red faced but extremely happy.

That is the reason for the Custom Channel, to be able to access the JSON in the body of the incoming request.

My belief of how this type of channel works is that my custom channel would receive the request, access the JSON in the body, create DataObjects and pass those to AwareIM. AwareIM understands DataObjects and would happily process them.

I am currently investigating how to implement the above.
#51413 by Jaymer
Wed Aug 21, 2019 6:20 pm
BobK wrote:Unfortunately, when AwareIM exposes a RESTful web service for some third party to consume, the input parameters must be included in the URL and can not be in the body of the request. I need to be able to receive JSON in the body of the request.


For sake of discussion, is this an accurate restatement:
--> An AwareIM RESTful web service can only receive data with a GET Action, and not a POST action.
#51414 by BobK
Wed Aug 21, 2019 6:40 pm
Jaymer wrote:
BobK wrote:Unfortunately, when AwareIM exposes a RESTful web service for some third party to consume, the input parameters must be included in the URL and can not be in the body of the request. I need to be able to receive JSON in the body of the request.


For sake of discussion, is this an accurate restatement:
--> An AwareIM RESTful web service can only receive data with a GET Action, and not a POST action.



The following is from the User Guide and why I made my statement above:

If your REST-ful service is implemented by a process that takes some object as input
(should only be one object) then values of attributes of this object have to be provided as
parameters in the URL


When describing how to expose a RESTful web service, the User Guide does not mention any HTTP Verb, so I assume only a GET Action will work.

EDIT: My assumptions made in the post are incorrect. See https://www.awareim.com/forum/viewtopic.php?f=1&t=10820&p=51488#p51488
Last edited by BobK on Fri Aug 30, 2019 3:40 pm, edited 1 time in total.
#51415 by Jaymer
Wed Aug 21, 2019 7:01 pm
well, you could do a Node.js middleware to parse & repackage it.
Its a pain in any event cause you can't do it in Testing mode, so you have to constantly publish.

Who is online

Users browsing this forum: No registered users and 17 guests