> ## Documentation Index
> Fetch the complete documentation index at: https://docs.methodfi.com/llms.txt
> Use this file to discover all available pages before exploring further.

# The reversal endpoint

export const get_common_parameters = (resource_name = 'resource') => {
  return {
    id: {
      name: 'id',
      type: "string",
      required: false,
      description: `Unique identifier for the ${resource_name}.`
    },
    entity_id: {
      name: 'entity_id',
      type: 'string',
      required: false,
      description: 'The ID of the associated Entity.'
    },
    account_id: {
      name: 'account_id',
      type: 'string',
      required: false,
      description: 'The ID of the associated Account.'
    },
    error: {
      name: 'error',
      type: 'object | null',
      required: false,
      description: <>
          An object representing an error that occurred while processing
          this {resource_name}. See <a href={`/reference/errors/${resource_name.replace(/^([A-Z])/, function (match) {
        return match.toLowerCase();
      }).replace(/([A-Z])/g, function (match) {
        return "-" + match.toLowerCase();
      })}-errors`}>{resource_name} errors</a>.
        </>
    },
    status_error: {
      name: 'status_error',
      type: 'object | null',
      required: false,
      description: <>
          An object representing an error that occurred while processing
          this {resource_name}. See <a href="/reference/errors/product-errors#status-errors">{resource_name} errors</a>.
        </>
    },
    metadata: {
      name: 'metadata',
      type: 'object | null',
      required: false,
      description: <>
          Additional data provided during creation.
          See <a href="/reference/metadata">metadata</a>
        </>
    },
    created_at: {
      name: 'created_at',
      type: 'string',
      required: false,
      description: `Timestamp of when the ${resource_name} was created.`
    },
    updated_at: {
      name: 'updated_at',
      type: 'string',
      required: false,
      description: `Timestamp of when the ${resource_name} was last updated.`
    },
    status: (enums = []) => ({
      name: 'status',
      type: 'enum',
      required: false,
      description: `Status of the ${resource_name}.`,
      enums
    }),
    type: (enums = []) => ({
      name: 'type',
      type: 'enum',
      required: false,
      description: `The type of ${resource_name}.`,
      enums
    })
  };
};

export const ParamList = ({items = [], is_child = false}) => {
  return items.map(item => {
    const field_props = {
      id: Math.random().toString(),
      body: item.name,
      name: item.name,
      type: item.type,
      required: item.required
    };
    const enums = item.enums || [];
    const items = item.items || [];
    const has_items = items?.length > 0;
    const has_enums = enums?.length > 0;
    const should_default_open = item.defaultOpen || false;
    const render_child_item = () => {
      const child_props = {
        title: has_enums ? "Possible enum values" : "properties"
      };
      if (should_default_open) child_props.defaultOpen = true;
      const has_inline_enums = has_enums && enums.every(enum_item => typeof enum_item === 'string') && enums.map((enum_item, idx) => {
        const is_last = idx === enums.length - 1;
        const is_2nd_to_last = idx === enums.length - 2;
        return <>
            <code>{enum_item}</code>
            {is_last && ''}
            {is_2nd_to_last && ' or '}
            {!is_last && !is_2nd_to_last && ', '}
          </>;
      });
      const enum_list = has_enums && !has_inline_enums && <Accordion {...child_props}>
          {enums.map((enum_item, index) => <div key={`enum-${index}`}>
              <code>{enum_item.name}</code>
              <br />
              <p>{enum_item.description}</p>
            </div>)}
        </Accordion>;
      const item_list = has_items && <Expandable {...child_props}>
          <ParamList items={items || []} is_child />
        </Expandable>;
      return <>
          <p>
            {item.description}
            {has_inline_enums && [has_inline_enums.length > 1 ? ' One of ' : ' Must be ', ...has_inline_enums]}
          </p>

          {enum_list}
          {item_list}
        </>;
    };
    return is_child ? <ResponseField {...field_props}>{render_child_item()}</ResponseField> : <ParamField {...field_props}>{render_child_item()}</ParamField>;
  });
};

A Reversal is automatically created to balance out funds for a Payment that was returned or could not be
completed.

