how to access notification objects(not BO) via custom api
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
how to access notification objects(not BO) via custom api
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)
-
- Posts: 7526
- Joined: Sun Apr 24, 2005 12:36 am
- Contact:
Re: how to access notification objects(not BO) via custom ap
Notifications are put in the Context just like business objects. Both business objects and notifications implement the same interface IObject
Aware IM Support Team
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
Re: how to access notification objects(not BO) via custom ap
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.
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
Re: how to access notification objects(not BO) via custom ap
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.
Re: how to access notification objects(not BO) via custom ap
The following is from the "Programmers Reference" (the BOLD is mine):
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?
I assume you are using a Custom Process. You may need to write a Custom Channel.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)
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?
Bob
-
- Posts: 370
- Joined: Sat Apr 28, 2018 3:33 am
- Location: India
- Contact:
Re: how to access notification objects(not BO) via custom ap
Thanks Bob! Now after reading it carefully I think I can find those objects by weekend-treasure hunt.
Re: how to access notification objects(not BO) via custom ap
Bob, what are you doing in aware where this is needed? Or helpful?BobK wrote: Unfortunately, I can not be much help on Custom Channels, I am struggling with writing my own first Custom Channel.
?
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: how to access notification objects(not BO) via custom ap
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.
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.
Bob
Re: how to access notification objects(not BO) via custom ap
For sake of discussion, is this an accurate restatement: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.
--> An AwareIM RESTful web service can only receive data with a GET Action, and not a POST action.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL
Re: how to access notification objects(not BO) via custom ap
Jaymer wrote:For sake of discussion, is this an accurate restatement: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.
--> 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:
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.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
EDIT: My assumptions made in the post are incorrect. See https://www.awareim.com/forum/viewtopic ... 488#p51488
Last edited by BobK on Fri Aug 30, 2019 3:40 pm, edited 1 time in total.
Bob
Re: how to access notification objects(not BO) via custom ap
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.
Its a pain in any event cause you can't do it in Testing mode, so you have to constantly publish.
Click Here to see a collection of my tips & hacks on this forum. Or search for "JaymerTip" in the search bar at the top.
Jaymer
Aware Programming & Consulting - Tampa FL
Jaymer
Aware Programming & Consulting - Tampa FL