Stripe.listSources()

List all payment sources for a customer.

Usage

Hover over inputs/exits for more info.

var Stripe = require('machinepack-stripe');


// List all payment sources for a customer.

Stripe.listSources({

customer: 'cus_4kmLwU2PvQBeqq',

: ,

}).exec({

// An unexpected error occurred.

error: function (err) {

 

},

// OK.

success: function (result) {

 

},

});

Inputs

customer required

The Stripe ID of the customer whose sources will be listed.

'cus_4kmLwU2PvQBeqq'
undefined

Exits

error

An unexpected error occurred.

success

OK.

{
  object: 'list',
  url: '/v1/customers/cu_14YepJ2eZvKYlo2CUJrwelj2/sources',
  has_more: false,
  data: [
    {
      id: 'ba_18k5KBAE8iIXJx4mnWV35Rnl',
      object: 'bank_account or card or bitcoin_receiver',
      address_city: '',
      address_country: '',
      address_line1: '',
      address_line1_check: '',
      address_line2: '',
      address_state: '',
      address_zip: '',
      address_zip_check: '',
      brand: 'Visa',
      country: 'US',
      customer: '',
      cvc_check: '',
      dynamic_last4: '',
      exp_month: 8,
      exp_year: 2017,
      funding: 'credit',
      last4: '4242',
      name: '',
      tokenization_method: '',
      account: 'acct_18epKhAE8iIXJx4m',
      account_holder_name: 'Jane Austen',
      account_holder_type: 'individual',
      bank_name: 'STRIPE TEST BANK',
      currency: 'usd',
      default_for_currency: false,
      fingerprint: 'rNUOheo5Mxi8lCO6',
      routing_number: '110000000',
      status: 'new',
      active: false,
      amount: 100,
      amount_received: 0,
      bitcoin_amount: 1757908,
      bitcoin_amount_received: 0,
      bitcoin_uri: 'bitcoin:test_7i9Fo4b5wXcUAuoVBFrc7nc9HDxD1?amount=0.01757908',
      created: 1471583627,
      description: 'Receiver for John Doe',
      email: '[email protected]',
      filled: false,
      inbound_address: 'test_7i9Fo4b5wXcUAuoVBFrc7nc9HDxD1',
      livemode: false,
      metadata: {},
      refund_address: '',
      uncaptured_funds: false,
      used_for_payment: false
    }
  ]
}