WePay.accountDetails()

Look up the details of a payment account on WePay.

Look up the details of a payment account on WePay. The payment account must belong to the user associated with the access token used to make the call.

Usage

Hover over inputs/exits for more info.

var WePay = require('machinepack-wepay');


// Look up the details of a payment account on WePay.

WePay.accountDetails({

accessToken: '604f39f41e364951ced74070c6e8bfa49d346cdfee6191b03c2c2d9c9cda9184',

accountId: 12345,

useProduction: false,

}).exec({

// An unexpected error occurred.

error: function (err) {

 

},

// OK.

success: function (result) {

 

},

});

Inputs

accessToken required

The string access token of the user you want to create a payment account for.

'604f39f41e364951ced74070c6e8bfa49d346cdfee6191b03c2c2d9c9cda9184'
accountId required

The string access token of the user you want to create a payment account for.

12345
useProduction

Use WePay production API - payments will be charged. Defaults to WePay staging - payments are not charged.

false

Exits

error

An unexpected error occurred.

success

OK.

{ account_id: 12345,
  name: 'Example account',
  state: 'active',
  description: 'this account is just an example.',
  owner_user_id: 539291,
  reference_id: '123abc',
  type: 'personal',
  create_time: 1367958263,
  disablement_time: 'null',
  country: 'US',
  currencies: [ 'USD' ],
  balances: 
   [ { currency: 'USD',
       balance: 390.5,
       incoming_pending_amount: 635.3,
       outgoing_pending_amount: 210,
       reserved_amount: 0,
       disputed_amount: 0,
       withdrawal_period: 'daily',
       withdrawal_type: 'ach',
       withdrawal_next_time: 1370112217,
       withdrawal_bank_name: 'WellsFargo XXXXX3102' } ],
  statuses: 
   [ { currency: 'USD',
       incoming_payments_status: 'ok',
       outgoing_payments_status: 'ok',
       account_review_status: 'pending' } ],
  image_uri: 'https://stage.wepay.com/img/logo.png',
  action_reasons: [ 'bank_account', 'kyc' ],
  supported_card_types: 
   [ 'visa',
     'mastercard',
     'american_express',
     'discover',
     'jcb',
     'diners_club' ],
  disabled_reasons: 
   [ 'country_not_supported',
     'fraud',
     'high_risk_chargeback',
     'no_settlement_path',
     'reported_user',
     'tos_violation' ],
  fee_schedule: [ { slot: 9, description: '2.9% + $0.30', currency: 'USD' } ] }