Hello everyone,

Previously, I posted a question in this forum to find out if it's possible to send webhooks from Creatio to my external REST API. According to the documentation, it seems that only receiving webhooks from an external service is supported. In response, I was suggested to create a process in the control panel and configure actions to listen for changes in some model and then send that information to my web service.

So far, I've followed these two steps:

  1. I created a web service and configured its headers and parameters.

  2. I created a process that listens for changes in a model, such as Opportunity, and then sends that information to my web service (which is my REST API).

I managed to do this process manually, but currently, I'm developing an integration with Node.js, and I'm consuming Creatio's OData4 REST API. My goal is to automate these two previous steps using code.

My questions are as follows:

  1. Is it possible to create a web service from Creatio's REST API?

  2. Is it possible to create a process using native C# code or metadata from the REST API?

I appreciate any guidance you can provide!

Like 0

Like

6 comments

I'm not sure I understand your question exactly. Are you saying you want to create a service endpoint in Creatio that you'll consume from outside of Creatio? 

If that is the case, then yes. You can create custom endpoints in Creatio that can be consumed from outside. Sample service shown here: https://customerfx.com/article/creating-a-web-service-and-consuming-it-…

More here: https://academy.creatio.com/documents/technic-sdk/7-16/creating-configu…

To consume it from outside, you'd first need to authenticate, see https://academy.creatio.com/documents/technic-sdk/7-16/authentication-e…

Then, you'd POST/GET etc the endpoint for the configuration service.

Ryan

Ryan Farley,

Ryan Farley,

Can I create a process and webservices using low code or rest api? 

No. That area does not create a Web service. That area only defines how to call an existing web service. That is used if you need to call an external API from a process in Creatio. You defined the URLs in parameters there so the process element knows how to call the web service. 

Ryan

Ryan Farley, 







Thank you very much for your help, however my other question is if you have ever had the opportunity to create web processes and services using the odata rest service?

Brayan,

I am not sure what you're asking. Are you referring to consuming the Creatio OData API? If that is the case, you can see Postman examples of this here: 

https://documenter.getpostman.com/view/10204500/SztHX5Qb

Ryan

Show all comments

Hello everyone,

Previously, I posted a question in this forum to find out if it's possible to send webhooks from Creatio to my external REST API. According to the documentation, it seems that only receiving webhooks from an external service is supported. In response, I was suggested to create a process in the control panel and configure actions to listen for changes in some model and then send that information to my web service.

So far, I've followed these two steps:

  1. I created a web service and configured its headers and parameters.

  2. I created a process that listens for changes in a model, such as Opportunity, and then sends that information to my web service (which is my REST API).

I managed to do this process manually, but currently, I'm developing an integration with Node.js, and I'm consuming Creatio's OData4 REST API. My goal is to automate these two previous steps using code.

My questions are as follows:

  1. Is it possible to create a web service from Creatio's REST API?

  2. Is it possible to create a process using native C# code or metadata from the REST API?

I appreciate any guidance you can provide!

Like 0

Like

1 comments

Im trying to send webhooks from Creatio to my custom Rest Api, for example when an opportunity was edited send it, It this possible ? Because I can see in the documentation that it is different.... 

In other hand I'm also using the cookie auth and I'll be able to create webhooks using rest and batch. 

Like 1

Like

4 comments

The webhooks documentation is for *receiving* webhooks. For sending a Webhook you'd need to add a web service and then you can just execute that from a process.

See this to set up the web service to execute your webhook:

https://academy.creatio.com/docs/user/customization_tools/web_services/…

and this to execute it from a process: 

https://academy.creatio.com/docs/user/bpm_tools/process_elements_refere…

Ryan

Is it something that can also be used in marketing automation campaigns ?



NB: it's a good use case that definitely should be added to the official documentation ;)

Ryan Farley,

Thanks that makes sense, when you mentioned web services you mean my local rest api right? 

Brayan,

No there is a web services area in Creatio where you can define the web service. You'll provide the URL, any parameters to include, whether it is GET or POST etc. See that info here 

