Skip to main content

Retrieve an Exchange Resource

This section shows you how to retrieve an exchange resource.

HTTP request

GET https://api.dwolla.com/exchanges/{id}

Request parameters

ParameterRequiredTypeDescription
idyesstringExchange resource unique identifier.

HTTP status and error codes

HTTP StatusCodeDescription
200OkThe Dwolla API accepted the request and returned a response.
401InvalidScopeThe scopes for retrieving an exchange resource is not enabled for this application. Reach out to Dwolla for more information.
404NotFoundThe requested resource was not found. Check Exchange ID.

Request and response

GET https://api.dwolla.com/exchanges/fcd15e5f-8d13-4570-a9b7-7fb49e55941d
Accept: application/vnd.dwolla.v1.hal+json
Authorization: Bearer pBA9fVDBEyYZCEsLf/wKehyh1RTpzjUj5KzIRfDi0wKTii7DqY

...

{
    "_links": {
        "self": {
            "href": "https://api.dwolla.com/exchanges/e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a",
            "type": "application/vnd.dwolla.v1.hal+json",
            "resource-type": "exchange"
        },
        "exchange-partner": {
            "href": "https://api.dwolla.com/exchange-partners/9b55a4b3-34ae-4607-b2d1-622f1eed77f9",
            "type": "application/vnd.dwolla.v1.hal+json",
            "resource-type": "exchange-partner"
        },
        "external-party": {
            "href": "https://api-sandbox.dwolla.com/external-parties/c604420d-5b36-407c-ab37-097a1066e1b2",
            "type": "application/vnd.dwolla.v1.hal+json",
            "resource-type": "customer"
        }
    },
    "id": "e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a",
    "status": "active",
    "created": "2022-10-21T21:41:03.283Z"
}
# Using dwolla_v2 - https://github.com/Dwolla/dwolla-v2-ruby
exchange_url = 'https://api.dwolla.com/exchanges/e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a'

exchange = app_token.get exchange_url
exchange.id # => "e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a"
<?php
// Using dwollaswagger - https://github.com/Dwolla/dwolla-swagger-php
$exchangesApi = new ExchangesApi($apiClient);
$exchangeUrl = "https://api.dwolla.com/exchanges/e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a";

$exchange = $exchangesApi->id($exchangeUrl);
$exchange->id; # => "e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a"
?>
# Using dwollav2 - https://github.com/Dwolla/dwolla-v2-python
exchangeurl = 'https://api.dwolla.com/exchanges/e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a'

exchange = app_token.get(exchange_url)
exchange.body['id'] # => 'e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a'
// Using dwolla-v2 - https://github.com/Dwolla/dwolla-v2-node
var exchangeUrl =
  "https://api.dwolla.com/exchanges/e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a";

dwolla.get(exchangeUrl).then((res) => res.body.id); // => "e5e9f2d3-a96c-4abd-a097-8ec7ae28aa8a"