% if mode == 'definition': Balanced::Order.save % elif mode == 'request': require 'balanced' Balanced.configure('ak-test-22IOkhevjZlmRP2do6CZixkkDshTiOjTV') order = Balanced::Order.fetch('/orders/OR6d55qbtKx5aWSURkQeodRr') order.description = 'New description for order' order.meta = { 'anykey' => 'valuegoeshere', 'product.id' => '1234567890' } order.save % elif mode == 'response': #0, "amount_escrowed"=>0, "created_at"=>"2014-04-25T20:18:43.120760Z", "currency"=>"USD", "delivery_address"=> {"city"=>nil, "country_code"=>nil, "line1"=>nil, "line2"=>nil, "postal_code"=>nil, "state"=>nil}, "description"=>"New description for order", "href"=>"/orders/OR6d55qbtKx5aWSURkQeodRr", "id"=>"OR6d55qbtKx5aWSURkQeodRr", "links"=>{"merchant"=>"CU4MnFEab304anOtUtEu5hkN"}, "meta"=>{"anykey"=>"valuegoeshere", "product.id"=>"1234567890"}, "updated_at"=>"2014-04-25T20:18:46.797463Z"}, @hyperlinks= {"buyers"=> #, "credits"=> #, "debits"=> #, "merchant"=> #, "refunds"=> #, "reversals"=> #}> % endif