# Connect your Bayarcash account

> Link BCL to your Bayarcash merchant account with your Personal Access Token and API Secret Key so your forms collect real payments.
>
> Source: https://docs.bcl.my/connect-bayarcash/

BCL collects payments through Bayarcash. To take real payments, paste your Bayarcash **Personal Access Token (PAT)** and **API Secret Key** into BCL. This is step 1 of 4 to your first sale.

Until you connect Bayarcash or turn on **Test Mode**, BCL opens the Payment Settings page each time you sign in.

## Before you start

You need two things before you connect:

- An approved Bayarcash merchant account. If you do not have one, [register as a Bayarcash merchant](https://console.bayar.cash/register-merchant) first.
- To be the BCL account owner. Only the owner can change payment settings.

> **Tip**
> Still waiting for Bayarcash approval? Turn on **Test Mode** and start building your forms. Test payments go to the Bayarcash sandbox, and no real money moves. You do not need to edit those forms after you connect.

## Get your token and secret key

Both keys come from the Bayarcash Console:

1. Log in to the [Bayarcash Console](https://console.bayar.cash/).
2. Open the [Integration page](https://console.bayar.cash/token-secret-key).
3. Copy your **Personal Access Token (PAT)** and your **API Secret Key**.

## Connect BCL to Bayarcash

With both keys copied, connect your account in BCL:

1. Go to **Platform Setup** > **Payment**. The **Payment Settings** page opens on the **Bayarcash Setup** tab.
2. Turn off **Test Mode**.
3. Paste your token into **Personal Access Token (PAT)**.
4. Paste your key into **API Secret Key**. BCL checks both keys when you click out of each field. When they are valid, a green **Token Verified** box shows your Bayarcash merchant name.
5. In **Default Portal**, choose the Bayarcash portal that receives payments when a form does not pick its own. If you only have one portal, BCL selects it for you. See [Choose a Bayarcash portal key](/bayarcash-portal-key/).
6. Click **Save Configuration**.

The first time you save, BCL also copies your company details from the Bayarcash Console if your company profile has no registration number yet.

## Change your settings later

When you change the token, secret key or default portal after the first save, BCL asks for a one-time code to confirm it is you:

1. Make your change and click **Save Configuration**.
2. In **Send code via**, choose **Email** or **SMS**, then click **Send code**. SMS is only offered when the owner's phone number is a Malaysian (+60) number.
3. Enter the code in **One-time code** and click **Verify & Save**.

Next step: [Set your gateway fees](/gateway-fees/).

## Common issues

### My Bayarcash account has just been approved. Do I need to edit the forms I built in Test Mode?

No. On Platform Setup > Payment, enter your token and secret key, choose a Default Portal and turn off Test Mode. Forms that do not pick their own portal use the default portal.

### Why does BCL keep sending me back to the Payment Settings page?

BCL needs either a connected Bayarcash account or Test Mode turned on. Save your Personal Access Token (PAT) and API Secret Key, or turn on Test Mode to try BCL first.

### Why can't I see the token fields?

Only the account owner can change payment settings. Other admins see a notice with the owner's name and email instead. Ask the owner to make the change.
