sFOX API
Sign InOpen Account
Connect API
Connect API
  • Introduction
    • Welcome
    • Getting Started
    • Resources
      • Terminology
      • Systems & Operations
      • Integration Options
    • Guides
      • End User Onboarding & KYC
        • Individuals
        • Businesses
        • Enhanced Due Diligence
  • REST API
    • REST Endpoints
    • Authentication
    • End Users
      • Create End User Account
      • Request Verification Code
      • Confirm Verification Code
      • Create User Auth Token(s)
      • Get End User(s)
      • Get EDD Requests
      • Get EDD Prompts
      • Create EDD Responses
        • Uploading Files as Responses
      • Submit Documents
      • Deactivate User
    • Payments
      • Create Bank Account (Plaid)
      • Create Bank Account
      • Get Bank Account
      • Get Plaid Processors
      • Amend Plaid Processors
      • Verify Bank Account
      • Delete Bank Account
      • Get Wire Instructions
      • Get ACH Agreement Status
      • Request ACH Onboarding
      • Get ACH Deposit Limit
    • Withdrawals
      • Confirm Withdrawal
      • Resend Confirmation Code
      • Cancel Withdrawal
    • Transfers
      • Create Transfer
      • Confirm Transfer
      • Resend Confirmation Code
      • Cancel Transfer
      • Get Transfer Permissions
      • Get Transfer History
    • Monetization
      • Create Setting
      • Update Setting
      • Delete Setting
      • Get Settings
      • Get Permissions
      • Get Monetization History
  • WebSocket API
    • Connecting
    • Authentication
    • Subscribing & Unsubscribing
    • Message Format
    • End Users
      • Onboarding
      • Balances
      • Orders
      • Trades
    • Market Data
      • Order Book
      • Trades
      • Ticker
  • Single Sign-On
    • Overview
      • IdP Initiated SSO
    • IdP Data
    • SAML Response Data
  • Errors
    • Error Codes
Powered by GitBook
On this page
  • Request
  • Body Parameters
  • Example Requests
  • Response
  • Response Body
  • Responses
  1. REST API
  2. Payments

Create Bank Account (Plaid)

PreviousPaymentsNextCreate Bank Account

Last updated 1 day ago

POST

https://api.sfox.com/v1/bank-account/plaid-processors

sFOX and Plaid have partnered to enable end users to instantly link and verify a bank account. sFOX will use the Plaid processor_token provided to securely retrieve bank account details from Plaid and enable ACH transfers.


Sandbox Only

Please note that this endpoint is currently only available for testing in the Sandbox environment and may undergo changes as we continue to improve the feature.

Request

  • Requires a for authentication. Requests attempted using an Connect API Key will result in an error.

  • There is a limit of one linked bank account per sFOX account. If you would like to link a different bank account, you must first .

Body Parameters

Name
Type
Description

data required

[object]

The Plaid processor_tokens and associated processors

processor required

string

The processor associated with this token. Possible values: sfox, dwolla

token required

string

The processor_token retrieved from Plaid.

Example Requests

#sFOX & Dwolla p-token: Link bank account and enable ACH transfers
curl -X POST 'https://api.sfox.com/v1/bank-accounts/plaid-processors' \
  -H 'Content-type: application/json' \
  -H "Authorization: Bearer ${USER_AUTH_TOKEN}" \
  -d '{ 
      "data": [
        {
          "processor": "sfox",
          "token": "${SFOX_PLAID_PROCESSOR_TOKEN}"
        },
        {
          "processor": "dwolla",
          "token": "${DWOLLA_PLAID_PROCESSOR_TOKEN}"
        }
      ]
   }'

#sFOX p-token only: Links bank account, does not enable ACH transfers
curl -X POST 'https://api.sfox.com/v1/bank-accounts/plaid-processors' \
  -H 'Content-type: application/json' \
  -H "Authorization: Bearer ${USER_AUTH_TOKEN}" \
  -d '{ 
      "data": [{
        "processor": "sfox",
        "token": "${SFOX_PLAID_PROCESSOR_TOKEN}"
      }]
   }'
//sFOX & Dwolla p-token: Link bank account and enable ACH transfers
const axios = require('axios');

