Notes on NetSuite’s Gift Certificate Record

The gift certificate functionality in NetSuite is much more limited than other functionality in NetSuite. It’s also the only option for implementing store credit, electronic, and physical gift cards in NetSuite. If you need to integrate with the gift certificate system in NetSuite, here are some notes to help you along the way:

  • Gift certificates are not created directly. They are are created by creating a “Gift Certificate Item” and using that item in a SalesOrder.
  • Gift certificates can be created without an associated posting transaction (Sales Order) by importing a CSV. However, you cannot create a standalone gift certificate via SuiteTalk. You must create a posting transaction (Invoice/CashSale) with a gift certificate item in order to create a gift certificate via SuiteTalk.
  • Technically, a non-posting transaction (Sales Order) will create a gift certificate record. However, the gift certificate cannot be used until it is associated with a posting transaction.
  • The “Amount Remaining” field is nil if the gift card has been created by a non-posting transaction by has not been filled/purchased. In other words, if amount remaining is nil the user should not be able to use this gift card on an ecommerce site.
  • Gift certificate codes can be a maximum of 9 characters. It’s important that external systems respect this limit if NetSuite is not the system-of-origin for gift card codes.
  • The gift certificate code can be blank. It’s hard to tell exactly how this can occur because there is no system log, but I believe it occurs when gift certificates are imported.
  • There is a custom field list advances search option for gift certificates, but strangely enough custom fields cannot be added to the gift certificate item.
  • The system log is not available for a gift certificate item
  • The last modified date is not shown in the UI
  • You cannot search gift certificates by the last modified date, although it is available in the SuiteTalk response.
  • The last modified date is not updated when a gift card is used. The best way to search for updated gift cards is using a transaction search.
  • A gift certificate is not tied to a specific customer, although in some areas of the UI it does seem as though
  • The gift certificate record does not contain a reference to the customer that purchased or used the gift card. You must search for transactions associated with the gift certificate, then pull a customer reference from the associated transaction.
  • Use the transaction search’s giftCertificate field to retrieve all transactions that are connected with the gift certificate. Note that this includes the non-posting transaction that may have created the gift certificate record, along with any other transactions that have effected the gift card balance over time. You’ll need to filter out the exact transactions you are looking for.`
  • If you need to automatically generate codes that play nicely with other systems (3PL, ecommerce, etc) the best approach is create a before save via SuiteScript to call out to an external service that coordinates gift card code generation.
  • NetSuite does provide the option to generate gift certificate codes for you. However, if you have other systems (such as an eCommerce platform), you won’t be able to push gift certificates into NetSuite using the externally generated code if this option is enabled.
  • If a transaction’s line item contains the giftCertCode field, then the line item is a GiftCertificateItem.
  • If a transaction’s header-level giftCertApplied field is less than zero, then a gift certificate was used as part of the payment.
  • If you search for transactions with giftCertificate not empty ItemFulfillments will be returned in the results, although there is no reference to a gift certificate record on that transaction.
  • A gift card notification email will be sent to the email in the “To” field. There is no way to disable this feature.

Example Gift Card Transaction Search

Here’s an example transaction search using the NetSuite ruby bindings for any transactions that use a gift card:
  basic: [
      field: 'giftCertificate',
      operator: 'notEmpty'

Note that not just SalesOrders are returned. Any transaction associated with a gift certificate is returned in this search. To restrict to a specific transaction type, using a type = _salesOrder search criteria.

Enhancements Requested

I requested enhancements for the more critical gift card limitations I found through SuiteIdeas (vote on them if you can!):