Search code examples
javagoogle-checkout

Managing inventory with off site payment systems


I am building a site that sells tickets. I am processing payments through third party payment processors, google checkout. Currently I am limiting purchase time on google checkout to 10 min. If they take longer, the tickets reopen and other users are able to purchase the tickets. The only problem is that Google checkout doesn't know that the timer has expired. The user is able to complete their purchase even though the tickets they are trying to buy have already been bought by someone else. Is there any way to stop google checkout from selling too many tickets? The tickets are GA so if I could limit how many are sold total this would work also. If this is not possible, which seems to be the case, has anyone tackled this problem and found a better solution?


Solution

  • You have several options to deal with inventory issues:

    • Checkout Store Gadget: offers a simple built-in "inventory update" (using an online spreadsheet). Because Google handles the inventory, an order will not go through if the inventory dropped to zero. Here's the link to the Store Gadget documentation:

    http://code.google.com/apis/checkout/developer/Google_Checkout_Store_Gadget_How_To.html

    • If you don't want to use the Store Gadget, you can use the Checkout Notification and Order Processing APIs and cancel the order if it took to long to complete (i.e. the ticket was sold to someone else). This avoids overselling but will make some customers unhappy.

    http://code.google.com/apis/checkout/developer/Google_Checkout_XML_API_Notification_API.html

    http://code.google.com/apis/checkout/developer/Google_Checkout_XML_API_Processing.html

    • Use an inventory buffer to avoid overselling. Keep a few tickets in "reserve" and avoid cancelations and unhappy customers :-)