const payload = JSON.stringify({
    "data": [
      {
        "processor": "sfox",
        "token": "${SFOX_PLAID_PROCESSOR_TOKEN}"
      },
      {
        "processor": "dwolla",
        "token": "${DWOLLA_PLAID_PROCESSOR_TOKEN}"
      }
    ]
})

const config = {
  method: 'post',
  url: 'https://api.sfox.com/v1/bank-accounts/plaid-processors',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': `Bearer ${process.env.USER_AUTH_TOKEN}`
  },
  data: data
}

axios(config)
  .then(response => {
    console.log(response.status)
    console.log(response.data)
  }).catch(err => {
    console.error(err.response.status)
    console.error(err.response.data)
  });


  
//sFOX p-token only: Links bank account, does not enable ACH transfers
const axios = require('axios');

const payload = JSON.stringify({
    "data": [
      {
        "processor": "sfox",
        "token": "${SFOX_PLAID_PROCESSOR_TOKEN}"
      }
    ]
})

const config = {
  method: 'post',
  url: 'https://api.sfox.com/v1/bank-accounts/plaid-processors',
  headers: {
    'Content-Type': 'application/json',
    'Authorization': `Bearer ${process.env.USER_AUTH_TOKEN}`
  },
  data: data
}

axios(config)
  .then(response => {
    console.log(response.status)
    console.log(response.data)
  }).catch(err => {
    console.error(err.response.status)
    console.error(err.response.data)
  });
#sFOX & Dwolla p-token: Link bank account and enable ACH transfers
import requests
import os

data = requests.post(
  "https://api.sfox.com/v1/bank-accounts/plaid-processors",
  headers={
    "Authorization": f"Bearer {os.environ['USER_AUTH_TOKEN']}"
  },
  json={
    "data": [
      {
        "processor": "sfox",
        "token": "SFOX_PLAID_PROCESSOR_TOKEN"
      },
      {
        "processor": "dwolla",
        "token": "DWOLLA_PLAID_PROCESSOR_TOKEN"
      }      
    ]
  }
)
print(data.status_code)
print(data.json())



#sFOX p-token only: Links bank account, does not enable ACH transfers
import requests
import os

data = requests.post(
  "https://api.sfox.com/v1/bank-accounts/plaid-processors",
  headers={
    "Authorization": f"Bearer {os.environ['USER_AUTH_TOKEN']}"
  },
  json={
    "data": [
      {
        "processor": "sfox",
        "token": "PLAID_PROCESSOR_TOKEN"
      }
    ]
  }
)
print(data.status_code)
print(data.json())

Response

Response Body

Name
Type
Description

data

[object]

The Plaid processor_tokens and associated processors

processor

string

The processor associated with the token that was processed. Possible values: sfox, dwolla

status

string

The status of processing the token.

bank_account_id

string

date_added

string

Date-time the token was added.

date_updated

string

Date-time the token was last updated.

Responses

201: Created

sFOX and Dwolla p-tokens processed successfully

{
    "data": [
        {
            "processor": "sfox",
            "status": "created",
            "bank_account_id": "05a59670-e7c2-4611-a356-d20cae93e939",
            "date_added": "2025-05-14T01:55:35.664Z",
            "date_updated": "2025-05-14T01:55:35.664Z"
        },
        {
            "processor": "dwolla",
            "status": "created",
            "bank_account_id": "05a59670-e7c2-4611-a356-d20cae93e939",
            "date_added": "2025-05-14T01:55:38.786Z",
            "date_updated": "2025-05-14T01:55:38.786Z"
        }
    ]
}

sFOX p-token successfully processed

{
    "data": [
        {
            "processor": "sfox",
            "status": "created",
            "bank_account_id": "05a59670-e7c2-4611-a356-d20cae93e939",
            "date_added": "2025-05-14T01:55:35.664Z",
            "date_updated": "2025-05-14T01:55:35.664Z"
        }
    ]
}
422: Unprocessable Entity
{
    "error": "could not process your sfox processor token: This account already has a bank account linked to it that is active"
}

sFOX p-token not included in a request with a Dwolla p-token.

{
    "error": "At least one sfox processor token is required if a dwolla processor token is given"
}

The ID of the associated bank account. (id from )

Active bank account is linked to this end user's account. To link a new bank account, and try again.

User Auth Token
disconnect the currently linked bank
remove the current bank account
Get Bank Account