Esempio n. 1
0
/**
 * Civixero.ContactPush API.
 *
 * @param array $params
 *
 * @return array
 *   API result descriptor.
 *
 * @see civicrm_api3_create_success
 * @see civicrm_api3_create_error
 * @throws API_Exception
 */
function civicrm_api3_civixero_contactpush($params)
{
    $xero = new CRM_Civixero_Contact($params);
    $xero->push($params);
    return civicrm_api3_create_success($params, $params);
}
Esempio n. 2
0
/**
 * Civixero.ContactPull API.
 *
 * @param array $params
 *
 * @return array
 *   API result descriptor
 * @see civicrm_api3_create_success
 * @see civicrm_api3_create_error
 * @throws API_Exception
 */
function civicrm_api3_civixero_contactpull($params)
{
    $xero = new CRM_Civixero_Contact($params);
    $xero->pull($params);
    return civicrm_api3_create_success(1, $params, 'Civixero', 'contactpull');
}