Back to Nodes

TOTVS RM

Last updated Mar 20, 2026

Native n8n nodes for TOTVS ERP Linha RM โ€” DataServer REST, native REST APIs, automatic JWT auth, and full module coverage

9 Weekly Downloads
33 Monthly Downloads

Included Nodes

TOTVS RM

Description

TOTVS RM logo

n8n-nodes-totvs-rm

Native n8n nodes for TOTVS ERP Linha RM

Connect your n8n workflows directly to TOTVS RM โ€” with automatic JWT authentication, access to any DataServer, and dedicated operations for HR, Payroll, Stock, Finance, Accounting, and more.

![npm version](https://www.npmjs.com/package/n8n-nodes-totvs-rm)
![License: MIT](LICENSE)
![n8n community](https://www.npmjs.com/package/n8n-nodes-totvs-rm)

โœจ Features

  • ๐Ÿ” Automatic JWT authentication โ€” token obtained and cached automatically (renewed before expiry)
  • ๐Ÿ—„๏ธ Generic DataServer access โ€” call any of the 1,000+ DataServers via RMSRestDataServer
  • ๐Ÿ“ฆ 12 dedicated modules with pre-built operations
  • ๐Ÿ” SQL filter support โ€” LIKE, AND, OR, IN, field selection, pagination, ordering
  • ๐ŸŒ Bilingual interface (PT-BR / EN)
  • ๐Ÿ“ฆ Modules & Operations

    | Module | Key Operations |
    |——–|—————|
    | Framework | Get JWT Token, Health Check, List DataServers |
    | DataServer (Generic) | List, Read, Create, Update, Delete any DataServer |
    | Employees (HR) | List, Get by Badge, Create, Update, Dismiss |
    | Payroll | List Calculations, Get Calculation |
    | Invoice (Stock) | List, Get, Create, Cancel |
    | Stock Movement | List, Get, Create |
    | Accounts Payable/Receivable | List, Get, Create, Mark as Paid |
    | Accounting Entry | List, Get, Create |
    | Customers / Suppliers | List, Get, Create, Update |
    | Users | List, Get, Create, Update |
    | Companies | List, Get |
    | Enrollment (Education) | List, Get, Create |

    ๐Ÿš€ Installation

    Option 1 โ€” n8n self-hosted

    Go to your n8n custom nodes directory

    cd ~/.n8n/nodes

    Clone the repository

    git clone https://github.com/espindolavinicius/n8n-nodes-totvs-rm.git cd n8n-nodes-totvs-rm

    Install and build

    npm install npm run build

    Restart n8n

    Option 2 โ€” via npm (after publishing)

    npm install n8n-nodes-totvs-rm
    

    Option 3 โ€” Docker

    Add to your Dockerfile or docker-compose.yml:

    RUN cd /home/node && npm install n8n-nodes-totvs-rm
    

    Or with docker-compose.yml:

    services:
      n8n:
        image: n8nio/n8n
        environment:
          - N8NNODESINCLUDE=n8n-nodes-totvs-rm
        volumes:
          - n8n_data:/home/node/.n8n
    

    โš™๏ธ Credential Setup

    In n8n, go to Settings โ†’ Credentials โ†’ New โ†’ TOTVS RM API and fill in:

    | Field | Example | Description |
    |——-|———|————-|
    | RM Host URL | http://10.0.0.1:8051 | Address of RM.Host.Service |
    | Username | admin | RM system login |
    | Password | ** | User password |
    | Default Company Code | 1 | CODCOLIGADA |
    | Default Branch Code | 1 | CODFILIAL |

    > Tip: Make sure port 8051 is accessible from the n8n server. For HTTPS, use https://your-server:port.

    ๐Ÿ’ก Usage Examples

    List active employees

  • Module: Employees (HR)
  • Operation: List Employees
  • SQL Filter: CODCOLIGADA=1 AND CODSITUACAO='A'
  • Order By: NOME ASC
  • Get a specific invoice

  • Module: Invoice (Stock)
  • Operation: Read Record
  • SQL Filter: CODCOLIGADA=1 AND NUMERONF='000001234'
  • Use a custom DataServer

  • Module: DataServer (Generic)
  • Operation: List Records (GetAll)
  • DataServer Name: SmtAtestadoData
  • SQL Filter: CODCOLIGADA=1
  • Discover all available DataServers

  • Module: Framework
  • Operation: List Available DataServers
  • ๐Ÿ—‚๏ธ Common DataServers Reference

    | Module | DataServer | Description |
    |——–|———–|————-|
    | HR / Employees | FopFuncData | Employee register |
    | HR / Payroll | FopFolhaCalcData | Payroll calculation |
    | HR / Medical | SmtAtestadoData | Medical certificates |
    | Stock / Invoice | FisNfData | Invoices |
    | Stock / Movement | TMovData | Stock movements (TMOV) |
    | Stock / Items | TITMMovData | Movement items |
    | Financial | MovData | Financial entries |
    | Accounting | CttLancData | Accounting journal |
    | Global / Person | GlbPessoaData | Customers and suppliers |
    | Global / User | GlbUsuarioData | System users |
    | Global / Company | GlbColigadaData | Companies |
    | Education | EduMatriculaData | Student enrollments |

    ๐Ÿ› ๏ธ RM Host Configuration

    In RM.Host.exe.config or RM.Host.Service.exe.config, ensure:

    
    
    

    For custom SSL certificate:

    
    

    ๐Ÿ” How Authentication Works

    1. On the first call, the node sends POST /api/connect/token with username and password
    2. The JWT token is cached in memory with its expiry time
    3. The token is automatically renewed 60 seconds before expiry
    4. Every request includes Authorization: Bearer

    ๐Ÿค Contributing

    Pull requests are welcome! To add a new module:

    1. Add the resource option in TotvsRm.node.ts
    2. Add the operations block with displayOptions
    3. Map the DataServer in dsMap
    4. Update this README

    ๐Ÿ‘จโ€๐Ÿ’ป Author

    Vinicius Espindola

  • GitHub: @espindolavinicius

๐Ÿ“„ License

MIT ยฉ Vinicius Espindola