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

# Same-Day ACH

> An overview of Same Day ACH and leveraging next-available processing times for faster transfers.

## Overview

Use the Dwolla API for faster payments to enable your application to take advantage of [Same Day ACH](https://www.dwolla.com/features/same-day-ach/) credit or debit transfers on a [per transfer request](/docs/api-reference/transfers/initiate-a-transfer) basis. A `clearing` request parameter is supplied in the request to the Dwolla API which tells Dwolla to expedite clearing for the source or the destination account involved in the transaction. Same Day ACH is a simple and powerful feature for platforms looking to differentiate themselves, streamline cash flows, and improve their end user experiences.

### Understanding Same Day ACH

Same Day ACH allows you to move money electronically within the **same business day** (excluding weekends and holidays). This is a significant improvement compared to standard ACH transfers that can take several days. The ACH network typically processes batches of transactions once or twice a day, resulting in clearing times of several business days. Same Day ACH builds upon this existing infrastructure by introducing additional processing windows throughout the day. This allows for funds to be received by the destination bank on the same business day that the transfer is initiated, provided it meets the specific deadline set by the originating financial institution.

#### Types of Same Day ACH transfers

* Same Day Debit: Move funds from a user's bank account into the Dwolla network.
* Same Day Credit: Move funds out of the Dwolla network to a user's bank account.

#### Benefits of Same Day ACH

* Faster payments: Funds are available in the recipient's account by the end of the **same business day** if initiated before the deadline.
* Improved user experience: Offer a faster and more modern payment option for your users.
* Stand out from the competition: Differentiate your platform by providing faster transactions.

#### Important Considerations

* Transaction limit: There's a [limit of \$1 million per transfer](https://www.dwolla.com/updates/same-day-ach-transaction-limits/), enforced by Nacha.
* Cost: Same Day ACH transfers are generally more expensive than standard ACH transfers.
* Risk and compliance: Using higher transaction limits and payment speeds might require additional review from Dwolla.

#### Deadlines and Availability

The table below shows the cut-off times (Central Time) for initiating Same Day ACH transfers and the corresponding estimated time when the funds will be available in the destination account. For example, your application can initiate a debit or credit transfer with Same Day clearing prior to 3 PM Central Time and funds will be available in the destination account by the end of the same business day. For more information on the timing of transactions, reference our resource article on [transaction timelines](https://www.dwolla.com/resources/understanding-payment-transfer-timelines/).

##### Deadlines and Availability

| Cut-off Time (Central Time) | Estimated Availability |
| :-------------------------: | :--------------------: |
|           9:00 AM           |        11:30 AM        |
|           1:00 PM           |         5:00 PM        |
|           3:00 PM           |         5:00 PM        |

### Creating a Customer and Attaching a Bank Account

Before you can initiate a debit or credit transfer using same-day clearing, you must first have a [Customer created](/docs/api-reference/customers/create-a-customer) and a [funding source](/docs/api-reference/funding-sources/create-customer-funding-source) attached for the user. If it’s a debit transfer, then the funding source must be `verified` before you can pull funds. For a credit transfer, the funding source can be `unverified` or `verified`.

Once your customer has connected a bank account and/or verified it, you'll then want to store the funding source id (e.g. `https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f`) which will be used when specifying the bank account as the either the source or destination href in the request to the [Transfers API](/docs/api-reference/transfers/initiate-a-transfer).

### Initiating a Same Day ACH Transfer

In order to initiate a transfer with Same Day ACH processing, an optional `clearing` JSON object must be included in the transfer request. The clearing object contains `source` and `destination` keys with respective values of `standard` or `next-available` and `next-available`.

Specifying the destination clearing as `next-available` will allow requests to default to the earliest available processing window based on the time submitted. In addition, transfers greater than `$1 million` will default to a processing window permitting larger amounts.

#### Initiating a Same Day Debit Transfer

The following example assumes the sending party has a verified funding source. We're receiving a pay-in from a Customer’s funding source to our Dwolla account balance, which represents the Dwolla Network.

<CodeGroup>
  ```bash HTTP theme={"dark"}
  POST https://api-sandbox.dwolla.com/transfers
  Accept: application/vnd.dwolla.v1.hal+json
  Content-Type: application/vnd.dwolla.v1.hal+json
  Authorization: Bearer pBA9fVDBEyYZCEsLf/wKehyh1RTpzjUj5KzIRfDi0wKTii7DqY
  Idempotency-Key: 19051a62-3403-11e6-ac61-9e71128cae77

  {
      "_links": {
          "source": {
              "href": "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7"
          },
          "destination": {
              "href": "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f"
          }
      },
      "amount": {
          "currency": "USD",
          "value": "10000.00"
      },
      "clearing": {
          "source": "next-available"
      }
  }

  ...

  HTTP/1.1 201 Created
  Location: https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388
  ```

  ```ruby initiate_transfer.rb theme={"dark"}
  request_body = {
    :_links => {
      :source => {
        :href => "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7"
      },
      :destination => {
        :href => "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f"
      }
    },
    :amount => {
      :currency => "USD",
      :value => "10000.00"
    },
    :clearing => {
      :source => "next-available"
    }
  }

  # Using DwollaV2 - https://github.com/Dwolla/dwolla-v2-ruby (Recommended)
  transfer = app_token.post "transfers", request_body
  transfer.response_headers[:location] # => "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388"
  ```

  ```php initiate_transfer.php theme={"dark"}
  <?php
  $transfersApi = new DwollaSwagger\TransfersApi($apiClient);

  $transfer = $transfersApi->create([
    '_links' => [
      'source' => [
        'href' => 'https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7',
      ],
      'destination' => [
        'href' => 'https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f'
      ]
    ],
    'amount' => [
      'currency' => 'USD',
      'value' => '10000.00'
    ],

    'clearing' => [
      'source' => 'next-available'
    ]
  ]);
  $transfer; # => "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388"
  ?>
  ```

  ```python initiate_transfer.py theme={"dark"}
  request_body = {
    '_links': {
      'source': {
        'href': 'https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7'
      },
      'destination': {
        'href': 'https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f'
      }
    },
    'amount': {
      'currency': 'USD',
      'value': '10000.00'
    },
    'clearing': {
      'source': 'next-available'
    }
  }

  # Using dwollav2 - https://github.com/Dwolla/dwolla-v2-python (Recommended)
  transfer = app_token.post('transfers', request_body)
  transfer.headers['location'] # => 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'
  ```

  ```javascript initiateTransfer.js theme={"dark"}
  var requestBody = {
    _links: {
      source: {
        href: "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7",
      },
      destination: {
        href: "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f",
      },
    },
    amount: {
      currency: "USD",
      value: "10000.00",
    },
    clearing: {
      source: "next-available",
    },
  };

  dwolla
    .post("transfers", requestBody)
    .then((res) => res.headers.get("location")); // => 'https://api.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'
  ```
</CodeGroup>

#### Initiating a Same Day Credit Transfer

The following example assumes the sending party has a verified account and a verified funding source. We're sending a payout from our Dwolla account balance to our Customer’s funding source which represents the receiving bank account.

<CodeGroup>
  ```bash HTTP theme={"dark"}
  POST https://api-sandbox.dwolla.com/transfers
  Accept: application/vnd.dwolla.v1.hal+json
  Content-Type: application/vnd.dwolla.v1.hal+json
  Authorization: Bearer pBA9fVDBEyYZCEsLf/wKehyh1RTpzjUj5KzIRfDi0wKTii7DqY
  Idempotency-Key: 19051a62-3403-11e6-ac61-9e71128cae77

  {
      "_links": {
          "source": {
              "href": "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7"
          },
          "destination": {
              "href": "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f"
          }
      },
      "amount": {
          "currency": "USD",
          "value": "10000.00"
      },
      "clearing": {
          "destination": "next-available"
      }
  }

  ...

  HTTP/1.1 201 Created
  Location: https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388
  ```

  ```ruby initiate_transfer.rb theme={"dark"}
  request_body = {
    :_links => {
      :source => {
        :href => "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7"
      },
      :destination => {
        :href => "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f"
      }
    },
    :amount => {
      :currency => "USD",
      :value => "10000.00"
    },
    :metadata => {
      :paymentId => "12345678",
      :note => "payment for completed work Dec. 1"
    },
    :clearing => {
      :destination => "next-available"
    }
  }

  # Using DwollaV2 - https://github.com/Dwolla/dwolla-v2-ruby (Recommended)
  transfer = app_token.post "transfers", request_body
  transfer.response_headers[:location] # => "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388"
  ```

  ```php initiate_transfer.php theme={"dark"}
  <?php
  $transfersApi = new DwollaSwagger\TransfersApi($apiClient);

  $transfer = $transfersApi->create([
    '_links' => [
      'source' => [
        'href' => 'https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7',
      ],
      'destination' => [
        'href' => 'https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f'
      ]
    ],
    'amount' => [
      'currency' => 'USD',
      'value' => '10000.00'
    ],

    'clearing' => [
      'destination' => 'next-available'
    ]
  ]);
  $transfer; # => "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388"
  ?>
  ```

  ```python initiate_transfer.py theme={"dark"}
  request_body = {
    '_links': {
      'source': {
        'href': 'https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7'
      },
      'destination': {
        'href': 'https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f'
      }
    },
    'amount': {
      'currency': 'USD',
      'value': '10000.00'
    },
    'clearing': {
      'destination': 'next-available'
    }
  }

  # Using dwollav2 - https://github.com/Dwolla/dwolla-v2-python (Recommended)
  transfer = app_token.post('transfers', request_body)
  transfer.headers['location'] # => 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'
  ```

  ```javascript theme={"dark"}
  var requestBody = {
    _links: {
      source: {
        href: "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7",
      },
      destination: {
        href: "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f",
      },
    },
    amount: {
      currency: "USD",
      value: "10000.00",
    },
    clearing: {
      destination: "next-available",
    },
  };

  dwolla
    .post("transfers", requestBody)
    .then((res) => res.headers.get("location")); // => 'https://api.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'
  ```
</CodeGroup>

### Retrieving a Transfer With Same Day Clearing

When retrieving the [transfer from the API](/docs/api-reference/transfers/retrieve-a-transfer), the response should contain the clearing object with a `source` or `destination` key and a value of either `same-day` or `next-day` depending on if the transfer was initiated prior to the last same day processing window and the transfer amount is less than `$1 million` (as mentioned above).

#### Retrieving a Same Day Debit Transfer

<CodeGroup>
  ```bash HTTP theme={"dark"}
  GET https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388
  Accept: application/vnd.dwolla.v1.hal+json
  Authorization: Bearer pBA9fVDBEyYZCEsLf/wKehyh1RTpzjUj5KzIRfDi0wKTii7DqY

  ...

  {
    "_links": {
      "source": {
        "href": "https://api-sandbox.dwolla.com/accounts/ad5f2162-404a-4c4c-994e-6ab6c3a13254",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "account"
      },
      "destination-funding-source": {
        "href": "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "funding-source"
      },
      "self": {
        "href": "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "transfer"
      },
      "funded-transfer": {
        "href": "https://api-sandbox.dwolla.com/transfers/646de847-7d02-e711-80ee-0aa34a9b2388",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "transfer"
      },
      "source-funding-source": {
        "href": "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "funding-source"
      },
      "destination": {
        "href": "https://api-sandbox.dwolla.com/customers/99dd22de-6ec6-4ba1-a0d1-09eb169a4bb1",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "customer"
      }
    },
    "id": "636de847-7d02-e711-80ee-0aa34a9b2388",
    "status": "processed",
    "amount": {
      "value": "10000.00",
      "currency": "usd"
    },
    "created": "2017-03-06T14:57:56.803Z",
    "clearing": {
      "source": "same-day"
    }
  }
  ```

  ```ruby retrieve_transfer.rb theme={"dark"}
  transfer_url = 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'

  # Using DwollaV2 - https://github.com/Dwolla/dwolla-v2-ruby (Recommended)
  transfer = app_token.get transfer_url
  transfer.status # => "processed"
  ```

  ```php retrieve_transfer.php theme={"dark"}
  <?php
  $transferUrl = 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388';

  $transfersApi = new DwollaSwagger\TransfersApi($apiClient);

  $transfer = $transfersApi->byId($transferUrl);
  $transfer->status; # => "processed"
  ?>
  ```

  ```python retrieve_transfer.py theme={"dark"}
  transfer_url = 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'

  # Using dwollav2 - https://github.com/Dwolla/dwolla-v2-python (Recommended)
  transfer = app_token.get(transfer_url)
  transfer.body['status'] # => 'processed'
  ```

  ```javascript retrieveTransfer.js theme={"dark"}
  var transferUrl =
    "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388";

  dwolla.get(transferUrl).then((res) => res.body.status); // => 'processed'
  ```
</CodeGroup>

#### Retrieving a Same Day Credit Transfer

<CodeGroup>
  ```bash HTTP theme={"dark"}
  GET https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388
  Accept: application/vnd.dwolla.v1.hal+json
  Authorization: Bearer pBA9fVDBEyYZCEsLf/wKehyh1RTpzjUj5KzIRfDi0wKTii7DqY

  ...

  {
    "_links": {
      "source": {
        "href": "https://api-sandbox.dwolla.com/accounts/ad5f2162-404a-4c4c-994e-6ab6c3a13254",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "account"
      },
      "destination-funding-source": {
        "href": "https://api-sandbox.dwolla.com/funding-sources/ecf993e2-fa22-4cea-8022-c7861200288f",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "funding-source"
      },
      "self": {
        "href": "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "transfer"
      },
      "funded-transfer": {
        "href": "https://api-sandbox.dwolla.com/transfers/646de847-7d02-e711-80ee-0aa34a9b2388",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "transfer"
      },
      "source-funding-source": {
        "href": "https://api-sandbox.dwolla.com/funding-sources/b268f6b9-db3b-4ecc-83a2-8823a53ec8b7",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "funding-source"
      },
      "destination": {
        "href": "https://api-sandbox.dwolla.com/customers/99dd22de-6ec6-4ba1-a0d1-09eb169a4bb1",
        "type": "application/vnd.dwolla.v1.hal+json",
        "resource-type": "customer"
      }
    },
    "id": "636de847-7d02-e711-80ee-0aa34a9b2388",
    "status": "processed",
    "amount": {
      "value": "10000.00",
      "currency": "usd"
    },
    "created": "2017-03-06T14:57:56.803Z",
    "clearing": {
      "destination": "same-day"
    }
  }
  ```

  ```ruby retrieve_transfer.rb theme={"dark"}
  transfer_url = 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'

  # Using DwollaV2 - https://github.com/Dwolla/dwolla-v2-ruby (Recommended)
  transfer = app_token.get transfer_url
  transfer.status # => "processed"
  ```

  ```php retrieve_transfer.php theme={"dark"}
  <?php
  $transferUrl = 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388';

  $transfersApi = new DwollaSwagger\TransfersApi($apiClient);

  $transfer = $transfersApi->byId($transferUrl);
  $transfer->status; # => "processed"
  ?>
  ```

  ```python retrieve_transfer.py theme={"dark"}
  transfer_url = 'https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388'

  # Using dwollav2 - https://github.com/Dwolla/dwolla-v2-python (Recommended)
  transfer = app_token.get(transfer_url)
  transfer.body['status'] # => 'processed'
  ```

  ```javascript retrieveTransfer.js theme={"dark"}
  var transferUrl =
    "https://api-sandbox.dwolla.com/transfers/636de847-7d02-e711-80ee-0aa34a9b2388";

  dwolla.get(transferUrl).then((res) => res.body.status); // => 'processed'
  ```
</CodeGroup>
