Kentico 9 · Kentico manages the main website - place the Kentico web project (CMS folder) into the...

118
Kentico 9

Transcript of Kentico 9 · Kentico manages the main website - place the Kentico web project (CMS folder) into the...

  • Kentico 9

  • 1. Integrating 3rd party systems . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31.1 Integrating Kentico with other applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3

    1.1.1 Child web application fails to start . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 41.2 Kentico REST service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 6

    1.2.1 Configuring the REST service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61.2.2 Authenticating REST requests . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101.2.3 Getting data using REST . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 11

    1.2.3.1 Examples of data retrieved via the REST service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 181.2.3.2 ODATA service documents . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21

    1.2.4 Manipulating data using REST . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 221.2.4.1 Managing pages using REST . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241.2.4.2 Managing objects using REST . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28

    1.2.5 Sending REST requests from code . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311.3 Using the integration bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32

    1.3.1 Integration bus overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 331.3.2 Enabling the integration bus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 391.3.3 Creating integration connectors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40

    1.3.3.1 Implementing outgoing synchronization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 421.3.3.2 Implementing incoming synchronization . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49

    1.3.4 Managing integration tasks . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 521.3.5 Example - Integration connector . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 531.3.6 Reference - Integration bus data types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 561.3.7 Integration bus database model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58

    1.4 Using the Kentico API externally . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 581.4.1 Displaying Kentico content in external applications . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61

    1.5 Data.com integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 661.5.1 Mapping Data.com fields . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 681.5.2 Searching Data.com for contacts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 691.5.3 Buying contacts from Data.com . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 741.5.4 Customizing the Data.com integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74

    1.6 Salesforce integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 751.6.1 Configuring Salesforce integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 761.6.2 Replicating contacts to Salesforce . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 791.6.3 Example - Replicating a contact into a Salesforce lead . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 811.6.4 Force.com integration API . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82

    1.7 Strands Recommender integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 901.7.1 Integrating the Strands Recommender service into your store . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 911.7.2 Placing Strands recommendations on a page . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 931.7.3 Placing Strands recommendations into emails . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 961.7.4 Troubleshooting the Strands Recommender integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 961.7.5 Customizing how products are categorized in the Strands integration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98

    1.8 Integrating SharePoint . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1001.8.1 Configuring SharePoint integration connections . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101

    1.8.1.1 Connecting to SharePoint Online . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1021.8.2 Configuring SharePoint integration web part . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1031.8.3 Configuring SharePoint integration settings . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1061.8.4 Displaying SharePoint data in Kentico . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1061.8.5 Example - Displaying a SharePoint picture library in Kentico . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1091.8.6 Managing SharePoint libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 114

    1.8.6.1 Working with files from SharePoint libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 117

  • Integrating 3rd party systemsOut-of-the-box integrations

    Integration tools

    Integrating Kentico with other applicationsIf you need to combine your Kentico website with an existing application, consider the issues described on this page.

    Location of Kentico and your application

    You can organize the Kentico web project and your application in the following ways:

    Mixing both applications together

    If you wish to share functionality, content, security information and session/application variables between Kentico and your application, youcan mix both applications into a single project. The easiest way is to use the Kentico web project as the main application, since it's alreadycorrectly configured. You can add your own assemblies, projects, ASPX pages and other files to the Kentico solution.

    Data.com

    Keep your contacts and accounts up to date by comparing them with the Data.com business directory.

    Salesforce

    Automatically replicate contacts coming from your Kentico websites into your organization in SalesForce.

    Product recommendations

    Offer relevant products to your customers based on conditions that you define. The functionality uses the Strands Recommenderengine.

    SharePoint

    Display data from a SharePoint server on your website.

    REST service

    Access and manipulate Kentico data using a RESTful web API.

    Integration bus

    Synchronize data between Kentico and any other application in real time.

    Other integration options

    Use the Kentico API and controls externallyCombine the Kentico project with another application

  • If you need to display your own ASPX pages on the actual website, you can register them as and then createASPX page templatesnew pages in the site's content tree based on the templates.If your website is built using the , see: , portal engine Using both ASPX and portal templates on a single site Adding custom code to

    .portal engine page templatesTo integrate applications that extend the system's back-end administration interface, you can create .custom modules

    Using separate nested applications

    If your application needs to run independently from Kentico, you can host separate applications in your IIS. There are two possible scenarios:

    Kentico manages the main website - place the Kentico web project (CMS folder) into the root of the website and your externalapplication into a sub-directory. You need to create a virtual directory in IIS for the external application.Kentico only provides a sub-section of the website or serves as a content repository - install the Kentico web project into asub-directory under your application.

    Sharing security information between Kentico and your application

    If you wish to use shared authentication for both your application and Kentico, you need to configure your environment for single.sign-on

    To use a single system of permissions (authorization), you can leverage and .permissions custom modules

    Child web application fails to startBy default, child web applications inherit the configuration of their parent application. This can prevent the child application from starting whencertain sections of the aren't compatible across applications. For example, if the child application doesn't share the sameweb.configlibraries, handlers, modules, master pages or themes with the parent application. This page describes how you can solve some of thesituations resulting from nesting different applications together.

    Breaking web.config inheritance in child applications

    Use the tag with the attribute set to to ensure that the configuration applies to the parent weblocation inheritInChildApplications false application only. This can be useful when you don't want to inherit the parent application's settings to the child application. The path attributeset to "." ensures that the location tag covers the default path.

    Example

    The following example shows how you can break inheritance for , , , , and in yourcontrols namespaces assemblies modules handlersweb.config file. None of the settings enclosed in the tag with set to are inherited by the childlocation inheritInChildApplications falseapplications.

    By default, child applications inherit the configuration specified in the parent application's web.config file. This can make them fail tostart. See for more information.Child web application fails to start

    Using the location tag break configuration inheritance

    https://docs.kentico.com/display/K9/Developing+websites+using+ASPX+templateshttps://docs.kentico.com/display/K9/Developing+websites+using+the+Portal+enginehttps://docs.kentico.com/display/K9/Using+both+ASPX+and+portal+templates+on+a+single+sitehttps://docs.kentico.com/display/K9/Adding+custom+code+to+portal+engine+page+templateshttps://docs.kentico.com/display/K9/Adding+custom+code+to+portal+engine+page+templateshttps://docs.kentico.com/display/K9/Creating+custom+moduleshttps://docs.kentico.com/display/K9/Configuring+single+sign-onhttps://docs.kentico.com/display/K9/Configuring+single+sign-onhttps://docs.kentico.com/display/K9/Configuring+permissionshttps://docs.kentico.com/display/K9/Creating+custom+modules

  • Specifying different web.config configurations for child applications

    By specifying a value for the attribute in the tag, you can apply different configuration settings to specific folders and files. Thispath locationway, you can distribute parent or child application settings through one configuration file.

    The default value for the attribute is ".". You can only specify one value in the attribute.path path

    Example

    The following example shows a configuration that specifies different settings for two specific folders. One of the folders belongs to a parentapplication and the nested folder belongs to a child application:

    Using the location tag break configuration inheritance

    A different approach to removing inheritance is using the and tags. The tags remove irrelevant modules in the child web application. However, this approach is not supported and implemented the same way across all the elements and itemsin the web.config file.

  • 1. 2.

    Kentico REST serviceREST is an abbreviation of — a style of software architecture designed for distributed systems, typically forRepresentational state transferthe World Wide Web. Kentico has a built-in REST service, which can be used to read, create, update and delete virtually any object or pagewithin the system. These operations are performed by requesting specific URLs. The Kentico REST service is RESTful, which means that itsupports both directions of data transfer (from and into the system).

    Kentico also provides the web part, which can be used to display data obtained from the REST service in a simpleGrid for REST servicegrid. You can find an example of this web part on the page on the sample ./Examples/API/REST-service Corporate Site

    Configuring the REST service

    REST prerequisites

    Before you can enable the Kentico REST service, you must ensure the following:

    In Windows

    Go to and click in the left menu.Control Panel -> Programs and Features Turn Windows features on or off

    Windows 7 / Windows Server 2008

    Expand the node in the dialog window.Microsoft .NET Framework Make sure that both of the following features are installed:

    Windows Communication Foundation HTTP ActivationWindows Communication Foundation Non-HTTP Activation

  • 1. 2.

    Windows 8 / Windows Server 2012

    Expand the node..NET Framework 4.5 Advanced ServicesMake sure that the feature is installed.WCF Services -> HTTP Activation

    Error: "Could not load type 'System.ServiceModel.Activation.HttpModule' from assembly 'System.ServiceModel"

    If your application returns the above error after enabling HTTP Activation, you need to manually register the correct version ofASP.NET.

    See for detailed information.https://msdn.microsoft.com/en-us/library/hh169179%28v=nav.70%29.aspx

    https://msdn.microsoft.com/en-us/library/hh169179%28v=nav.70%29.aspx

  • 1. 2. 3.

    4.

    1. 2. 3.

    4. 5. 6.

    In IIS Manager

    Select the website for which you want REST to be enabled.Open the configuration.AuthenticationEnsure that authentication is enabled. You can also have either or authentication enabled dependingAnonymous Forms Windowson your environment.Disable and other types of authentication (leave and either or enabled).Basic Anonymous Forms Windows

    Once you have these prerequisites met, you can proceed to configuring the REST service in the Kentico instance.

    Configuring the REST service

    Once you meet the prerequisites for using the REST service, configure the following settings for the Kentico instance:

    Edit your application's file.web.configFind the section directly under the root (i.e. not under a specific element).system.webServer Add the following attribute to the element:

    Log in to the Kentico administration interface.Open the application.SettingsSelect the category and configure the settings:Integration -> REST

    REST setting Description

    Service enabled Enables or disables the Kentico REST service.

    Service enabled for Choose if the REST service allows access to objects, pages, orboth.

    Authentication type Determines which type of the REST serviceauthenticationuses. Supported types are and authentication.Basic Forms

    Note: You can authenticate REST requests using the hashquery string parameter in both modes.

    Always check page security If disabled, security is not checked when accessing publishedversions of pages. If enabled, security is always checked.

  • 6.

    1.

    Page access is read only If enabled, the REST service only allows GET requests forpages (pages cannot be modified).

    Object access is read only If enabled, the REST service only allows GET requests forobjects (objects cannot be modified).

    Allowed page types Specifies a list of that the REST service is allowedpage typesto access. Enter the code names of page types separated bysemicolons.

    If empty, all page types are allowed.

    Allowed object types Specifies a list of objects types that the REST service isallowed to access. If empty, all object types are allowed.

    Generate authentication hash for URL Click the link to generate an hash for specificauthenticationREST URLs.

    Enter the full absolute URL of the REST request, including theprotocol, website domain name, virtual directory, ,REST pathand query string . For example:parameters

    http://mywebsite.com/rest/content/currentsite/en-us/all/news?format=json

    The system adds the authentication hash parameter to theURL. You can copy the URL and use it to perform the RESTrequest without any other type of authentication.

    Restrictions:

    Only works for GET requests (read only data retrieval)You cannot use hash parameter authentication for obje/allct retrieval requests ( ).~/rest//all

    Default encoding Sets the character encoding that the REST service uses forrequests that do not contain a supported headeAccept-Charsetr.

    Allow sensitive fields for administrators If enabled, REST requests authenticated using the credentialsof users with the Global administrator are allowedprivilege levelto work with data fields that contain sensitive information (forexample fields related to passwords).

    Requests authenticated under non-administrator users canNEVER access sensitive fields, regardless of this setting'svalue.

    Enabling upload of large data

    If you are planning to upload large-size data into Kentico through the REST service, it is necessary to specify the required data size limit inthe application's file. This can be done by adding the following pieces of code into the section at the endweb.config of the web.config file:

    Insert a element into the sub-section:

    Tip: If you encounter issues with the Kentico REST service in your environment, you can try investigating the WCF trafficusing tracing and message logging tools. See the article for more information.Tracing and Message Logging

    Note: This sample sets all limits to 10 MB. You may need to enter different values according to your specific needs.

    https://docs.kentico.com/display/K9/Page+typeshttps://docs.kentico.com/display/K9/User+managementhttps://msdn.microsoft.com/en-us/library/ms751526%28v=vs.110%29.aspx

  • 1.

    2.

    Add a element under the sub-section:

    The in the code above only contains a sample value and needs to be replaced with the actual root address of thebaseAddressREST service (depending on your website's domain name).

    Authenticating REST requestsEvery REST request needs to be authenticated. You can select the of the REST service in Authentication type Settings -> Integration ->

    .REST

    Basic authentication

    With Basic authentication, you need to specify the username and password through the line in the header of every RESTAuthorizationrequest. The header line consists of:

    The authentication type ( )BasicThe username and password connected by a colon ( ), encoded using the Base64 algorithmusername:password

    For example, the following header line uses as the authentication credentials:RestClient:MyPassword

    Authorization: Basic UmVzdENsaWVudDpNeVBhc3N3b3Jk

    Once authenticated, the system allows the REST request to perform operations depending on the specified user's and privilege level permiss.ions

    Forms authentication

    When using of requests, the system identifies users based on the active session and the authentication ticket stored informs authenticationthe .ASPXFORMSAUTH cookie. You can use forms authentication to create a web interface with a login page, and allow users to sendREST requests through their browser.

    Important: We strongly recommend using to protect the authentication credentials in the request headers. See also: SSL Configuring SSL

    Note: The type of the Kentico REST service does not require Basic Authentication to be enabled in IIS. KeepBasic authenticationBasic Authentication disabled in IIS as described in .Configuring the REST service

    https://docs.kentico.com/display/K9/User+managementhttps://docs.kentico.com/display/K9/Configuring+permissionshttps://docs.kentico.com/display/K9/Configuring+permissionshttp://msdn.microsoft.com/en-us/library/7t6b43z4%28v=vs.100%29.aspxhttp://en.wikipedia.org/wiki/Transport_Layer_Securityhttps://docs.kentico.com/display/K9/Configuring+SSLhttps://docs.kentico.com/display/K9/Configuring+SSL

  • 1.

    2.

    1. 2. 3. 4. 5.

    6.

    You cannot use forms authentication for the Kentico REST service if you have enabled in IIS.Windows authentication

    Forms authentication can pose a security threat, because logged in users may unknowingly click links that send malicious REST requests toyour site. To protect yourself from such attacks, take the following steps:

    Immediately after creating the session (i.e. first authentication), set up an by sending a POST request to theauthentication tokenfollowing URL:

    https:///rest/settoken?username=&password=&token=

    The authentication token can be an arbitrary string of characters, for example a GUID.

    Include the authentication token in the HTTP header of every REST request:

    Cms-Session-Token:

    Hash parameter authentication

    You can authenticate individual REST requests by adding a hash parameter to the URL. The hash parameter allows you to prepare RESTrequests that can be executed by unauthenticated users. Requests that contain the hash parameter ignore the other types of authentication— the value of the setting does not affect hash authentication.Authentication type

    To get the authentication hash for REST requests:

    Prepare the URL of your REST request in advance.Open the application.SettingsSelect the category.Integration -> RESTClick .Generate authentication hashEnter the full absolute URL of the REST request, including the protocol, website domain name, virtual directory, , andREST pathquery string . For example: parameters http://mywebsite.com/rest/content/currentsite/en-us/all/news?format=jsonClick .Authenticate

    The system adds the authentication hash parameter to the URL. You can copy the URL and use it to perform the REST request without anyother type of authentication.

    Getting data using RESTThe REST service allows you to retrieve page and object data from Kentico instances.

    Send requests using the to a URL in format: GET HTTP method /

    The base URL of the Kentico REST service is . For example, if your site is running at use /rest ,http://localhost/Kenticoas the base URL of the service. To learn about the available for pages and objects, see the http://localhost/Kentico/rest resource paths

    tables in the sections below. The requests return data in either XML, JSON, RSS or Atom format (see Examples of data retrieved via the for more information).REST service

    Character encoding

    Data retrieval requests return the results in the server's default character encoding. To get the results in a different encoding type, set the

    Restrictions

    Only works for GET requests (read only data retrieval)You cannot use hash parameter authentication for ( ). This is an/all object retrieval requests ~/rest//allintentional security limitation that protects global data in the system.

    Warning: Only use hash parameter authentication for loading data that you want to make publicly available. REST requests withhash authentication can be executed by anyone who obtains the URL (for example by intercepting the web request).

    REST base URL

    Sending a GET request to the base URL of the REST service exposes the service document (for ODATA browsing). Thedocument contains a list of all available primary object types (without child and binding object types) and the URLs under which theobjects can be accessed. See also: ODATA service documents

    http://en.wikipedia.org/wiki/HTTP#Request_methods

  • encoding in the field of the GET request's HTTP header. If the specified encoding is not available, the system uses the Accept-Charset Defa configured in .ult encoding Settings -> Integration -> Rest

    GET http://localhost/Kentico/rest/cms.user/administrator HTTP/1.1Authorization: Basic UmVzdENsaWVudDpNeVBhc3N3b3JkAccept-Charset: utf-8Content-Type: text\xml

    Getting page data

    To load the data of pages from Kentico websites, send GET requests to the appropriate URL — append the described resource pathsbelow to the base URL of your REST service.

    Resource format and example Description

    Single page

    /content/currentsite//document/ /content/currentsite/en-us/document/company/careers______________________________________________________

    A single page in the given culture from the site running on thedomain in the base URL.

    Identify the page using its .alias path

    /content/site///document/ /content/site/corporatesite/en-us/document/company/careers_

    A single page in the given culture on the specified site.

    Multiple pages

    /content/currentsite//all/ /content/currentsite/en-us/all/news

    /content/site///all/ /content/site/corporatesite/en-us/all/news_

    All pages starting with the specified .alias path

    /content/currentsite//childrenof/ /content/currentsite/en-us/childrenof/news

    /content/site///childrenof/ /content/site/corporatesite/en-us/childrenof/news_

    All child pages under the specified parent page. Does not includethe parent page itself.

    Getting object data

    To load the data of objects from Kentico, send GET requests to the appropriate URL – append the described below to the resource pathsbase URL of your REST service.

    Most object resources start with an name. To find the value for specific object types, view the of classes in the object type Code name Modul application, or the column of the database table.es ClassName CMS_Class

    Example

    You can further configure the data retrieval by adding to the URL.query string parameters

    Culture constants

    You can use the following constants instead of culture codes in page REST calls:

    defaultculture - the page version in the site's default cultureallcultures - page versions in all available cultures

    Example: /content/currentsite/defaultculture/document/company/careers

    https://docs.kentico.com/display/K9/Setting+page+aliaseshttps://docs.kentico.com/display/K9/Setting+page+aliases

  • Resource format and example Description

    Multiple objects

    / /cms.country_

    All objects of the given type assigned to the site running on thedomain in the base URL.

    If the object type does not use site bindings, returns all objects ofthe given type.

    //site//cms.country/site/corporatesite_

    All objects of the given type assigned to the specified site.

    If the object type does not use site bindings, returns all objects ofthe given type.

    //global /cms.emailtemplate/global_

    All global objects of the given type (objects not assigned to anysite).

    If the object type does not use site bindings, returns all objects ofthe given type.

    //all /cms.emailtemplate/all_________________________________________________________

    All objects of the given type (site-related objects from all sites andglobal objects).

    Note:

    /all object retrieval requests only work if the user account usedfor has the .authentication Global administrator privilege levelThe REST service does not allow object retrieval for/allrequests that use the URL parameter for . hash authentication

    These are intentional security limitations that protect global data.

    Single object

    ///cms.country/271_

    Object of the given type with the specified identifier (primary keyID).

    Ignores site bindings – object IDs are unique across all sites in thesystem.

    // /cms.country/usa_

    Object of the given type with the specified code name.

    For object types with site bindings, always returns the objectassigned to the site running on the domain in the base URL.

    //site// /cms.emailtemplate/site/corporatesite/Blog.NotificationToModerators/cms. / e431b7e6-9e6c-409d-a1d9-7emailtemplate site/corporatesite/48cbf51b5d6

    Object of the given type with the specified code name or GUIDvalue, assigned to the specified site.

    //global/ /cms.emailtemplate/global/Blog.NotificationToModerators

    607ed253-7842-48be-98d7-63e0714a6a/cms.emailtemplate/global/d1___________________________________________________________________

    Global object of the given type with the specified code name orGUID value.

    Child objects

    ///children/cms.country/271/children_

    All that are supported as child types for the specifiedobject typesobject. Only ID values can be used to identify the parent object.

    ///children//cms.country/271/children/cms.state_

    All objects of the given type that are children of the specified parentobject. Only ID values can be used to identify the parent object.

    Binding objects

    ///bindings /cms.user/53/bindings_

    All that are used as binding types (representobject typesrelationships with other objects) for the specified object. Only IDvalues can be used to identify the object.

    You can further configure the data retrieval by adding to the URL.query string parameters

    https://docs.kentico.com/display/K9/User+management

  • ///bindings/ /cms.user/53/bindings/cms.usersite_

    All objects of the given binding type that exist for the specifiedobject. Only ID values can be used to identify the object.

    Custom tables

    /cms.customtable//cms.customtable/customtable.sampletable_

    The class definition of the specified (includes datacustom tablesuch as the custom table's names, field definitions and searchsettings).

    /customtableitem. /customtableitem.customtable.sampletable_

    The data records stored in the specified custom table.

    Forms

    /cms.form//cms.form/contactus_

    The class definition of the specified (includes data such as theformform's names, basic settings and field definitions).

    /bizformitem.bizform. /bizformitem.bizform.contactus_

    The data records stored for the specified form.

    Other

    //site /cms.country/site_

    Lists all sites on which the specified object type is available andprovides the REST URLs under which the object data can beretrieved for individual sites (for ODATA browsing).

    /typeinfo/ /typeinfo/cms.user_

    The data for the specified object type. The TypeInfo is aTypeInfoset of properties that define the general behavior and basicproperties of object types (classes) in Kentico.

    /macro//macro/CurrentSite.SiteName

    Evaluates the given and serializes the result.macro expressionOnly works for macros that return a serializable result.

    When creating the macro expression:

    Do NOT add the encapsulating bracket charactersUse URL encoding for forbidden URL characters

    Data loading parameters

    When loading data via REST, you can append the following query string parameters to the request URL:

    Parameter Value (default bold) Description

    General

    format xml/json/atom10/rss20 Sets the format of the retrieved data. Forexample, append to the?format=jsonrequest URL to get data in JSON format.

    See also: Examples of data retrieved via theREST service

    localize______________________

    culture code__________________________

    If added, the system resolves all localization inside the returned data.expressions

    Without this parameter, requests alwaysreturn localization expressions in unresolvedformat. Supported by both page and objectretrieval requests.

    Specify the target language by entering thecorresponding into theculture codeparameter's value. You can find theavailable culture codes in the Localizationapplication on the tab.Cultures

    For example, append to the?localize=fr-frrequest URL to resolve all localizationexpressions into their French value (or thevalue in the default if theUI cultureexpression is not defined in French).

    https://docs.kentico.com/display/K9/Custom+tableshttps://docs.kentico.com/display/K9/Formshttps://docs.kentico.com/display/K9/Macro+expressionshttps://docs.kentico.com/display/K9/Working+with+resource+stringshttps://docs.kentico.com/display/K9/Working+with+resource+strings

  • hash hash string Allows you to the requestauthenticatewithout requiring an authentication headeror Forms authentication.

    See to learnAuthenticating REST requestshow to generate the hash value.

    Pages

    classnames page type code name ( )all Limits which the request returns.page typesSpecified as a list of page type code namesseparated by semicolons.

    For example, to retrieve only pagcms.articlees, append to the?classnames=cms.articlerequest URL.

    coupleddata true/false Determines if the request retrieves datastored in the fields of specific page types(coupled data).

    The default behavior depends on the type ofthe page request:

    Requests for single pages containcoupled data by defaultRequests for multiple pages that do notspecify the page type para(classnamesmeter) do NOT load coupled data bydefault

    For example, to load pages with coupleddata, append to the?coupleddata=truerequest URL.

    combinewithdefaultculture true/false Indicates if the request loads the defaultlanguage versions of pages if they do notexist in the specified culture.

    To load the default language versions ofpages, append ?combinewithdefaultculture=

    to the request URL.true

    selectonlypublished true/false Determines if the request loads only pagesthat are published on the live site.

    To also retrieve unpublished pages ,append to the?selectonlypublished=falserequest URL.

    version published/last Determines if the request returns the pageversions that are published on the live siteor the latest version that is being edited inthe application (when using Pages Workflo

    ).w

    To load the latest page versions, append ?v to the request URL.ersion=last

    Multiple pages or objects

    https://docs.kentico.com/display/K9/Page+typeshttps://docs.kentico.com/display/K9/Configuring+workflowshttps://docs.kentico.com/display/K9/Configuring+workflows

  • where SQL code ( )empty SQL WHERE condition for filtering theloaded data. The parameter only allows thefollowing types of SQL syntax:

    column names, values and basicoperators: =, !=, >, <AND & OR operators, parenthesescolumn BETWEEN AND value valuecolumn LIKE valuecolumn IN (values)column IS NULLNOT keyword for the aboveexpressions (NOT BETWEEN, NOTLIKE, NOT IN, IS NOT NULL)

    Other expressions and SQL functions arenot supported.

    Example: ~/rest/cms.user?Where=UserIsEditor=1

    orderby SQL code ( )empty SQL ORDER BY clause for modifying theorder of the items in the data. Theparameter allows the following values:

    one or more column names (separatedby commas)the ASC and DESC keywords

    Other SQL expressions and functions arenot supported.

    Append to use?orderby=##default##alphabetical order based on the objectdisplay name.

    columns column names ( )all columns Limits which data columns of the object orpage are loaded.

    For example, to load only the anUserNamed columns when retrieving users,UserIDappend to the?columns=UserName,UserIDrequest URL.

    If you add the parameter, the columns binar parameter is ignored (you can choosey

    whether to include binary columns byenumerating the corresponding columns).

    topn integer ( )all records SQL TOP N clause for filtering the loadeddata.

    For example, to load only the first 10records, append to the request?topn=10URL.

    Multiple objects

    offset integer ( )first record Sets the number of the first record that therequest returns (according to the order ofthe data). Allows you to implement paging ofthe data.

    For example, to load data starting from thethird item in the dataset, append t?offset=2o the request URL.

    Note: The parameter only worksoffsetwhen getting object data (not supported forpages).

  • maxrecords integer ( )all records Limits the maximum number of retrievedrecords. You can use the paramaxrecordsmeter in combination with the parametoffseter to retrieve a specific range of records.

    For example, to load items 11–20 from thedata, append to?offset=10&maxrecords=10the request URL.

    Note: The parameter onlymaxrecordsworks when getting object data (notsupported for pages).

    Objects

    objectdata true/false Indicates whether the request retrieves thedata fields of objects.

    To load only the metadata of an object,append t?objectdata=false&metadata=trueo the request URL.

    metadata true/false Determines if the request retrieves themetadata of objects (type, list of properties /columns).

    To load the metadata, append ?metadata=tr to the request URL.ue

    binary true/false Indicates whether the request retrievesbinary data (e.g. the data of files uploadedinto form fields). Binary data is retrieved in B

    format.ase64

    To include the binary data in the response,append to the request URL.?binary=true

    children true/false Indicates whether the result includes childobjects.

    To load child objects, append ?children=trueto the request URL.

    maxrelativelevel integer ( )all levels If the parameter is true, thischildrenparameters sets the maximum depth of theexported object tree structure.

    For example, to load all child objects downto the second level of the object tree,append t?children=true&maxrelativelevel=2o the request URL.

    bindings true/false Determines if the retrieved data includesbindings to child objects and sites. Requestsonly return bindings if the paramobjectdataeter is true.

    To load object data with its bindings,append to the request URL.?bindings=true

    otherbindings true/false Determines if the retrieved data includesbindings to other objects (M:Nrelationships). Requests only return bindingsif the parameter is true.objectdata

    To load object data with bindings to otherobjects, append to the?otherbindings=truerequest URL.

    metafiles true/false Determines if the retrieved data includesmetafiles attached to the object

    To load metafiles, append t?metafiles=trueo the request URL.

    relationships true/false Determines if the retrieved data includesobject relationships.

    To load relationships, append ?relationships to the request URL.=true

  • categories true/false Determines if the retrieved data includes theobject's category structure (if the object isstored in a hierarchical category structure).

    To load the category structure, append ?cat to the request URL.egories=true

    translations true/false Indicates whether the result includes atranslation table of foreign keys.

    To load the translation table, append ?transl to the request URL.ations=true

    hierarchy true/false If true, the response data is exported in ahierarchical structure (if false, the children –bindings – parent structure is flat).

    To export the data in a hierarchicalstructure, append to the?hierarchy=truerequest URL.

    Examples of data retrieved via the REST serviceThis page shows examples of data (all objects) obtained from the REST service in various formats.cms.country

    XML

    All objects retrieved in format.cms.country XML

    The data was obtained using the following URL: ~/rest/cms.country

    272 Afghanistan Afghanistan 12d61676-7541-4a4e-88f6-f02098b637fe 2013-10-21T14:20:12.293+02:00 AF AFG 273 Albania Albania af056090-4477-4826-ad41-7ce8e8d45d3a 2013-02-07T15:08:05.117+01:00 AL ALB

    ...

    246

    JSON

    The code below is an extract from data of the objects retrieved in format.cms.country JSON

    The data was obtained using the following URL: ~/rest/cms.country?format=json

    http://en.wikipedia.org/wiki/XMLhttp://en.wikipedia.org/wiki/JSON

  • {"cms_countries": [ { "cms_country": [ { "CountryGUID":"12d61676-7541-4a4e88f6-f02098b637fe", "CountryID":272, "CountryName":"Afghanistan", "CountryDisplayName":"Afghanistan", "CountryLastModified":"2013-10-21T14:20:12.293+02:00", "CountryTwoLetterCode":"AF", "CountryThreeLetterCode":"AFG" }, { "CountryGUID":"af056090-4477-4826-ad41-7ce8e8d45d3a", "CountryID":273, "CountryName":"Albania", "CountryDisplayName":"Albania", "CountryLastModified":"2013-02-07T15:08:05.117+01:00", "CountryTwoLetterCode":"AL", "CountryThreeLetterCode":"ALB" },

    ...

    ] }, { "TotalRecords": [ { "TotalRecords":"246" } ] }]}

    RSS 2.0

    All objects retrieved in format.cms.country RSS 2.0

    The data was obtained using the following URL: ~/rest/cms.country?format=rss20

    http://en.wikipedia.org/wiki/RSS

  • Atom 1.0

    All objects retrieved in format.cms.country Atom 1.0

    The data was obtained using the following URL: ~/rest/cms.country?format=atom10

    http://en.wikipedia.org/wiki/Atom_%28standard%29

  • ODATA service documentsThe Kentico REST service supports by providing service documents in a standard format for ODATA services. The serviceODATAdocuments provide information about the types of data available via the REST service and about the URLs under which the data can beaccessed.

    The service documents are available under the following URLs:

    ~/rest - exposes the service document. The document contains a list of all available primary object types (without child and bindingobject types) and the URLs under which the objects can be accessed.

    http://www.odata.org/

  • ~/rest//site - lists all sites on which the specified object type is available and provides the REST URLs under whichthe object data can be retrieved for individual sites.

    Manipulating data using RESTThe REST service allows you to manipulate the data of pages and objects on Kentico instances.

    Send requests using the , or to the appropriate URL. See the following documentation pages for details:POST PUT DELETE HTTP method

    Managing pages using RESTManaging objects using REST

    http://en.wikipedia.org/wiki/HTTP#Request_methods

  • 1.

    General data manipulation parameters

    When managing pages or objects via REST, you can append the following query string parameters to the request URL:

    Parameter Value (default bold) Description

    format xml/json Sets the format of the data submitted inPOST/PUT requests. For example, append

    to the request URL to submit?format=jsondata in JSON format.

    hash hash string___________________

    Allows you to the requestauthenticatewithout requiring an authentication headeror Forms authentication.

    See to learnAuthenticating REST requestshow to generate the hash value.

    Setting fields to empty values

    If you need to set a page or object field to an empty value using a REST request, use the following expression instead of an actual value:

    ##null## (for data in XML format)null (for data in JSON format)

    The null expression is particularly useful for non-string fields (typically fields storing foreign key IDs), where an empty string value would notproduce the desired results.

    For example, the following request updates the page of the sample Corporate Site and ensures that it does not have a user specifiedHomein the field:Created by

    HTTP method: PUTURL: ~/rest/content/site/corporatesite/en-us/document/HomeData (XML format):

    ##null##

    Uploading attachment files

    When uploading files via the REST service, use the following format for the binary data:

    base 64 encoding in requests using the XML data formatbyte array values in requests using the JSON data format (you can get the appropriate byte array by serializing your data via the Sy

    method)stem.Web.Script.Serialization.JavaScriptSerializer.Serialize

    Carefully consider the data type of the target field. Most page and object fields in Kentico do not store binary data directly, but instead containthe GUID of the corresponding attachment object. To find information about the requirements for your scenario, for ansend a GET requestexisting object of the given type and check the resulting data.

    For example, use the following steps to create a new page, including an image file as an attachment:CMS.File

    Send a request to create the attachment file itself ( object type, base64 encoding for the file binary in the cms.attachment Attachme field):ntBinary

    HTTP method: POSTURL: ~/rest/cms.attachment/currentsiteData (XML format):

    Data validation

    When inserting or updating data via the REST service, Kentico does not perform any validation. You need to ensure validation onthe side of the application sending the REST requests to prevent unwanted behavior.

    http://msdn.microsoft.com/en-us/library/bb292287%28v=vs.110%29.aspxhttp://msdn.microsoft.com/en-us/library/bb292287%28v=vs.110%29.aspx

  • 1.

    2. 3.

    4. 5.

    NewAttachmentFile.png .png 3180 image/x-png 183 47

    Store the value from the data of the response to the POST request that created the attachment.AttachmentGuidCreate the CMS.File page (set the field to the GUID of the new attachment object):FileAttachment

    HTTP method: POSTURL: ~/rest/content/currentsite/en-us/document/ImagesData (XML format):

    1685 .png .png NewAttachmentFile 96d6dfc9-4f3a-4a30-95af-4d7cc5a36f9a

    Store the value from the data of the response to the POST request that created the new CMS.File page.DocumentIDUpdate the data of the attachment object to include the ID of the new page (set the field to the AttachmentDocumentID DocumentI

    of the page):DHTTP method: PUTURL: ~/rest/cms.attachment/Data (XML format):

    120

    Managing pages using RESTThe REST service allows you to manipulate the data of pages on Kentico websites. Send requests using the , orPOST PUT DELETE HTTP

    to the appropriate URL — append the described below to the of your REST service.method resource paths base URL

    The base URL of the Kentico REST service is . For example, if your site is running at use /rest ,http://localhost/Kenticoas the base URL of the service. http://localhost/Kentico/rest

    Creating pages

    HTTP method: POST

    Resource format:

    /content/currentsite//document/ - creates a new page in the given culture for the site running on the domainin the base URL./content/site///document/ - creates a new page in the given culture on the specified site.

    Use the to identify the under which you want to create the new page.alias path parent page

    To learn more about working with pages, see .Managing pages using REST

    http://en.wikipedia.org/wiki/HTTP#Request_methodshttp://en.wikipedia.org/wiki/HTTP#Request_methodshttps://docs.kentico.com/display/K9/Setting+page+aliases

  • Set the name and other fields of the new page in the data of the POST request. Both and formats are supported for the data.XML JSON

    Examples

    Creates a page (CMS.MenuItem type) under the page New service Services

    XML JSON

    URL: ~/rest/content/currentsite/en-us/document/Services

    Data:

    4114 Newservice 23438

    URL: ~/rest/content/currentsite/en-us/document/Services?format=json

    Data:

    {"NodeClassID":4114,"DocumentName":"New service","DocumentPageTemplateID":23438}

    Creates a page (CMS.News type) under the pageNews article News

    XML JSON

    URL: ~/rest/content/currentsite/en-us/document/News

    Data:

    4112 Newsarticle 2014-06-05T00:00:00+02:00 Summary Text

    URL: ~/rest/content/currentsite/en-us/document/News?format=json

    Data:

    {"NodeClassID":4112,"NewsTitle":"News article","NewsReleaseDate":"2014-06-05T00:00:00Z","NewsSummary":"Summary","NewsText":"Text"}

    Creates a version of the existing page on the sample Corporate siteFrench Services

    Important:

    When creating new pages, always set the field. To find the value for a page type, NodeClassID NodeClassID get a page using the REST service and check the data or view the column in the databaseof the given type ClassID CMS_Class

    table.The request data must contain values for for the given .all fields that are set as required page typeThe service automatically sets the system fields of the new page (such as the ID and timestamp fields).Creating multiple pages in a single request is not supported. You need to send a separate POST request for each page.

    Creating language versions of pages

    You can use POST requests to create new of existing pages:language versions

    Use the culture code in the resource path to set the desired language.Identify the page using the .alias pathSpecify the of the existing page in the request data. Do NOT manually set a for the new languageNodeID DocumentIDversion.Set any other required data for the page language version.

    http://en.wikipedia.org/wiki/XMLhttp://en.wikipedia.org/wiki/JSONhttps://docs.kentico.com/display/K9/Page+typeshttps://docs.kentico.com/display/K9/Editing+the+content+of+multilingual+websiteshttps://docs.kentico.com/display/K9/Setting+page+aliases

  • XML JSON

    URL: ~/rest/content/site/CorporateSite/fr-fr/document/Services

    Data:

    5 FrenchServices

    URL: ~/rest/content/site/CorporateSite/fr-fr/document/Services?format=json

    Data:

    {"NodeID":5,"DocumentName":"French Services"}

    Updating existing pages

    HTTP method: PUT

    Updating page data

    Resource format:

    /content/currentsite//document/ - updates the data of an existing page on the site running on the domain inthe base URL./content/site///document/ - updates the data of an existing page on the specified site.

    Use the to identify the page that you want to update. Updating multiple pages in a single request is not supported. You need toalias pathsend a separate PUT request for each page.

    Update the values of the page's fields using the data of the PUT request. Both and formats are supported for the data.XML JSON

    Examples:

    Updates the name of the page on the sample Corporate siteServices

    XML JSON

    URL: ~/rest/content/site/CorporateSite/en-us/document/Services

    Data:

    ServicesMODIFIED ServicesMODIFIED

    URL: ?fo~/rest/content/site/CorporateSite/en-us/document/Servicesrmat=json

    Data:

    {"DocumentName":"Services MODIFIED","MenuItemName":"Services MODIFIED"}

    Updates the title, release date and summary of a news article on the sample Corporate site

    XML JSON

    Updating page names

    Many have a unique field that serves as the source for the page name (instead of the default field).page types DocumentNameWhen updating the names of such page types, always set the new value for both the field and the dedicatedDocumentNamepage type name field to ensure consistency.

    https://docs.kentico.com/display/K9/Setting+page+aliaseshttp://en.wikipedia.org/wiki/XMLhttp://en.wikipedia.org/wiki/JSONhttps://docs.kentico.com/display/K9/Page+types

  • URL: ~/rest/content/site/CorporateSite/en-us/document/News/New-Consulting-Services

    Data:

    Consultingavailable Consultingavailable 2014-07-04T00:00:00+02:00 Updatedsummary

    URL: ~/rest/content/site/CorporateSite/en-us/document/News/New-?format=jsonConsulting-Services

    Data:

    {"DocumentName":"Consultingavailable","NewsTitle":"Consulting available","NewsReleaseDate":"2014-07-04T00:00:00Z","NewsSummary":"Updated summary"}

    Workflow actions

    You can also use PUT requests to move pages through the life cycle, or check pages in and out when using .workflow content locking

    Resource format:

    /content/currentsite/// - performs the given workflow action for the specified page on thesite running on the domain in the base URL./content/site//// - performs the given workflow action for the given page onthe specified site.

    Workflow action Description

    publish Publishes the page.

    checkout Performs check-out for the page. The page is checked out underthe user account specified by the REST request's infauthenticationormation.

    checkin Performs check-in for the page.

    archive Archives the page.

    movetonextstep Moves the page to the next workflow step.

    movetopreviousstep Moves the page to the previous workflow step.

    Use the to identify the page for which you want to perform the workflow action. Do not submit any data when sending workflowalias pathaction requests.

    URL example: ~/rest/content/currentsite/en-us/checkout/Home

    Deleting pages

    HTTP method: DELETE

    Resource format:

    /content/currentsite//document/ - deletes the given of the page for the site running on thelanguage versiondomain in the base URL./content/site///document/ - deletes the given language version of the page on the specifiedsite.

    Use the to identify the page that you want to delete. Deleting multiple pages in a single request is not supported. You need to sendalias patha separate DELETE request for each page.

    Page deletion parameters

    When deleting pages via REST, you can append the following query string parameters to the request URL:

    Parameter Value (default bold) Description

    https://docs.kentico.com/display/K9/Configuring+workflowshttps://docs.kentico.com/display/K9/Content+lockinghttps://docs.kentico.com/display/K9/Setting+page+aliaseshttps://docs.kentico.com/display/K9/Editing+the+content+of+multilingual+websiteshttps://docs.kentico.com/display/K9/Setting+page+aliases

  • deleteallcultures true/false Indicates if the request also deletes all langu of the specified page.age versions

    To delete all language versions of a page,append to the?deleteallcultures=truerequest URL.

    destroyhistory true/false Indicates if the request also deletes thepage's .version history

    To delete the version history together withthe page, append to?destroyhistory=truethe request URL.

    Managing objects using RESTTo manage objects in Kentico using the REST service, send requests using the POST, PUT or DELETE to the appropriateHTTP methodURL — append the described below to the of your REST service. resource paths base URL

    The base URL of the REST service is . For example, if your site is running at use /rest ,http://localhost/Kentico http://locas the base URL of the service. alhost/Kentico/rest

    Object resource paths start with an name. To find the value for specific object types, view the of classes in the object type Code name Modu application, or the column of the database table.les ClassName CMS_Class

    Creating objects

    HTTP method: POST

    Resource format:

    / - creates a new object of the specified type.//currentsite - creates a new object of the specified type and assigns it to the website running on the domain in thebase URL.//site/ - creates a new object of the specified type and assigns it to the specified website./customtableitem. - creates a new data record inside the specified . custom table/bizformitem.bizform. - creates a new data record inside the specified .form

    Set the name and other fields of the new object in the data of the POST request. Both and formats are supported for the data.XML JSON

    Examples

    Creates a new user with the Editor privilege level and an empty password. Assigns the user to the site running on the domain inthe base URL.

    XML JSON

    Important: Do NOT use object requests to create, update or delete the pages of Kentico websites. See Managing pages using for information about working with pages.REST

    Important:

    The service automatically sets the system fields of the new object (such as the ID and timestamp fields).Creating multiple objects of the same type in a single request is not supported.You can create child or binding objects along with the primary object. When using the XML format for the data of suchrequests, enclose the data into the element to ensure valid syntax with a single root element.

    https://docs.kentico.com/display/K9/Editing+the+content+of+multilingual+websiteshttps://docs.kentico.com/display/K9/Editing+the+content+of+multilingual+websiteshttps://docs.kentico.com/display/K9/Configuring+and+using+page+versioninghttp://en.wikipedia.org/wiki/HTTP#Request_methodshttps://docs.kentico.com/display/K9/Custom+tableshttps://docs.kentico.com/display/K9/Formshttp://en.wikipedia.org/wiki/XMLhttp://en.wikipedia.org/wiki/JSON

  • URL: ~/rest/cms.user/currentsite

    Data:

    Editor Contenteditor [email protected] true true

    URL: ~/rest/cms.user/currentsite?format=json

    Data:

    {"UserName":"Editor","FullName":"Content editor","Email":"[email protected]","UserEnabled":true,"UserIsEditor":true}

    Creates a new object with a child statecountry

    XML JSON

    URL: ~/rest/cms.country

    Data:

    Newcountry NewCountry Newstate NewState NS

    URL: ~/rest/cms.country?format=json

    Data:

    {"CountryDisplayName":"New country","CountryName":"NewCountry","CMS.State": [{ "StateDisplayName":"New state", "StateName":"NewState", "StateCode":"NS" }]}

    Creates a for the page of the sample Corporate sitepage alias Home

    XML JSON

    URL: ~/rest/cms.documentalias/site/corporatesite

    Data:

    4 /HomeAlias

    URL: ~/rest/ ?format=jsoncms.documentalias/site/corporatesite

    Data:

    {"AliasNodeID":4,"AliasURLPath":"/HomeAlias"}

    Adds a new data record into the custom tableSample table

    XML JSON

    https://docs.kentico.com/display/K9/Setting+page+aliases

  • URL: ~/rest/customtableitem.customtable.sampletable

    Data:

    Record added viaREST

    URL: ?format=json~/rest/customtableitem.customtable.sampletable

    Data:

    {"ItemText":"Record added viaREST"}

    Updating existing objects

    HTTP method: PUT

    Resource format:

    // - updates the object with the specified identifier (primary key ID). // - updates the object with the specified code name. For object types with site bindings, always updatesthe object assigned to the site running on the domain in the base URL.//site// - updates the object with the specified code name or GUID value on thespecified website.//global/ - updates the global object with the specified code name or GUID value./customtableitem./ - updates the data record with the specified identifier (ID or GUIDvalue) inside the given . custom table/bizformitem.bizform./ - updates the data record with the specified identifier (ID or GUIDvalue) inside the given .form

    Update the values of the object's fields using the data of the PUT request. Both and formats are supported for the data. UpdatingXML JSONmultiple objects in a single request is not supported.

    Examples

    Updates the email address of the useradministrator

    XML JSON

    URL: ~/rest/cms.user/administrator

    Data:

    [email protected]

    URL: ~/rest/cms.user/administrator?format=json

    Data:

    {"Email":"[email protected]"}

    Updates a data record of the sample formContact us

    XML JSON

    URL: ~/rest/bizformitem.bizform.contactus/1

    Data:

    [email protected] Updatedmessage

    URL: ?format=json~/rest/bizformitem.bizform.contactus/1

    Data:

    { "Email":"[email protected]", "Message":"Updated message"}

    https://docs.kentico.com/display/K9/Custom+tableshttps://docs.kentico.com/display/K9/Formshttp://en.wikipedia.org/wiki/XMLhttp://en.wikipedia.org/wiki/JSON

  • Deleting objects

    HTTP method: DELETE

    Resource format:

    // - deletes the object with the specified identifier (primary key ID).// - deletes the object with the specified code name. For object types with site bindings, always deletesthe object assigned to the site running on the domain in the base URL.//site// - deletes the object with the specified code name or GUID value from thespecified website.//global/ - deletes the global object with the specified code name or GUID value./customtableitem./ - deletes the data record with the specified identifier (ID or GUIDvalue) from the given .custom table/bizformitem.bizform./ - deletes the data record the specified identifier (ID or GUID value)from the given .form

    URL examples:

    ~/rest/cms.user/53~/rest/cms.country/usa ~/rest/cms.emailtemplate/site/corporatesite/Blog.NotificationToModerators~/rest/customtableitem.customtable.SampleTable/5

    Deleting multiple objects in a single request is not supported. You need to send a separate DELETE request for each object.

    Sending REST requests from codeBy sending requests to the , you can from the system or .Kentico REST service get data manipulate pages and objects

    The following example demonstrates how to send REST requests using server-side code. The sample code is incomplete — you need toperform the following according to your requirements:

    integrate the request sending into your custom logic or applicationsupply the required values (HTTP method, request URL and data)process the response dataensure exception handling

    https://docs.kentico.com/display/K9/Custom+tableshttps://docs.kentico.com/display/K9/Forms

  • using System;using System.Web;using System.Net;using System.IO;using System.Text;

    ...

    string httpMethod; // "GET", "POST", "PUT" or "DELETE"string requestUrl; // The URL of the REST request (base URL + resource path)string requestData; // Data for POST or PUT requests

    string responseDescription; // Stores the description of the response statusstring responseData; // Stores data retrieved by the request

    // Creates the REST requestHttpWebRequest request = (HttpWebRequest)WebRequest.Create(requestUrl);

    // Sets the HTTP method of the requestrequest.Method = httpMethod;

    // Authorizes the request using Basic authenticationrequest.Headers.Add("Authorization: Basic YWRtaW5pc3RyYXRvcjo=");

    // Submits data for POST or PUT requestsif (request.Method == "POST" || request.Method == "PUT"){ request.ContentType = "text/xml";

    Byte[] bytes = Encoding.GetEncoding("utf-8").GetBytes(requestData); request.ContentLength = bytes.Length;

    using (Stream writeStream = request.GetRequestStream()) { writeStream.Write(bytes, 0, bytes.Length); }}

    // Gets the REST responseHttpWebResponse response = (HttpWebResponse)request.GetResponse();

    // Stores the description of the response statusresponseDescription = (Int32)response.StatusCode + " - " +response.StatusDescription;

    // Gets the response datausing (Stream responseStream = response.GetResponseStream()){ if (responseStream != null) using (StreamReader reader = new StreamReader(responseStream)) { responseData = HttpUtility.HtmlEncode(reader.ReadToEnd()); }}

    ...

    C# example

  • Using the integration busThe integration bus allows developers to connect Kentico with third party systems, such as CRMs or ERPs. The purpose of the integration isto synchronize objects and pages (in both directions). The data exchange is ensured by . Each connector is a standard .NETconnectorsclass that needs to be implemented by a developer.

    Information

    Connecting Kentico with third party systems:

    Integration bus overviewThe integration bus synchronizes objects and pages with third party systems. It provides a safer and more reliable way than other solutions,because the synchronization tasks can be ordered in a queue and recovered if they fail. You can implement the synchronization in bothdirections:

    Outgoing tasks – perform synchronization from Kentico to external applications.Incoming tasks – perform synchronization from external systems to Kentico.

    Outgoing tasks - From Kentico to external applications

    Outgoing synchronization tasks are based on .subscriptions

    Subscriptions

    Subscriptions keep track of operations performed in Kentico, such as creating, updating or deleting objects and pages. Developers need toprepare subscriptions for operations that should be synchronized to external systems. When an operation that has a subscription occurs, thesystem passes the request to a connector, which processes the synchronization in one of two modes (depends on the subscription settings):

    Asynchronously – the synchronization task is placed into a queue, where it waits until the task's processing is started by a scheduledtask or by a user manually.Synchronously – the synchronization task is passed directly to the connector.

    Integration bus overview - learn about the options the integration bus offers.

    Managing integration tasks - see how to manage the synchronization tasks used by the integration bus.

    Example - Integration connector - inspect a sample integration connector.

    Reference - Integration bus data types - refer to this page whenever you need more information about the classes, interfaces andenumerations related to the integration bus.

    Integration bus database model - a reference page about the integration bus data model.

    1. 2. 3. 4.

    Enable the integration bus featuresCreate integration connectorsImplement outgoing synchronizationImplement incoming synchronization

  • Data types for subscriptions

    Subscriptions use one of three data types to specify which data is transferred:

    Simple - this type synchronizes the content of objects.SimpleSnapshot - this type synchronizes whole objects and preserves foreign key bindings. This applies only when the 3rd partysystem has an architecture and database design similar to Kentico.Snapshot - synchronizes multiple objects at once. For example a main object with its children, such as polls together with pollanswers. Not supported for pages.

    For details, refer to the enumeration.TaskDataTypeEnum

    Asynchronous processing

    With asynchronous processing of tasks, the data of the changed object or page is first stored in the database (the task is logged in the taskqueue). If the external system is not available, the tasks wait ordered in the queue until they can be reliably processed.

    The of asynchronous processing: advantages

    Synchronization data is not lost even if the processing of tasks fails.Asynchronous processing is highly scalable, all timeconsuming operations are performed one by one.Allows translation of column values using the method.TranslateColumnsToExternal()

    The of asynchronous processing: disadvantages

    No context is available during the object/page processing.

    Otherwise, asynchronous processing does not have any major disadvantages, and can be used for most scenarios.

    To ensure maximum performance, the system postpones the logging and processing of tasks until the event.EndRequest

    https://docs.kentico.com/display/K9/Reference+-+Integration+bus+data+types#Reference-Integrationbusdatatypes-TaskDataTypeEnumhttp://msdn.microsoft.com/en-us/library/system.web.httpapplication.endrequest.aspx

  • When the processing thread starts, the connector begins by fetching the first task in the queue (FIFO principle). Fetched tasks aretransformed to strongly typed objects and passed to the methods implemented in the connector class. In some cases, additional methods arecalled, for example when performing translation of foreign keys. When the task is processed, the result value (of type IntegrationProcessRes

    ) is returned to notify the connector. Depending on the result, the connector decides what to do next.ultEnum

    Note: Processing doesn’t start on when the object or page has been changed in an asynchronous thread (forEndRequestexample when importing new sites with the option enabled).Log integration tasks

    https://docs.kentico.com/display/K9/Reference+-+Integration+bus+data+types#Reference-Integrationbusdatatypes-IntegrationProcessResultEnumhttps://docs.kentico.com/display/K9/Reference+-+Integration+bus+data+types#Reference-Integrationbusdatatypes-IntegrationProcessResultEnum

  • Synchronous processing

    When using synchronous processing, the changed object is passed directly to the connector for further processing.

    The of synchronous processing include:advantages

    You can manipulate objects within the context of Kentico – you can access properties like or of the currentlyParent Childrenprocessed object, and the data is fetched from the database just in time.With pages, you can access properties like , and .Tags Categories Attachments

    The of synchronous processing include:disadvantages

    The system does not store the synchronization data in the database – if an error occurs and the connector fails to process therequest, the data is lost.Synchronous processing of large or numerous tasks may slow down the application.No method.TranslateConlumnsToExternal()

    It is recommended to use synchronous processing only if you need to leverage the advantages.

    Note: The is already implemented. You only need to prepare the parts of the code shown in theBaseIntegrationConnectorinherited connector class ( in the figure above).CustomIntegrationConnector

  • Processing of synchronous tasks starts immediately after an object or page matching a subscription is changed. Unlike asynchronousprocessing, where the logging and processing is postponed until the application reaches , synchronous processing sends theEndRequestdata instantly to the subscribed connectors.

    Incoming tasks - From external applications to Kentico

    The inbound direction allows you to transfer changes from external applications to Kentico by sending data to the Integration bus. Thesystem stores the data in a queue, later takes it from the queue, and processes it on a regular basis or on your request. Processing ofincoming tasks is .always asynchronous

    http://msdn.microsoft.com/en-us/library/system.web.httpapplication.endrequest.aspx

  • 1. 2.

    Your task as a developer is to implement methods that help the system log the correct data into the queue. You need to convert the externalobject to a corresponding internal object or page, and supply translation information if you want to preserve foreign key bindings:

    There are two ways to implement the communication between Kentico and your external system:

    Implement a serviceCall the Kentico API (requires references to Kentico DLLs)

    Implementing a service

    The communication is ensured by a custom service (Web API, WCF, etc.) that you need to implement within the Kentico application. Theservice then calls the Kentico API, which uses a connector to convert external objects to Kentico objects.

    The advantage is that your external application does not need to reference Kentico libraries (DLLs).

    Calling the Kentico API

    Your external application needs to reference the libraries (DLLs) of the Kentico application and have a connection to the Kentico database.See to learn how to set up this scenario.Using the Kentico API externally

    You can then call the API (ProcessExternalTask method) within your application's code, which performs the following tasks:

    Converts external objects to Kentico objects using a connector defined within the Kentico application.Logs the synchronization data (integration tasks) directly into the connected Kentico database.

  • The advantage is that even if the Kentico application is not accessible for some reason, the synchronization data is logged to the queue andcan be reliably processed later without loss of data.

    Enabling the integration busTo enable the , open the application in the Kentico administration interface and adjust the settings in the Integration bus Settings Integration

    category.-> Integration bus

    Setting Description

    Enable system integration bus Allows logging and processing of incoming and outgoing integrationtasks.

    Integration tasks represent individual synchronization operations forobjects or pages (create, update, delete etc.). The synchronizationprocess consists of two steps:

    Logging - creation of integration tasks for actions that requiresynchronization.Processing - execution of the integration tasks.

    You can enable or disable logging/processing of incoming/outgoingtasks separately through the other settings in the category.

    Enable logging of incoming tasks Indicates if the integration bus logs integration tasks received fromexternal systems. To log tasks, the Enable system integration

    setting must also be enabled.bus

    Enable processing of incoming tasks Check to allow processing of integration tasks incoming fromexternal systems. To process tasks, the Enable system

    setting must also be enabled.integration bus

    Enable logging of outgoing tasks Indicates if the integration bus logs changes made to pages andobjects in Kentico as outgoing integration tasks. To log tasks, the E

    setting must also be enabled.nable system integration bus

    Enable processing of outgoing tasks Check to allow processing of outgoing integration tasks. To processtasks, the setting must also beEnable system integration busenabled.

    All sites in the system share the same settings for the integration bus. You need to select the option in the selector to(global) Siteconfigure the settings.

  • 1. 2. 3. 4.

    Creating integration connectorsYou can add integration connector classes into your application in two ways:

    In the App_Code directoryIn a separate project or assembly

    Creating connectors in the App_Code folder

    Open your Kentico web project in Visual Studio.Create a new class in the folder (or if you installed Kentico as a web application project).App_Code Old_App_CodeSet the class to inherit from BaseIntegrationConnector.Override the method and set the property within this method.Init() ConnectorName

    The value of the property must match the code name of the connector object registered in theConnectorNameadministration interface.

    using CMS.Synchronization;using CMS.SynchronizationEngine;

    public class CMSIntegrationConnector : BaseIntegrationConnector{ /// /// Initializes the connector name. /// public override void Init() { // Initializes the connector name (must match the code name of theconnector object in the system) // GetType().Name uses the name of the class as the ConnectorName ConnectorName = GetType().Name; }}

  • 5.

    6.

    1. 2.

    3. a. b. c.

    4. 5. 6.

    1. 2. 3. 4.

    Ensure that the system loads the appropriate class when working with the connector using the assemblyRegisterCustomClassattribute. See for more information.Loading custom classes from App_Code

    using CMS;

    [assembly: RegisterCustomClass("CMSIntegrationConnector",typeof(CMSIntegrationConnector))]

    On web application projects, build the solution.

    With the connector class prepared, you now need to:

    Implement and/or synchronizationoutgoing incomingRegister the connector in the system

    You can find an example of a basic connector class on the page.Example - Integration connector

    Creating connectors in a separate project or assembly

    Open your Kentico web project in Visual Studio (using the or file).WebSite.sln WebApp.slnAdd a new project to the solution (name it e.g. ).Class Library CustomIntegrationConnector

    This ensures that the connector has its own DLL assembly.Add references to the project:

    Right-click the project and select Add reference...Click Browse...Add at least the following references from the project's directory:Lib

    CMS.SynchronizationCMS.SynchronizationEngineCMS.DocumentEngineCMS.HelpersCMS.DataEngineCMS.SiteProviderCMS.WorkflowEngineCMS.Base

    Edit and rename the default class in the project and set the class to inherit from BaseIntegrationConnector.Override the method and set the property within this method.Init() ConnectorNameBuild the solution.

    With the connector class prepared, you now need to:

    Implement and/or synchronizationoutgoing incomingRegister the connector in the system

    Registering connectors in the system

    Once the connector's class is ready, you need to register the connector as an object in the system:

    In the Kentico administration interface, open the application.Integration busSelect the tab.ConnectorsClick .New connectorFill in the , and and select the check box.Display name Assembly name Class Enabled

    Property Description

    Display name The name of the connector displayed in the user interface.

    Code name Sets a unique identifier for the connector. Must match the valueof the property declared in the connector'sConnectorNameclass.

    Provider class_____________

    Specifies the class where the connector class is implemented:

    Assembly name - the assembly (project) containing theconnector class. Select for connectors(custom classes)implemented in the App_Code (or Old_App_Code) folder.Class - the exact class (including any namespaces) thatdefines the functionality of the connector. For App_Codeclasses, the value must match the first parameter of the Re

    attribute that loads the class.gisterCustomClass

    https://docs.kentico.com/display/K9/Loading+custom+classes+from+App_Code

  • 4.

    5.

    1.

    2.

    3.

    Enabled Indicates if the connector logs and processes integration tasks.Logging and processing of tasks must also be in enabled Settin

    .gs -> Integration -> Integration bus

    Click .Save

    The system displays a warning icon ( ) next to connectors that are not registered correctly. The most common causes of problems are:

    The value of the property in the connector class's method does not match the .ConnectorName Init Code nameIncorrect assembly or class name.App_Code classes are not loaded correctly. See for more information.Loading custom classes from App_Code

    Implementing outgoing synchronizationTo synchronize data from Kentico to external applications, you need to decide:

    which and you want to synchronizeobjects pages which you want to usedata typewhether you want to use or processing of integration taskssynchronous asynchronous whether you want to handle of foreign key bindingstranslations

    Use this information to implement the outgoing synchronization in your :connector class

    Prepare subscriptions for the Kentico objects that you want to synchronize:Use predefined subscription methods - allows you to easily subscribe to objects or pagesORBuild subscription objects - allows you to select exactly which objects are synchronized

    Implement the method that converts objects or pages to the objects used by the external application.

    (Optional) Implement :translation of foreign key bindingsGetExternalObjectID method - if the synchronized objects or pages have bindings to objects inheriting from BaseInfoGetExternalDocumentID method - if the synchronized objects or pages have bindings to pages ( )TreeNode

    Creating subscriptions

    Subscriptions keep track of actions that occur in Kentico, such as creating, updating or deleting objects and pages. Use subscriptions todetermine the scope of the changes that the connector synchronizes.

    You need to implement subscriptions inside the method of your :Init() connector class

    using CMS.SynchronizationEngine;using CMS.Synchronization;using CMS.DataEngine;

    public class CMSIntegrationConnector : BaseIntegrationConnector{ public override void Init() { // Initializes the connector name ConnectorName = GetType().Name;

    // Register your subscriptions here }}

    Using predefined subscription methods

    You can subscribe to pages or objects by calling the following methods:

    Note: When you add, edit or delete a connector, the system re-initializes all defined connectors.

    You can if you need to define custom options for the subscription scope.create your own subscription class

    https://docs.kentico.com/display/K9/Loading+custom+classes+from+App_Codehttps://docs.kentico.com/display/K9/Reference+-+Integration+bus+data+types#Reference-Integrationbusdatatypes-TaskDataTypeEnumhttps://docs.kentico.com/display/K9/Integration+bus+overview#Integrationbusoverview-Synchronousprocessinghttps://docs.kentico.com/display/K9/Integration+bus+overview#Integrationbusoverview-Asynchronousprocessing

  • 1. 2.

    SubscribeToAllDocumentsSubscribeToDocumentsSubscribeToAllObjectsSubscribeToObjects

    See for information about the method parameters.Reference - Integration bus data types

    Examples:

    // Subscribes to all types of changes made to user objectsSubscribeToObjects(TaskProcessTypeEnum.AsyncSnapshot, UserInfo.OBJECT_TYPE);

    // Subscribes to all types of changes made to all pages on all sitesSubscribeToAllDocuments(TaskProcessTypeEnum.AsyncSimpleSnapshot, TaskTypeEnum.All);

    Building subscription objects

    You can select exactly which objects are synchronized using subscription objects:

    Create a new object of a subscription class.Call the method for the object.SubscribeTo

    Subscription classes inherit from , and you can use the following predefined options:AbstractIntegrationSubscription

    BaseIntegrationSubscriptionObjectIntegrationSubscriptionDocumentIntegrationSubscription

    The subscription classes provide the following :filtering options

    BaseIntegrationSubscription

    ConnectorName - string; assigns the subscription to a connector. Use the property to enter the name of the currentConnectorNameconnector.TaskProcessType - enumeration; specifies the synchronization mode and data type. See for details.TaskProcessTypeEnumTaskType - enumeration; determines the type of the synchronized action (create, update, delete, etc.). See forTaskTypeEnumdetails.SiteName - string; determines the code name of the site where the objects or pages belong. You can use AbstractIntegrationSubscri

    to subscribe only to global objects.ption.GLOBAL_OBJECTS

    ObjectIntegrationSubscription

    ObjectType - string; determines the type (class) of the synchronized object. You can either use the object type code name directly(for example ) or system constants ( ).cms.user UserInfo.OBJECT_TYPEObjectCodeName - string; determines the code name of one specific object, for example: administrator

    DocumentIntegrationSubscription

    https://docs.kentico.com/display/K9/Reference+-+Integration+bus+data+types#Reference-Integrationbusdatatypes-TaskProcessTypeEnumhttps://docs.kentico.com/display/K9/Reference+-+Integration+bus+data+types#Reference-Integrationbusdatatypes-TaskTypeEnum

  • 1.

    2. 3.

    DocumentNodeAliasPath - string; determines the alias path of the synchronized pages, for example: /Products/%DocumentCultureCode - string; determines the culture of the synchronized pages, for example: en-USDocumentClassName - string; determines the of the synchronized pages, for example: page type CMS.MenuItem

    If you do not want to limit the synchronization scope through one of the properties, set the given value to in the subscription object'snullconstructor. For the enumeration, set the value.TaskType All

    Examples:

    // Subscription that synchronizes the creation of object types starting with'poll.poll' - polls and poll answersObjectIntegrationSubscription objSub = newObjectIntegrationSubscription(ConnectorName, TaskProcessTypeEnum.AsyncSnapshot,TaskTypeEnum.CreateObject, "PersonalSite", "poll.poll%", null);SubscribeTo(objSub);

    // Subscription that synchronizes all changes made to pages on 'NewSite', locatedunder the /Home/ path in the content treeDocumentIntegrationSubscription pageSub = newDocumentIntegrationSubscription(ConnectorName,TaskProcessTypeEnum.AsyncSimpleSnapshot, TaskTypeEnum.All, "NewSite", "/Home/%",null, null);SubscribeTo(pageSub);

    // Subscribes to all changes made to the SETTINGS of a specific custom table, where'customtable.SampleTable' is the table's code nameObjectIntegrationSubscription customTableSub = newObjectIntegrationSubscription(ConnectorName,TaskProcessTypeEnum.AsyncSimpleSnapshot, TaskTypeEnum.All, null, null,"customtable.SampleTable");SubscribeTo(customTableSub);

    // Subscribes to all changes made to the DATA of the 'customtable.SampleTable'custom tableObjectIntegrationSubscription customTableDataSub = newObjectIntegrationSubscription(ConnectorName,TaskProcessTypeEnum.AsyncSimpleSnapshot, TaskTypeEnum.All, null,CustomTableItemProvider.GetObjectType("customtable.SampleTable"), null);SubscribeTo(customTableDataSub);

    Creating custom subscription classes

    If you need to extend the filtering options of a connector's subscriptions, you can create your own subscription class:

    Create a new class inheriting from one of the existing .subscription classesIf you wish to create a completely custom subscription class, we recommend inheriting from AbstractIntegrationSubscripti

    .onIf you only wish to add custom filtering for objects or pages, inherit from or ObjectIntegrationSubscription DocumentInteg

    .rationSubscription

    Define any properties and constructors that you need for the custom logic of your subscription class.Override the method:IsMatch()

    Wildcard character %