< Back to all integrations

TOTVS

ERP & Finance

Connect AI agents and workflows to TOTVS Protheus, RM and Datasul: customers, suppliers, products, sales and purchase orders, invoices and receivables.

Book a demo
[ TOTVS + engini ]

TOTVS for AI agents and workflows.

engini lets your AI agents and workflows work in TOTVS, the leading ERP in Brazil and across Latin America, on Protheus, RM or Datasul: read customers, suppliers, products and stock, enter sales and purchase orders, read invoices and electronic fiscal documents, follow receivables and payables, call the REST services your team publishes, and start a workflow when records change. Subsidiaries in Brazil stay in step with headquarters on another ERP. Connect from Claude, ChatGPT or Cursor over MCP, from your code, or build in Workflow Studio.

MCPPython and TypeScript SDKCLIREST APIWorkflow Studio
Sign-inA TOTVS user for the REST APIs, by company and branch
ReachCustomers, suppliers, products, stock, sales and purchase orders, invoices, receivables and payables
DeploymentTOTVS Cloud, or on premises through the On-Prem Agent
[ 01 / What agents can do ]

What your agent can do in TOTVS. Every tool is one you allow or leave out.

The TOTVS tools in engini, grouped by what they change. In an ERP a write is a financial and fiscal event, so write tools go only to the agents that need them.

Read

Get Customers, Get Suppliers, Get Products

Read master data by company and branch.

Read
Get Stock Balances

Read stock by warehouse.

Read
Get Sales Orders, Get Purchase Orders

Read orders and their status.

Read
Get Invoices

Read issued and received invoices, with their electronic fiscal document keys.

Read
Get Receivables, Get Payables

Read open financial titles.

Read

Write

Create Sales Order

Enter an order with its items.

Write
Create Purchase Order

Raise an order to a supplier.

Write
Create or Update Customer, Supplier or Product

Keep master data current.

Write
Call REST Service

Run any REST service your team publishes in TOTVS.

Write

Any endpoint

Send API Request

Call any TOTVS API, with the sign-in added for you.

Any call

Triggers

Check for New or Changed Records

Orders, invoices or customers added or changed.

Scheduled

A trigger starts a workflow, and a workflow can include an AI agent step. In Code, a trigger delivers the event to your own endpoint.

[ 02 / Connect your agent ]

Connect your AI agent to TOTVS. Four ways in, one set of permissions.

MCP

Claude, ChatGPT, Cursor

Create an MCP server in engini with your TOTVS connection and only the tools you choose. Add its address to your client and sign in through engini. There is no key to copy.

MCP client setup →
SDK

Python and TypeScript

Hand your agent a toolset of TOTVS tools. The SDK gives OpenAI and Anthropic models the tools in the format they expect and runs the ones they pick.

SDK guide →
CLI

For coding agents

The engini CLI connects TOTVS and runs its tools from a terminal, with machine-readable output, so an AI coding agent can drive it without getting stuck.

CLI guide →
REST API

Any language

Every TOTVS tool is an endpoint. Call it with exact inputs from a scheduled job or a sync, with no model in the loop.

API reference →
MCP in four steps
In engini, connect TOTVS and create an MCP server with that connection and the tools this agent may use.
Claude: Settings, Connectors, Add custom connector, then paste the server address.
Cursor: add the address to .cursor/mcp.json. Claude Code: claude mcp add.
Sign in through engini when the client asks. The agent sees only the tools you chose.
Cursor, connected to TOTVS through engini
// .cursor/mcp.json: Cursor, connected to TOTVS through engini
{
"mcpServers": {
"engini-totvs": {
"url": "<your engini MCP server address>"
}
}
}

Create the MCP server in engini with your TOTVS connection and the tools this agent may use, then paste its address. The client signs in through engini on first use. Claude, VS Code and other clients take the same address: see the MCP client setup guide.

Try asking your agent
“Which sales orders for this customer are still open in branch 01?”
“How much of product 000123 is in stock in warehouse 01?”
“Enter a sales order for 40 units of 000123 for customer 000045.”
“Which receivables are overdue this month?”
“Show the invoices issued yesterday with their fiscal keys.”
“Which suppliers were added this quarter?”

