GoDaddy

How to get set up to accept payments

View as Markdown

Set up the GoDaddy Payments account, store ID, and Personal Access Token that every online and in-person payment needs.

Overview

Every online and in-person payment needs the same three things. You need a GoDaddy Payments account with an active store, your storeId, and a Personal Access Token (PAT) with the right scopes. You set them up once, and every page under Accept payments assumes you have them.

This page also lists what must be true before your software charges a paying customer.

Create a GoDaddy Payments account

There's no API for this step. You create the GoDaddy Payments account and activate the store in the GoDaddy interface. This path uses a PAT on your own account, so there's no developer organization, OAuth client, or application registration to set up.

Create a GoDaddy Payments account

Go to Set up a GoDaddy Payments account to create your account and activate your store.

Without the GoDaddy Payments account, you can still create a session, but the payment fails.

Find your store ID

Every payment names the store it belongs to with storeId.

Find your store ID

Sign in to your GoDaddy account and go to About the Commerce API to retrieve your storeId.

Create a Personal Access Token

A PAT authenticates your server. Create it on the account that owns the store, and select only the scopes for the calls you intend to make.

The following table lists the scopes each task needs:

TaskScopes
Create checkout sessionscommerce.checkout-session:write
Charge a card on a terminal and read the resultcommerce.payment-request:write, commerce.payment-request:read
List the terminals on a storecommerce.store:read
Read a store's sales channelscommerce.channel:read
Read transactionscommerce.transaction:read
Register a domain for Apple Paycommerce.store.apple-pay:write, commerce.store:read

Go to How to Authenticate to create the token.

Keep the token on your server

The token displays once, so store it in a secrets manager. The browser never needs it. For online payments, the checkout session carries a token of its own, and that's what the checkout form authenticates with.

Set the environment variables

The examples under Accept payments read the following values from the environment:

VariableValueUsed by
GODADDY_PATYour Personal Access TokenEvery example
STORE_IDYour storeIdEvery example
SKU_IDA SKU in your catalogOnline examples that charge an existing SKU
DRAFT_ORDER_IDA draft order you createdOnline examples that charge an existing draft order
TRANSACTION_IDA transaction ID from a completed paymentTransaction lookup examples
DEVICE_IDThe terminal's device identifierIn-person examples
SERIAL_NUMBERThe serial number printed on your terminalIn-person examples that find a deviceId
PAYMENT_REQUEST_IDA UUID you generate for a new charge, or the ID of the request you pollIn-person examples
REFERENCE_IDYour own order or ticket numberIn-person examples that set references
CALLBACK_URLThe public HTTPS URL that receives payment request callbacksIn-person examples
WEBHOOK_SECRETThe shared secret GoDaddy signs callbacks withIn-person examples
UPDATED_AT_AFTERAn RFC 3339 date-time, like the start of an outageIn-person examples that list payment requests

Go to How to connect your terminal to find a terminal's DEVICE_ID.

Before you take live payments

You must meet the following prerequisites before your software charges a paying customer:

  • a GoDaddy Payments account

  • an active store on that account

  • a PAT with the scopes for every call you make

  • for in-person payments, a GoDaddy terminal (Duo, Flex, or Pro) purchased for the account

    Buy a terminal

    Go to GoDaddy Payments point of sale to choose and buy a terminal.

  • for Apple Pay online, every checkout domain registered

    Register Apple Pay domains

    Go to How to set up Apple Pay to register your domains.

Tax is optional and configured on the store. Go to Create and apply taxes to set it up in the GoDaddy interface, or How to configure your taxes to set it up through the API.

Last updated on

How is this guide?

On this page