For AI agents: the complete documentation index is available at https://docs.clickmax.io/en/llms.txt, the full documentation bundle is available at https://docs.clickmax.io/en/llms-full.txt, and this page is available as Markdown at https://docs.clickmax.io/en/features/integrations/pagbank.md.
  • English
  • Integrate PagBank

    Generate a token in your PagBank account, paste it into Clickmax and click Complete integration. Once the integration is active, you sell through the PagBank Checkout block in your Clickmax pages and funnels, and the sales arrive by themselves: each payment becomes a sale, creates or updates the buyer's contact (tagged pagbank) and can fire automations. There is nothing to configure in PagBank.

    Before you start

    • Workspace role: Owner, Admin, Editor or Collaborator. Finance, Guest and Attendant have no access to Integrations.
    • A PagBank account with access to the sales panel.

    Step by step

    1. In another tab, log in to your PagBank account and open Vendas > Integrações (Sales > Integrations).
    2. Click Gerar token (Generate token) and copy the token.
    3. In Clickmax, open Integrations and select the PagBank card.
    4. Paste the token into the PagBank token field, fill in the Integration nickname and leave Status active.
    5. Click Complete integration.

    Clickmax detects by itself whether the token is a production or a test token. To test without real charges, generate a test (sandbox) token at portaldev.pagbank.com.br, under Tokens, and use it instead of the production token.

    Selling right on your pages

    With the token pasted, the editor's PagBank Checkout block sells on the page itself, without the buyer leaving it:

    • Payment methods: credit card (up to 12 installments; PagBank requires a minimum amount per installment), Pix and boleto. Boleto asks for the buyer's address.
    • 1-click purchase: buyers who just paid by card see Quick checkout in the upsell or downsell and pay with the saved card.
    • One-time products only: the block doesn't sell subscriptions.
    • Only the token: the public key needed to protect card data is obtained by Clickmax from the token. There is nothing else to copy.
    • Pix and boleto enabled in the account: if the PagBank account doesn't have one of them enabled, the block panel shows the PagBank declined sales from this page warning and the buyer sees that the method is unavailable.

    Step by step is in How to sell through PagBank right on my page and, for funnels, in How to use the PagBank checkout as a step in my funnel.

    What arrives in Clickmax

    Sales made through the PagBank checkout in your Clickmax pages and funnels, by card, Pix or boleto.

    Each event creates or updates the buyer's contact, records an activity in the contact's history and can fire automations. The contact gets origin Integrations, sub-origin Pagbank and the tag pagbank. Approved payments mark the contact as a customer.

    What doesn't arrive

    • Sales made on other sites or stores that use PagBank as their payment method — for example, a WooCommerce store with the PagBank plugin. PagBank sends those notices to the system that created the order, not to Clickmax. For those sales, use the store integration: WooCommerce, Shopify or Nuvemshop.
    • Payment links created in the PagBank panel.

    Available triggers

    The triggers are in the PagBank group in automations. All of them accept an optional product filter, which matches the product code of the offer sold in the checkout.

    TriggerWhen it fires
    Boleto generatedA boleto is generated and awaits payment
    Payment approvedThe payment is approved
    Payment declinedThe payment is declined
    Payment canceledA payment is canceled before being paid
    Payment refundedA paid payment is refunded

    How sales are recorded

    • One sale per charge. Each payment creates a sale.
    • The same sale follows the payment. A generated boleto comes in as a pending sale and becomes paid once it clears. A refund changes the status of that same sale instead of creating another one.

    If it didn't work

    • The token is rejected: generate a new token under Vendas > Integrações in PagBank and paste it again. For a real account, use a production token, not the test token from the developer portal.
    • The PagBank Checkout block doesn't sell: check that the integration is active with the token, and that Pix and boleto are enabled in the PagBank account. See How to sell through PagBank right on my page.
    • A sale doesn't show up: check that it was made through the PagBank checkout of a Clickmax page or funnel and that the integration is active in Integrations. Sales from other sites and from payment links created in the PagBank panel don't arrive.
    • The automation doesn't fire for a product: check that the product picked in the trigger filter is the same as the offer sold in the checkout.