Create an account by REST API without sending user assigned notification

Hello

There is something equivalent to the php version of $bean->save(false); to avoid user email notificacion by API REST Calls?

Or some variable flag on the json of rest/v10/Accounts POST?

Something like the last part of this fake json example

{

   "id":123,

   "name":google,

   "sic":goo,

   "address_city":"fake street 123th",

   "send_user_notification":false,

}

Parents
  • Hi, 

    if You don`t want to create custom bean You can alsow create custom ApiHelper and override  function checkNotify. 

    Create file custom/modules/Accounts/AccountsApiHelper.php 

    and ther something like 

    class AccountsApiHelper extends SugarBeanApiHelper { // data/SugarBeanApiHelper.php

    public function checkNotify($bean){ 

    return false;

    }

    check files:

    include/api/SugarApi.php:  saveBean 

    include/api/ApiHelper.php:  getHelper

    data/SugarBeanApiHelper.php : checkNotify

Reply
  • Hi, 

    if You don`t want to create custom bean You can alsow create custom ApiHelper and override  function checkNotify. 

    Create file custom/modules/Accounts/AccountsApiHelper.php 

    and ther something like 

    class AccountsApiHelper extends SugarBeanApiHelper { // data/SugarBeanApiHelper.php

    public function checkNotify($bean){ 

    return false;

    }

    check files:

    include/api/SugarApi.php:  saveBean 

    include/api/ApiHelper.php:  getHelper

    data/SugarBeanApiHelper.php : checkNotify

Children
No Data