Magento 1.x Software Support Notice

For Magento Commerce 1, Magento is providing software support through June 2020. Depending on your Magento Commerce 1 version, software support may include both quality fixes and security patches. Please review our Magento Software Lifecycle Policy to see how your version of Magento Commerce 1 is supported.

For Magento Open Source 1.5 to 1.9, Magento is providing software security patches through June 2020 to ensure those sites remain secure and compliant. Visit our information page for more details about our software maintenance policy and other considerations for your business.

Account Update

Edit this page on GitHub

Module: GiftCard API

Resource: giftcard_account


Allows you to update the required gift card account.


Type Name Description
string sessionId Session ID
string giftcardAccountId Gift card account ID
array giftcardData Array of giftcardAccountEntityToUpdate


Type Description
boolean True is the gift card account is updated

The giftcardAccountEntityToUpdate content is as follows:

Type Name Description
boolean is_active
Defines whether the gift card account is active
boolean is_redeemable
Defines whether the gift card account is redeemable
int store_id
Store view ID
double balance
Gift card account initial balance
string date_expires
Expiration date in the YYYY-MM-DD format


Fault Code Fault Message
102 Unable to save data.


Request Example SOAP V1
$proxy = new SoapClient('http://magentohost/api/soap/?wsdl');
$sessionId = $proxy->login('apiUser', 'apiKey');

$giftcardId = 1;
$giftcardToUpdate = array(
    "balance" => 700

$result = $proxy->call(
Request Example SOAP V2
$proxy = new SoapClient('http://magentohost/api/v2_soap/?wsdl'); 

$sessionId = $proxy->login('apiUser', 'apiKey'); 
$result = $proxy->giftcardAccountUpdate($sessionId, '3', array(
'date_expires' => null, 
'store_id' => '2', 
'balance' => '700', 
'is_active' => TRUE, 
'is_redeemable' => TRUE));   

Request Example SOAP V2 (WS-I Compliance Mode)
$proxy = new SoapClient('http://magentohost/api/v2_soap/?wsdl'); 

$sessionId = $proxy->login((object)array('username' => 'apiUser', 'apiKey' => 'apiKey')); 
$result = $proxy->giftcardAccountUpdate((object)array('sessionId' => $sessionId->result, 'giftcardAccountId' => '3', 'giftcardData' => array(
'balance' => '700',
'is_active' => TRUE,
'is_redeemable' => TRUE,
'store_id' => '2',
'date_expires' => null)));