The Payment's `reversal_id` contains the ID of its Reversal.

## Reversal Objects

<ParamList
  items={[
get_common_parameters('Reversal').id,
{
name: 'pmt_id',
type: 'string',
required: false,
description: 'The ID of the Payment being reversed.',
},
{
name: 'target_account',
type: 'string | null',
required: false,
description: (
  <>
    The ID of the Account that the Reversal sends funds to (<code>credit</code>)
    or pulls funds from (<code>debit</code>).
  </>
),
},
{
name: 'trace_id',
type: 'string | null',
required: false,
description: 'The ACH trace identifier for the Reversal, when available.',
},
{
name: 'direction',
type: 'enum',
required: false,
description: 'The direction of the Reversal.',
enums: [
  {
    name: 'credit',
    description: 'Funds are returned after a full or partial return by the biller.',
  },
  {
    name: 'debit',
    description: 'Funds are pulled back, for example when the source of the Payment failed after the destination was already paid.',
  },
],
},
{
name: 'description',
type: 'string | null',
required: false,
description: 'The description of the Reversal.',
},
{
name: 'amount',
type: 'number',
required: false,
description: (
  <>
    The Reversal amount, in cents. For a partial reversal, this is only the amount returned by the biller,
    and is less than the Payment's <code>amount</code>.
  </>
),
},
{
name: 'fee',
type: 'object | null',
required: false,
description: (
  <>
    Fee details refunded with the Reversal, if applicable. Always <code>null</code> for partial
    reversals, because fees are not refunded when a Payment is partially reversed.
  </>
),
items: [
  {
    name: 'fee.type',
    type: 'enum',
    required: false,
    description: 'The type of fee.',
    enums: [
      {
        name: 'total',
        description: 'A fee that represents the total fee amount.',
      },
    ],
  },
  {
    name: 'fee.amount',
    type: 'number',
    required: false,
    description: 'The fee amount, in cents.',
  },
],
},
get_common_parameters('Reversal').status([
{
  name: 'pending_approval',
  description: 'The Reversal requires approval before it is processed. Applies to debit reversals.',
},
{
  name: 'pending',
  description: 'The Reversal has been approved and is waiting to be sent.',
},
{
  name: 'processing',
  description: 'The Reversal has been sent and is in progress.',
},
{
  name: 'sent',
  description: 'The Reversal has completed.',
},
{
  name: 'failed',
  description: 'The Reversal failed. See `error`.',
},
{
  name: 'pending_settlement',
  description: 'A `debit` Reversal is waiting to be settled.',
},
]),
{
name: 'error',
type: 'object | null',
required: false,
description: (
  <>
    An object representing an error that occurred while processing this Reversal.
    See <a href="/2025-12-01/reference/errors/payment-reversal-errors#resource-errors">Payment Reversal errors</a>.
  </>
),
},
{
name: 'estimated_completion_date',
type: 'string | null',
required: false,
description: 'An estimated date, in ISO 8601 format (YYYY-MM-DD), on which the Reversal should complete.',
},
get_common_parameters('Reversal').created_at,
get_common_parameters('Reversal').updated_at,
]}
/>

## Webhooks

| Event | Description |
| - | - |
| `payment_reversal.create` | A Reversal was created, including a partial reversal. |
| `payment_reversal.update` | A Reversal's status changed. |
| `payment.update` | The Payment's status changed, for example to `partial_reversal_processing` or `partially_reversed`. |

<RequestExample>
  ```json THE REVERSAL OBJECT theme={null}
  {
    "id": "rvs_A6bmTtFmxQhGQ",
    "pmt_id": "pmt_RGACQH7XdfYhC",
    "target_account": "acc_1a9e1fbnJ1f3",
    "trace_id": null,
    "direction": "credit",
    "description": "RETRY PYMT",
    "amount": 2500,
    "fee": null,
    "status": "pending",
    "error": null,
    "estimated_completion_date": "2026-10-07",
    "created_at": "2026-10-02T15:00:00.000Z",
    "updated_at": "2026-10-02T15:00:00.000Z"
  }
  ```
</RequestExample>


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.