When to use P2P
P2P is the right transfer type whenever both the sender and recipient hold accounts at your institution. Common scenarios include:
- Moving money between a customer’s own accounts — a customer transferring from their checking account to their savings account, or between two accounts they manage.
- Paying another customer at the same institution — a customer sending money to a friend, family member, or business that also banks with you.
- Internal treasury movements — splitting balances between corporate accounts held within the same organization.
- Payment splitting — distributing amounts across multiple accounts for payroll, expense sharing, or cashback.
Key advantages
How it works
P2P reuses the same API as TED OUT, so your integration stays consistent across transfer types. The process is two steps from the customer’s perspective:
- Initiate — The customer submits the transfer details. The plugin validates the recipient, checks the sender balance, and confirms the fee (typically R$ 0.00). The customer sees the transfer summary before committing.
- Confirm — The customer confirms. The plugin creates an atomic debit + credit in Midaz. The transfer completes immediately.
Transfer states
The
PENDING state does not apply to P2P transfers. TED OUT uses PENDING to mark funds it reserves while it awaits SPB submission. P2P settles entirely within Midaz, so the transfer moves directly from PROCESSING to COMPLETED.Fee configuration
The plugin disables fees by default. Most institutions offer internal transfers at no charge. The fee configuration is available if your pricing model needs it. To enable P2P fees, see TED configuration.
Recipient validation
The recipient must have an account at the same institution. When you submit a transfer, the plugin looks up the recipient in CRM. It matches the bank details you provide: ISPB, branch, account, and holder document. If the plugin does not find the recipient, it rejects the transfer and moves no funds. The customer must check the account details and try again.
Technical integration
P2P uses the same endpoints as TED OUT. You need no extra integration work beyond the outbound transfer flow you already built.
- Initiate Transfer — POST /v1/transfers/initiate
- Process Transfer — POST /v1/transfers/process
- Get Transfer — GET /v1/transfers/
The
type field in the transfer response is P2P. P2P transfers have no controlNumber, because they do not go through JD SPB.Error handling
P2P transfers are atomic. The plugin creates the debit and credit as a single Midaz transaction. If any part fails, Midaz applies neither leg. No intermediate state moves funds partially or leaves an account short. If a transfer fails, the customer keeps the same balance and can retry. See the full error list for error codes and recovery guidance.

