{"id":7441,"date":"2021-05-15T16:45:21","date_gmt":"2021-05-15T16:45:21","guid":{"rendered":"https:\/\/docs.campaignsuite.nl\/docs\/developers\/client-connections\/mautic\/"},"modified":"2021-05-15T16:51:55","modified_gmt":"2021-05-15T16:51:55","slug":"mautic","status":"publish","type":"docs","link":"https:\/\/docs.campaignsuite.nl\/en\/docs\/developers\/client-connections\/mautic\/","title":{"rendered":"Mautic"},"content":{"rendered":"\t\t<div data-elementor-type=\"wp-post\" data-elementor-id=\"7441\" class=\"elementor elementor-7441\">\n\t\t\t\t\t\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-3849d51 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"3849d51\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-8eca7c8\" data-id=\"8eca7c8\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-element elementor-element-c9eda50 elementor-widget elementor-widget-text-editor\" data-id=\"c9eda50\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<h4> getForms <\/h4>\nFunction to retrieve all Mautic forms. When $id is passed, only one form is returned.\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-21135ad elementor-widget elementor-widget-docly_code_syntax_highlighter\" data-id=\"21135ad\" data-element_type=\"widget\" data-widget_type=\"docly_code_syntax_highlighter.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t                    <div class=\"docly-source-code prism\" data-lng-type=\"php\">\r\n\t\t\t<pre>\r\n\t\t\t\t<code class=\"language-php\">\r\n\t\t\t\t\t\/**\n   * Function to retrieve all Mautic forms. When $id is passed, only one form is returned\n   *\n   * @param $id int Id of a Mautic form\n   * @return array $forms Returns an array of Mautic forms\n   *\/\n  public function getForms($id = &#039;&#039;){}\t\t\t\t<\/code>\r\n\t\t\t<\/pre>\r\n            <\/div>\r\n                \t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-8031737 elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"8031737\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-2f44b81\" data-id=\"2f44b81\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-element elementor-element-69e0c0b elementor-widget elementor-widget-text-editor\" data-id=\"69e0c0b\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div>\n<h4> createForm <\/h4>\nThis function will create a new Mautic form from a Gravity Forms form and its fields.\n\n<\/div>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-e0dc2a1 elementor-widget elementor-widget-docly_code_syntax_highlighter\" data-id=\"e0dc2a1\" data-element_type=\"widget\" data-widget_type=\"docly_code_syntax_highlighter.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t                    <div class=\"docly-source-code prism\" data-lng-type=\"php\">\r\n\t\t\t<pre>\r\n\t\t\t\t<code class=\"language-php\">\r\n\t\t\t\t\t\/**\n   * @param $type string Type can be Campaign or Standalone\n   * @param $form array The gravity Forms form as an array\n   *\/\n  public function createForm($type, $form){}\t\t\t\t<\/code>\r\n\t\t\t<\/pre>\r\n            <\/div>\r\n                \t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-2a2522e elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"2a2522e\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-ee712de\" data-id=\"ee712de\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-element elementor-element-30e8881 elementor-widget elementor-widget-text-editor\" data-id=\"30e8881\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div>\n<h4> postFormEntry <\/h4>\nThis function sends a wp_remote_post () request directly to Mautic. This is necessary because Mautic needs the visitor&#8217;s IP address to identify the contact.\n\n<\/div>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-f30285a elementor-widget elementor-widget-docly_code_syntax_highlighter\" data-id=\"f30285a\" data-element_type=\"widget\" data-widget_type=\"docly_code_syntax_highlighter.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t                    <div class=\"docly-source-code prism\" data-lng-type=\"php\">\r\n\t\t\t<pre>\r\n\t\t\t\t<code class=\"language-php\">\r\n\t\t\t\t\t\/**\n   * @param $form_id int Id of the Mautic form\n   * @param $data array Array of the data to post to the form\n   *\/\n  public function postFormEntry($form_id, $data){}\t\t\t\t<\/code>\r\n\t\t\t<\/pre>\r\n            <\/div>\r\n                \t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t<section class=\"elementor-section elementor-top-section elementor-element elementor-element-2dc266f elementor-section-boxed elementor-section-height-default elementor-section-height-default\" data-id=\"2dc266f\" data-element_type=\"section\">\n\t\t\t\t\t\t<div class=\"elementor-container elementor-column-gap-default\">\n\t\t\t\t\t<div class=\"elementor-column elementor-col-100 elementor-top-column elementor-element elementor-element-cd363bd\" data-id=\"cd363bd\" data-element_type=\"column\">\n\t\t\t<div class=\"elementor-widget-wrap elementor-element-populated\">\n\t\t\t\t\t\t\t\t<div class=\"elementor-element elementor-element-09c9a1a elementor-widget elementor-widget-text-editor\" data-id=\"09c9a1a\" data-element_type=\"widget\" data-widget_type=\"text-editor.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t\t\t\t\t<div>\n<h4> updateEntry <\/h4>\n<div> This feature updates a Mautic form submission based on certain conditions. <\/div>\n<\/div>\t\t\t\t\t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t<div class=\"elementor-element elementor-element-95ecde1 elementor-widget elementor-widget-docly_code_syntax_highlighter\" data-id=\"95ecde1\" data-element_type=\"widget\" data-widget_type=\"docly_code_syntax_highlighter.default\">\n\t\t\t\t<div class=\"elementor-widget-container\">\n\t\t\t                    <div class=\"docly-source-code prism\" data-lng-type=\"php\">\r\n\t\t\t<pre>\r\n\t\t\t\t<code class=\"language-php\">\r\n\t\t\t\t\t\/**\n   * @param int $mautic_form_id The Mautic form ID\n   * @param array $where Array of conditions\n   * @param array $updates Array of fields to update\n   *\/\n  function updateEntry($mautic_form_id, $where, $updates){}\t\t\t\t<\/code>\r\n\t\t\t<\/pre>\r\n            <\/div>\r\n                \t\t<\/div>\n\t\t\t\t<\/div>\n\t\t\t\t\t<\/div>\n\t\t<\/div>\n\t\t\t\t\t\t\t<\/div>\n\t\t<\/section>\n\t\t\t\t\t\t\t<\/div>\n\t\t","protected":false},"excerpt":{"rendered":"<p>getForms Function to retrieve all Mautic forms. When $id is passed, only one form is returned. \/** * Function to retrieve all Mautic forms. When $id is passed, only one form is returned * * @param $id int Id of a Mautic form * @return array $forms Returns an array of Mautic forms *\/ public [&hellip;]<\/p>\n","protected":false},"author":1,"featured_media":0,"parent":7409,"menu_order":1,"comment_status":"open","ping_status":"closed","template":"","doc_tag":[],"class_list":["post-7441","docs","type-docs","status-publish","hentry","no-post-thumbnail"],"acf":[],"_links":{"self":[{"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/docs\/7441","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/docs"}],"about":[{"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/types\/docs"}],"author":[{"embeddable":true,"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/comments?post=7441"}],"version-history":[{"count":3,"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/docs\/7441\/revisions"}],"predecessor-version":[{"id":7447,"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/docs\/7441\/revisions\/7447"}],"up":[{"embeddable":true,"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/docs\/7409"}],"wp:attachment":[{"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/media?parent=7441"}],"wp:term":[{"taxonomy":"doc_tag","embeddable":true,"href":"https:\/\/docs.campaignsuite.nl\/en\/wp-json\/wp\/v2\/doc_tag?post=7441"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}