Each request runs through the TOTVS tools in the agent's toolset or MCP server. If a tool is not allowed, the agent cannot call it.

[ 03 / What teams build ]

What teams build on TOTVS. Agents and workflows, across systems.

Subsidiaries

Brazil on TOTVS, headquarters elsewhere

Sales, invoices and balances from a Brazilian subsidiary on TOTVS reach headquarters on NetSuite, SAP or Oracle, and both sides reconcile.

TOTVSNetSuiteSAP S/4HANA
Order to cash

Orders from the CRM and the store

Orders from Salesforce or Shopify become TOTVS sales orders, and the invoice key goes back to the customer record.

SalesforceShopifyTOTVS
Finance

Receivables people follow up

Overdue receivables go to the account owner in Teams with the invoice details.

TOTVSMicrosoft Teams
Operations

Answers in plain words

An agent answers stock, order and invoice questions from TOTVS. Its toolset holds read tools only.

ClaudeTOTVS

Every integration runs both ways, so any of these flows can also run in reverse. These are examples, not the limit: any flow between TOTVS and another system engini connects is available.

[ 04 / Agent Policy ]

You decide what each agent may do in TOTVS. engini enforces it on every call.

Toolsets

Only the tools you allow

A toolset lists the TOTVS tools an agent may call and the connection each one uses. Give one agent read tools only and another the write it needs. engini refuses any call outside the toolset.

MCP servers

Scoped when you set them up

An MCP server exposes only the connections and tools chosen when it is created, and engini shows who uses each server.

Identity

Whose permissions apply

Connect a person's own TOTVS account and engini acts as that person, with their TOTVS permissions. Use a shared integration account and it acts as that account. Every run is recorded under the user who started it.

Credentials

Kept out of prompts

Your agent never needs your credentials: engini stores them and adds them when it runs each call, so keys stay out of prompts and tool inputs.

Audit

Every call on record

Every call lands in History and the audit log, which you can export or stream to your SIEM.

Environments

Test before production

Workspaces keep teams apart, and development, staging and production environments keep a test agent away from live data.

SOC 2 Type IIISO 27001GDPRSecurity at engini →
[ Behind your firewall ]

TOTVS behind your firewall.

If TOTVS runs in your own data center, install the engini On-Prem Agent on a server inside your network. It opens every connection itself: out to engini over HTTPS on port 443, and to TOTVS while it runs a task. You open no inbound ports or firewall rules. Calls through it run on the same engine as MCP, the API and workflows, and each one is recorded in History.

On-Prem Agent guide →
[ 05 / Set up ]

Connect TOTVS in three steps. Then decide what each agent may do.

Step 01

Sign in to TOTVS

Create a TOTVS user with access only to the routines the workflows need and enable the REST services, then add a TOTVS connection with your server, company, branch and that user, through the On-Prem Agent if TOTVS runs inside your network.

Step 02

Choose the tools

Add the connection to an MCP server or a toolset with only the tools each agent needs.

Step 03

Build or ask

Use the connection as a step in a workflow, or ask your agent to work in TOTVS from Claude, ChatGPT, Cursor or your own code.

[ 06 / Questions ]

TOTVS and engini. Straight answers.

Can an AI agent write to TOTVS, or only read?

Both. engini has tools to enter sales and purchase orders, create and update customers, suppliers and products, and call published REST services. Whether a given agent may use them is up to you: give it a toolset or an MCP server with read tools only, and it cannot call the rest.

Does the agent act as me in TOTVS?

It acts as the TOTVS user behind the connection, with that user's access by company and branch. Every run is recorded under the person who started it.

Can a change in TOTVS start work?

Yes. Scheduled triggers check TOTVS for new or changed orders, invoices and customers. A workflow can include an AI agent step.

What if the tool I need is not listed?

Use Send API Request to call any TOTVS API endpoint through the same connection, and give it only to the agents that need it.