Square Test Card: Sandbox Payment Testing Guide

Our Cards

Choose from any of our gift cards to give to your loved ones

giftcardimage

Where to Use?

Redeem your gift cards at any of our Merchants

Where to Buy?

You can purchase a gift card from any of these locations

ABOUT US

about

What is ONYX GiftCards?

Onyx Gift Cards is a Grenadian company designed to introduce, market and manage gift cards systems in Grenada for retailers and corporations. We are enthusiastic about the effect and influence we will have on the local market. We intend to expand our systems regionally with a range of product offerings and services.

What is a Gift Card?

Gift cards are the preferred way of giving and receiving gifts. They carry a monetary value that can be redeemed for gifts at your favorite store.
Onyx GiftCards are “Open Gift Cards” which means that they can be redeemed at multiple merchant locations. They are standard credit card size, can fit into the average wallet and made of PVC plastic. Onyx GiftCards are Barcoded for security and safety for the consumer and bear a disclaimer at the back.
Onyx Giftcards can be bought with a branded Card backer which is black in colour and is designed to fit the card. There is an area to write a brief message to the recipient as well.

How it Works?

  • Buy an Onyx Gift Card at these local stores
  • Give your gift card to friends, family, co-workers, etc.
  • The recipient can shop at our select merchants nationwide
  • Your friends, family, co-workers, etc. will present their gift card at checkout to pay for your item(s)
  • They will walk away happy with the best gift ever...the gift of Choice

Why ONYX GiftCards?

  • Save TIME. No need to run around looking for the perfect gift
  • Redeem from a variety of business island-wide. We will continue adding businesses as fast as ONYX grows.
  • ONYX Gift Cards do not expire
  • Cards are valued at convinient amounts to meet every need and occasion

What a Square test card is

A Square test card is a card number that the Square sandbox accepts for payment testing. It never reaches a real issuer, moves no money, and exists so you can run charges, refunds, and decline scenarios before you accept live payments. Square publishes a table of test numbers by card brand in its developer documentation. Use those numbers only with sandbox credentials. A test card sent to the production endpoint will fail or, worse, create a real payment record you have to void.

Prerequisites

How to run a test charge

  1. Sign in to the Developer Dashboard and set the application toggle to Sandbox.
  2. Copy the sandbox application ID into your checkout configuration.
  3. Copy the sandbox access token into your server environment variables.
  4. Load your checkout page with the Web Payments SDK initialized in sandbox mode.
  5. Enter a test number from the published table, such as 4111 1111 1111 1111 for Visa.
  6. Enter a future expiration date and the CVV that the documentation lists for that card.
  7. Submit the payment and confirm the API response returns a payment ID with an APPROVED status.
  8. Open the Sandbox section of the Dashboard and confirm the payment appears in the transaction list.
  9. Send a refund request against that payment ID and confirm the refund object comes back with a matching amount.

Testing declines and error paths

Happy-path charges prove little on their own. Square also lists test cards and CVV values that trigger specific failures, including card declines and CVV mismatches. Wire each one into an automated test so your checkout shows the right message instead of a blank error screen. Keep a separate case for network timeouts and for duplicate idempotency keys, since those are the failures that cost real merchants money.

Common mistakes

Keeping test data separate

Gate every test card and sandbox key behind an environment flag, and fail the build if a sandbox token appears in a release configuration. Store card data only inside the SDK's hosted fields so your servers never touch a full number, which keeps you inside PCI DSS scope limits. Review the current Square test card table before each integration release, because a number that worked last quarter may now return a different result.

Contact Us

Latest

AVS Test

Enhance your security with our comprehensive AVS Test, ensuring safe and secure transactions.

Read our complete guide: Should You Buy CVV From a Card Shop? The Honest Buyer's Guide