https://academy.creatio.com/docs/user/customization_tools/web_services/…

Ryan

Show all comments

Hi Community,

 

I have the following requirement where I need to open the ActivitySectionV2 page from a detail schema. More specifically, I've created a button in a custom detail which, when pressed, opens the ActivitySectionV2 page, as you can see in the following image.

 

In addition to opening the page, this button should transfer the records Contact Id from the detail  to the Activity section. Inside the ActivitySectionV2 page, I'll use these values for the QuickFilters of the Employees.

 

 

To achieve this, I tried using messages between modules. And also, loading the section module through the detail but both didn't work. 

 

Detail Schema

messages: {
			"SetActivityFilters": { 
				mode: Terrasoft.MessageMode.BROADCAST,
				direction: Terrasoft.MessageDirectionType.PUBLISH
			}
},
methods: {
openActivities: function(){
 
				var collection = this.get("Collection");
 
				var contactIds = [];
 
				for(var i = 0; i < collection.collection.items.length; i++){
					if(collection.collection.items[i].values.imdContact !== undefined){
						contactIds.push(collection.collection.items[i].values.imdContact.value);
					}
				}
 
				window.console.log(contactIds);
 
 
 
				//Open Activity + Send Contacts
				this.sandbox.publish("SetActivityFilters", contactIds, [this.sandbox.id]);
				this.sandbox.publish("PushHistoryState", {hash: "SectionModuleV2/ActivitySectionV2"});
 
 
				/*this.sandbox.loadModule("SectionModuleV2", {
					renderTo: "centerPanel",
					//id: "SectionModuleV2_ActivitySectionV2",
					instanceConfig: {
						parameters: {
							ContactIds: contactIds 
						},
						schemaName: "ActivitySectionV2",
						isSchemaConfigInitialized: true,
						useHistoryState: true,
						//isSeparateMode: true,
						//entitySchemaName: "Activity",
				  }
		  });*/
}}

 

ActivitySectionV2

 

			messages: {
			         "SetActivityFilters": { 
				          mode: Terrasoft.MessageMode.PTP,
				          direction: Terrasoft.MessageDirectionType.SUBSCRIBE
			         }
		    },		
            methods: {
             init: function(){
				this.callParent(arguments);
				this.sandbox.registerMessages(this.messages);
				this.processMessages();
 
				//window.console.log(this.parameters);
			},
 
			onRender: function(){
				this.callParent(arguments);
			},
 
			processMessages: function() {
				this.sandbox.subscribe("SetActivityFilters", function(result){
 
					window.console.log("'MessageToSubscribe' received" + result);
 
				}, this, ["SectionModuleV2_CaseSection_CardModuleV2_detail_imdSchema54bae29aDetail1d5019a5imdCaseParticipants"]);
			}}

Could you please tell me if there is any other way I can achieve this requirement and what is wrong with my approach.

 

Thanks in Advance.

 

Best Regards,

Pedro Pinheiro

Like 1

Like

3 comments

Hello Pedro,

 

Current code you shared will open the Activity section indeed, but there is no logic in the code that will add values to the quick owner filter. And it's so since it's impossible to do via the scenario you described. Why: because to set such filtration dynamically the addNonPeriodFilterValue method from the FixedFilterViewModelV2 should be called (just check it in the debugger when selecting owner from the lookup inside the filter) and I found no ways of doing that from the init method of ActivitySectionV2. So you need to find other ways of achieving the business task.

Hi Oleg Drobina,

 

Thanks for the response.

 

Currently, to simplify the problem. I'm just trying to fully open the ActivitySection and print the values that are coming from the detail, without applying the filters.

 

To do this I had to change the initial code, because my activity was not receiving the "SetActivityFilters" message. So, what I did was to load the module instead, using the following code:

