Skip to content
glorieux edited this page Jul 31, 2013 · 1 revision

The Wallet Object

Property Type More
Id Integer
Tag String
CreationDate Time
Owners Array
Description String < 200 chars
Balance Money Hash { Currency: 'EUR', Amount: 10 }
Currency String ISO (“EUR only for the moment”)

Creating a Wallet

Arguments

  • wallet: a Hash:

Returns

A Wallet Object

Example

MangoPay::Wallet.create({
  Owners: [43243, 654654, 654024],
  Description: 'A test wallet',
  Currency: 'EUR',
  Tag: 'Test Time'
})

Updating a Wallet

Arguments

  • wallet_id: the id of the hash you want to update
  • wallet: a Hash:
    • Description
    • Tag

Returns

A Wallet Object

Example

MangoPay::Wallet.update(new_wallet['Id'], {
  Description: 'Updated Description',
  Tag: 'Updated Tag'
})

Retrieving a Wallet

Arguments

  • wallet_id: the id of the wallet you want to retrieve

Returns

A Wallet Object

Example

MangoPay::Wallet.fetch(32132)

Clone this wiki locally