Introduction - Pluga

Connect Asaas to other tools through Pluga to create charges, send financial information, or run other available flows without building your own integration.

An automation consists of a trigger, which starts the flow, and one or more actions executed in the connected tools.

How it works

%%{init: {"flowchart": {"nodeSpacing": 18,"rankSpacing": 24,"diagramPadding": 4,"padding": 7}}}%%
flowchart TD
    A["Event in the source tool"] --> B["Pluga identifies the trigger"]
    B --> C["Map the data"]
    C --> D["Execute the action"]
    D --> E["Update the destination tool"]

    classDef inicio fill:#DBEAFE,stroke:#2563EB,color:#1E3A8A,stroke-width:3px
    classDef validacao fill:#E0F2FE,stroke:#0284C7,color:#0C4A6E,stroke-width:2px
    classDef sucesso fill:#DCFCE7,stroke:#16A34A,color:#14532D,stroke-width:3px

    class A inicio
    class B,C,D validacao
    class E sucesso

    linkStyle default stroke:#94A3B8,stroke-width:2px

Asaas can act as the source or the destination:

DirectionExample
Input into AsaasCreate a charge from a sale, form, spreadsheet, or other system.
Output from AsaasSend charge information to spreadsheets, CRMs, ERPs, or other tools.

The availability of triggers, actions, filters, and fields depends on the automation template offered by Pluga.

When to use Pluga or the API

Use Pluga when the available template covers the flow you need to automate without your own development.

Consider a direct integration with the Asaas API when you need:

  • specific business rules;
  • a high volume of requests;
  • your own control of queues, retries, and logs;
  • custom error handling;
  • idempotency controlled by the application;
  • advanced validations;
  • features that are not available in Pluga;
  • asynchronous or conditional flows that require your own architecture.

Before you begin

Have:

  • an active Asaas account;
  • a Pluga account;
  • access to the other tool in the automation;
  • permission to connect the accounts involved;
  • a valid API key for the Asaas account;
  • the trigger and action you want to execute defined.
🚧

Attention

The Asaas API key allows Pluga to perform actions on the connected account.

Store this credential in a secure place and avoid sharing it in messages, public spreadsheets, or channels without access control.

If you need to create a credential, see API Keys.

1. Choose the automation

Go to the Asaas integrations page on Pluga.

Then:

  1. choose the tool that will be connected to Asaas;
  2. find the desired automation template;
  3. click Fazer essa automatização (Create this automation).

Before continuing, confirm that the template has the trigger and action required for your operation.

2. Connect the accounts

Connect the Asaas account using the API key.

Then authenticate the other tool used in the flow.

Confirm that the connected accounts correspond to the expected environments and operations before mapping the fields.

3. Configure triggers and filters

Define the event that will start the automation.

Examples of triggers available in Pluga templates include changes related to charges or events originating in external tools.

When the template allows filters, use them to prevent executions that do not meet your operation's rules.

4. Map the fields

Associate the data from the source tool with the fields expected by the action.

In an automation that creates charges in Asaas, review in particular:

GroupExamples
CustomerName, email, CPF/CNPJ, phone
ChargeAmount, due date, description, payment method
ControlOrder number, sale ID, external reference
Additional settingsInstallments, split, notifications, or other fields available in the template

Missing or invalid required fields can prevent the automation from running.

📘

Best practice

Whenever the Pluga template allows it, use a source identifier, such as the order number, sale ID, or external reference.

This identifier helps with reconciliation between systems and reduces the risk of duplicates.

5. Test the automation

Before activating the flow:

  1. review the connected accounts;
  2. check triggers and filters;
  3. validate the mapping;
  4. use controlled data;
  5. run the test;
  6. confirm the result in the destination tool.

If the action creates a charge in Asaas, check in particular:

  • customer;
  • amount;
  • due date;
  • payment method;
  • reference used for reconciliation.

Expected result

The action defined in the template should run with the mapped data and appear correctly in the destination tool.

If the automation creates a charge, also confirm that it was registered in the expected Asaas account before activating the flow.

6. Activate the automation

After validating the test, click Finalizar automatização (Finish automation).

From then on, execution will follow the trigger, filters, and mappings defined in Pluga.

📘

Important

Integrations via Pluga run according to the templates available on the platform itself.

If your operation depends on specific behavior, confirm that the required trigger, action, and fields are available before putting the automation into production.

Flow examples

Create a charge from a sale

%%{init: {"flowchart": {"nodeSpacing": 18,"rankSpacing": 24,"diagramPadding": 4,"padding": 7}}}%%
flowchart TD
    A["Register new sale"] --> B["Pluga identifies the event"]
    B --> C["Send the data to Asaas"]
    C --> D["Create the charge"]
    D --> E["Make the charge available to the customer"]

    classDef inicio fill:#DBEAFE,stroke:#2563EB,color:#1E3A8A,stroke-width:3px
    classDef validacao fill:#E0F2FE,stroke:#0284C7,color:#0C4A6E,stroke-width:2px
    classDef sucesso fill:#DCFCE7,stroke:#16A34A,color:#14532D,stroke-width:3px

    class A inicio
    class B,C,D validacao
    class E sucesso

    linkStyle default stroke:#94A3B8,stroke-width:2px

Record a received charge in a spreadsheet

%%{init: {"flowchart": {"nodeSpacing": 18,"rankSpacing": 24,"diagramPadding": 4,"padding": 7}}}%%
flowchart TD
    A["Charge received in Asaas"] --> B["Pluga identifies the event"]
    B --> C["Send the data to Google Sheets"]
    C --> D["Create a row in the spreadsheet"]
    D --> E["Record the receipt"]

    classDef inicio fill:#DBEAFE,stroke:#2563EB,color:#1E3A8A,stroke-width:3px
    classDef validacao fill:#E0F2FE,stroke:#0284C7,color:#0C4A6E,stroke-width:2px
    classDef sucesso fill:#DCFCE7,stroke:#16A34A,color:#14532D,stroke-width:3px

    class A inicio
    class B,C,D validacao
    class E sucesso

    linkStyle default stroke:#94A3B8,stroke-width:2px

Avoid duplicates

In automations that create charges or customers, use a reference from the source tool whenever the template allows it.

Before reprocessing an execution:

  • check the Pluga history;
  • confirm whether the record has already been created in Asaas;
  • review filters and triggers;
  • avoid resending the same data without checking the previous result.

Changes to the mapping affect the next executions of the automation and do not automatically change records that have already been created.

Common errors

SituationWhat to check
Charge was not createdRequired fields, data sent, and API key
Data was created incorrectlyMapping between source and destination
Automation did not runTrigger, filters, and automation status
Record was duplicatedReprocessing and control identifier
Authentication failureAccount connection and API key validity
Data did not reach the destinationExecution history and mapped fields

If the flow fails, first check the Pluga execution history to identify the step where the error occurred.

Available tools

The list of compatible tools and templates may change as new connectors are added or removed by Pluga.

📘

Important

The availability of each integration is defined by Pluga itself.

To see the complete and always up-to-date list of connectors available for Asaas, go to:

https://pluga.co/ferramentas/asaas/integracao/

Next steps


Did this page help you?