Show / Hide Table of Contents

Internal Transfers

Internal transfers are transactions that request the move of funds to one of the beneficiary accounts within the sytem.

Root endpoint

The original endpoint for OData queries for internal transfers requests is /api/v1/Transfers. While the endpoint remains to be used for POST requests (i.e. internal transfer creation, cancellation, approval, rejection), for queries it didn't provide the necessary distinction between inbound and outbound transfers. To retrieve outbound and inbound transfers lists and their details, the endpoints below were introduced.

Outbound Transfers

Outbound transfers of an account GET /api/v1/Accounts({accountId})/OutboundTransfers

Outbound transfer by id GET /api/v1/OutboundTransfers({id})

Fees for an outbound transfer GET /api/v1/OutboundTransfers({transferId})/Fees

Inbound Transfers

Inbound transfers of an account GET /api/v1/Accounts({accountId})/InboundTransfers

Inbound transfer by id GET /api/v1/InboundTransfers({id})

Fees for an inbound transfer GET /api/v1/InboundTransfers({transferId})/Fees

Transfer beneficiaries

The root endpoint for queries for transfers beneficiaries is /api/v1/Accounts({accountId})/TransferBeneficiaries

The list of all transfer beneficiaries available for the authorized user /api/v1/TransferBeneficiaries

Transfer beneficiary by id /api/v1/TransferBeneficiaries({id})

{
    "@odata.context": "http://portal.wearefreemarket.com/api/v1/$metadata#TransferBeneficiaries/$entity",
    "Id": 2414,
    "AccountId": 10100,
    "BeneficiaryAccountId": 112423,
    "Name": "Beneficiary2414",
    "CurrencyCode": "GBP",
    "StatusCode": "E",
    "Status": "Enabled"
  }

Internal transfer lifecycle

Approval Workflow

Creating an internal transfer

The basic request to create an internal transfer

POST /api/v1/Transfers/CreateAccountTransfer HTTP/1.1
Host: portal.wearefreemarket.com
Authorization: Bearer {authToken}
Content-Type: application/json

{
    "AccountId": {AccountId},
    "CurrencyCode": "GBP",
    "Amount": 1000.0,
    "BeneficiaryId": {BeneficiaryId},
    "Reference": "reference text"
  }
parameter description data type validation rules
AccountId The account id from which the transfer will be created int required
CurrencyCode The currency to be transfered string required
Amount The amount to be transfered decimal
BeneficiaryId The beneficiary id who will receive the funds int required
Reference The internal transfer reference, up to 35 characters string

Cancelling an internal transfer

POST /api/v1/Transfers/{transferId}/Cancel HTTP/1.1
Host: portal.wearefreemarket.com
Authorization: Bearer {authToken}

Approving an internal transfer

POST /api/v1/Transfers/{transferId}/Approve HTTP/1.1
Host: portal.wearefreemarket.com
Authorization: Bearer {authToken}

Rejecting an internal transfer

POST /api/v1/Transfers/{transferId}/Reject HTTP/1.1
Host: portal.wearefreemarket.com
Authorization: Bearer {authToken}

Webhook events

Transfer created

This event is raised when a new transfer has been created.

 [
    {
        "EntityType": "Transfer",
        "EntityId": 1234,
        "Reason": "TransferCreated",
        "ApiUrl": "https://portal.wearefreemarket.com/api/v1/OutboundTransfers(1234)"
    }
]

Transfer completed

This event is raised when a new transfer has been completed and funds have been transfered to the beneficiary.

 [
    {
        "EntityType": "Transfer",
        "EntityId": 1234,
        "Reason": "TransferCompleted",
        "ApiUrl": "https://portal.wearefreemarket.com/api/v1/OutboundTransfers(1234)"
    }
]

Incoming transfer completed

This event is raised on the beneficiary account once the transfer has been completed and funds have been transfered.

 [
    {
        "EntityType": "Transfer",
        "EntityId": 1234,
        "Reason": "IncomingTransferCompleted",
        "ApiUrl": "https://portal.wearefreemarket.com/api/v1/InboundTransfers(1234)"
    }
]

Transfer canceled

This event is raised when a transfer has been canceled and the allocated funds have been returned to your account.

 [
    {
        "EntityType": "Transfer",
        "EntityId": 1234,
        "Reason": "TransferCanceled",
        "ApiUrl": "https://portal.wearefreemarket.com/api/v1/OutboundTransfers(1234)"
    }
]
In this article
Back to top Generated by DocFX