methods: {
			onActiveRowAction: function(buttonTag, primaryColumnValue) {
				this.mixins.ConfigurationGridUtilitiesV2.onActiveRowAction.call(this, buttonTag, primaryColumnValue);
			},
 
			init: function(){
				this.callParent(arguments);
			},
 
			openActivities: function(){
 
				var collection = this.get("Collection");
 
				var contactIds = [];
 
				for(var i = 0; i &lt; collection.collection.items.length; i++){
					if(collection.collection.items[i].values.imdContact !== undefined){
						contactIds.push(collection.collection.items[i].values.imdContact.value);
					}
				}
 
				window.console.log(contactIds);
 
				this.sandbox.loadModule("SectionModuleV2", {
					renderTo: "centerPanel",
					id: "SectionModuleV2_ActivitySectionV2",
					instanceConfig: {
						parameters: {
							ContactIds: contactIds 
						},
						schemaName: "ActivitySectionV2",
						isSchemaConfigInitialized: true,
						useHistoryState: false,
					}
				});
			}
}

I followed this post in the community to try to implement this https://community.creatio.com/questions/pass-parameters-section

 

When pressing the "Open Activity" button, I get this error and behaviour:

 

After some debbuging, I found that the context does not have the module that I'm trying to load. Maybe, I'm missing some dependencies.

 

 

Could you please help me understand this issue?

 

Once I figure this out, I will check another approach to apply the filters.

 

Thank you.

 

Best Regards,

Pedro Pinheiro

 

 

 

 

 

 

 

 

To pass values from the detail (in my example it was ContractDetailV2) to the ActivitySectionV2:

 

1) In the ContractDetailV2:

onOpenActivityButtonClick: function() {
				this.sandbox.publish("PushHistoryState", {
					hash: "SectionModuleV2/ActivitySectionV2",
					silent: false,
					stateObj: {
						value: "5266908c-f3d1-4c5c-9097-f0dfbdbf900b",
						displayValue: "Email Supervisor"
					}
				});
			}

Here you can pass an array in the "value" property of the stateObj object as well.

 

onOpenActivityButtonClick is a click-handler for the button:

{
                "operation": "insert",
                "name": "OpenActivityButton",
                "parentName": "Detail",
                "propertyName": "tools",
                "values": {
                    "itemType": Terrasoft.ViewItemType.BUTTON,
                    "caption": {"bindTo": "Resources.Strings.OpenActivityButtonCaption"},
                    "click": {"bindTo": "onOpenActivityButtonClick"},
                    "style": Terrasoft.controls.ButtonEnums.style.TRANSPARENT,
                    "enabled": true
                }
            }

 

2) In the ActivitySectionV2:

define("ActivitySectionV2", [], function() {
	return {
		entitySchemaName: "Activity",
		details: /**SCHEMA_DETAILS*/{}/**SCHEMA_DETAILS*/,
		diff: /**SCHEMA_DIFF*/[]/**SCHEMA_DIFF*/,
		methods: {
			init: function() {
				this.callParent(arguments);
				var shouldUpdateFilter = this.checkHistoryState();
				if (shouldUpdateFilter.value &amp;&amp; shouldUpdateFilter.displayValue) {
					var tag = "Owner";
					var row = {
						value: shouldUpdateFilter.value,
						displayValue: shouldUpdateFilter.displayValue
					}
					console.log("Row value: " + row.value + " and Row displayValue: " + row.displayValue);
				}
			},
			checkHistoryState: function() {
				var historyState = this.sandbox.publish("GetHistoryState");
				return historyState?.state;
			}
 
		}
	};
});

As a result you will be able to get passed values in the init method execution:

Show all comments

I am currently involved in an exciting project involving system integration using OAuth2, and I would like to share my concern with all of you. In this case, I'm looking to implement OAuth2 authentication similar to what is achieved with Salesforce, but on the Creatio platform. I want to allow my application to connect to Creatio, access customer data and opportunities, and all this from the cloud, without the need for local deployments (on-site-deployment).

I really appreciate if someone in the community has explored these areas and can help me, I want to know if Oauth2 authentication is viable for this case, or I would simply go for the basic authentication by cookie

