Gift Certificate

A gift certificate record is created when a customer purchases a gift certificate item. For example, you might create a gift certificate item and make it available for purchase. A customer can then buy this gift certificate item. When the customer buys the gift certificate item and names a recipient, the system creates a gift certificate, which can be redeemed for goods and services sold by your business. The gift certificate includes properties such as an expiration date, a remaining value, and the email address of the gift certificate’s recipient.

The gift certificate record is defined in the listAcct (accounting) XSD, where it is called giftCertificate.

To view existing gift certificate instances in the UI, go to Lists > Accounting > Gift Certificates.

For details about working with gift certificate items in the UI, see Viewing and Editing Gift Certificate Status. For full details about the gift certificate feature, see Gift Certificates.

The gift certificate item record is also supported in SOAP web services. For details, see Gift Certificate Item.

Supported Operations

The following operations can be used with the gift certificate record:

get | getList | getSavedSearch | search | searchMoreWithId | update | updateList

Note:

You can also use the asynchronous equivalents of SOAP web services list operations. For information about asynchronous operations, see SOAP Web Services Asynchronous Operations. For more information about request processing, see Synchronous Versus Asynchronous Request Processing.

Note that when using the update operation, only the following fields can be updated:

Gift Certificate Field Definitions

This record does not support external ID.

For full details on all body fields, sublist fields, search filters, and search joins available to this record, see the SOAP Schema Browser’s gift certificate reference page.

Note:

For information on using the SOAP Schema Browser, see SOAP Schema Browser.

Code Sample

The following example show how to update a gift certificate instance’s with new values for the recipient, name, message, and expirationDate fields.

C#

          private void updateGiftCertificate()
{
   GiftCertificate myGiftCertificate = new GiftCertificate();
   myGiftCertificate.internalId = "13";
   myGiftCertificate.email = "john@smith.com";
   myGiftCertificate.name = "John";
   myGiftCertificate.message = "Happy Birthday!";
          
   DateTime nextYear = new DateTime(2016, 1, 1);
   myGiftCertificate.expirationDate = nextYear;
   myGiftCertificate.expirationDateSpecified = true;
        
   _service.update(myGiftCertificate);

} 

        

SOAP Request

          <soap:Body>
   <update xmlns="urn:messages_2017_1.platform.webservices.netsuite.com">
      <record internalId="13" xsi:type="q1:GiftCertificate" xmlns:q1="urn:accounting_2017_1.lists.webservices.netsuite.com">
         <q1:name>John</q1:name>
         <q1:email>john@smith.com</q1:email>
         <q1:message>Happy Birthday!</q1:message>
         <q1:expirationDate>2016-01-01T00:00:00</q1:expirationDate>
      </record>
   </update>
</soap:Body> 

        

SOAP Response:

          <soapenv:Body>
   <updateResponse xmlns="urn:messages_2017_1.platform.webservices.netsuite.com">
      <writeResponse>
         <platformCore:status isSuccess="true" xmlns:platformCore="urn:core_2017_1.platform.webservices.netsuite.com"/>
         <baseRef xsi:type="platformCore:RecordRef" type="giftCertificate" internalId="13" xmlns:platformCore="urn:core_2017_1.platform.webservices.netsuite.com"/>
      </writeResponse>
   </updateResponse>
</soapenv:Body> 

        

Related Topics

Lists
Other Lists
How to Use the SOAP Web Services Records Help
SOAP Web Services Supported Records
SOAP Schema Browser
SuiteTalk SOAP Web Services Platform Overview

General Notices