On Monday, June 13, 2016 at 12:54:45 PM UTC+2, Arshpreet Singh wrote:
> I have to pass dictionary as function argument for following code:
>
>
> import authorize
>
> authorize.Configuration.configure(
> authorize.Environment.TEST,
> 'api_login_id',
> 'api_transaction_key',
> )
>
> r
"Arshpreet Singh" wrote in message
news:0b6372ce-3f16-431b-9e72-42d5c935d...@googlegroups.com...
I have to pass dictionary as function argument for following code:
[...]
result = authorize.Transaction.sale({
'amount': 40.00,
'credit_card': {
'card_number': '411
To be equivalent to the other one it should be:
result = authorize.Transaction.sale({'amount': 40.00, 'credit_card':
credit_card})
In this line:
result = authorize.Transaction.sale({40.00,credit_card})
You are not putting keys in the dictionary. If there are no keys Python
creates a 'set literal