Pagar.me Payment icon

Pagar.me Payment

Interact with Pagar.me API for payments

Overview

This node interacts with the Pagar.me API to perform various payment-related operations. It supports creating payments, retrieving payment details, tokenizing credit cards, making payments with tokens, fetching BIN information, and making generic API requests. This node is useful for automating payment processing workflows, managing card tokens, and querying payment data within an n8n workflow.

Use Case Examples

  1. Create a new payment by providing card details and amount.
  2. Retrieve details of an existing payment using its payment ID.
  3. Tokenize a credit card to securely store card information for future payments.
  4. Make a payment using a saved card token or card ID with specified installments and capture options.

Properties

Name Meaning
HTTP Method The HTTP method to use for the generic API request operation (GET, POST, PUT, PATCH, DELETE).
Path (relative to /core/v5) The API endpoint path relative to the base URL /core/v5 for the generic request operation.
Query (JSON) A JSON object representing query parameters to include in the generic API request.
Body (JSON) A JSON object representing the request body for POST, PUT, or PATCH methods in the generic API request.
Headers (JSON) Optional HTTP headers as a JSON object to include in the generic API request.
Attach Public Key as appId (for /tokens) If enabled and the path starts with 'tokens', appends the public key as an appId query parameter to the request URL.

Output

JSON

  • json - The JSON response data returned from the Pagar.me API for the executed operation.

Dependencies

  • Pagar.me API key credential (apiKey)
  • Pagar.me API public key credential (publicKey) for tokenization and /tokens requests

Troubleshooting

  • Ensure the Pagar.me API key credential is correctly configured and has necessary permissions.
  • For tokenization and /tokens API calls, ensure the public key credential is set; otherwise, an error will be thrown.
  • Verify that JSON inputs for query, body, and headers are valid JSON objects to avoid parsing errors.
  • Check that the HTTP method and path are correctly specified for generic requests.
  • Common error messages include API errors with HTTP status codes and details from the Pagar.me API response, which help identify issues like authentication failures or invalid parameters.

Links

Discussion