Like 0

Like

1 comments

Hello,

 

You can set up OAuth 2.0 authentication integration on your Creatio website with the following basic tools

 

Information on how to do this can be found on the Academy's website here:

https://academy.creatio.com/docs/user/on_site_deployment/deployment_additional_setup/oauth_2.0_authorization/set_up_oauth20_authorization_for_integrated_applications

Show all comments

Hello Community,

 

We have a requirement where we need to show only investigation edit page and hide all the others in the + button of the detail, as displayed in figure below.

 

.

 

How can we achieve this?

 

Thank you,

Like 0

Like

1 comments

Hello Mariam,

 

Here is the example with the "Contracts" detail on the contact edit page where I have setup several edit pages:

Here is the list of these edit pages on the contact page:

And my task is to remove the "Specification" option. To do that:

 

1) Create a replacing view model for the "ContractDetailV2"

2) Add the following code to the methods of this replacing view model:

getEditPages: function() {
				var editPagesCollection = this.get("EditPages");
				var editPagesItems = editPagesCollection.getItems();
				var indexToRemove = editPagesItems.map(e =&gt; e.values.Caption).indexOf("Specification");
				editPagesCollection.removeByIndex(indexToRemove);
				return editPagesCollection;
			}

3) Save the schema and refresh the page in the UI

 

As a result the "Specification" option is gone from the list:

So in this case the main objective is to override the logic of the getEditPages method according to your business needs.

Show all comments

Currently, I'm facing an issue while attempting to initiate a login request. Unfortunately, an error is persisting throughout the process. I suspect that there might be an additional configuration step required on my end, but I'm uncertain about the specifics.



The URL I am using for the login attempt is as follows:

https://057678-sales-enterprise.creatio.com/



This URL corresponds to the sales division of my trial account.



Could you kindly provide me with guidance on any potential configuration steps I might be missing or if there are specific settings I need to adjust? Your expertise would greatly assist me in resolving this matter and continuing my progress with the platform.









I'm using the wrong url?

Like 0

Like

2 comments

Hello,



Thank you for your question!

We attached the article where you can find the instructions on how to correctly set up the request, but the error indicates a problem with login and password. Please check the correctness of the login and password.

https://academy.creatio.com/docs/developer/integrations_and_api/authent…

Hello, thanks, the problem was modifying my password in user organization configuration roles, now it works.

Show all comments

Hi Community,

 

Through a webservice we are receiving several account records. Some of these new accounts have a url with more than 250 chars, which is the limit set by Creatio for this field. As this limit is exceeded, we are receiving errors from the database.

 

Is there a way to increase the character limit for the Web Link to 500?

 

Thank you.

 

Best Regards,

Pedro Pinheiro

Like 3

Like

1 comments

Hello!



No, this element has a fixed length that cannot be modified.

Show all comments

Hi Community,

 

The goal is to execute a specific process each time another process returns errors on it's logs.

 

To achieve this we found on the community this post (https://community.creatio.com/questions/Notifyuserifbusinessprocessfails), where someone had the same goal. The correct answer for that post, says that we need to "create a view based on the SysProcessLog table and add this newly created object into your business process as a starting signal".

 

After creating the view and adding the new object to the business process as a starting signal, the process still does not run.

 

 

We checked the view and it's being populated correctly. Only the modified/added trigger are not being set.

 

To create the view we used the following guide https://academy.creatio.com/documents/technic-sdk/7-16/localizing-views.

 

Could you please help us understand and solve this issue?

 

Thank you.

 

Best Regards,

Pedro Pinheiro

Like 0

Like

1 comments

Views don't trigger signals. 

I was attempting to do the same and ended up running the process on a timer to continuously check for errors on an interval. It would be great to have either an ootb way to notify someone about process errors or the ability to handle an error condition in the process itself.

Ryan

Show all comments

Hi guys,

How to solve the below error it is occourig while logging into my local instance.

Thanks and regards,

Mohith.

Like 0

Like

0 comments
Show all comments