Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Added option to set LIVE or TEST API mode
- Added examples for create order, update order, retreive order and retrive gateway(s) - Changed code in gateways.py
- Loading branch information
Showing
7 changed files
with
68 additions
and
22 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
from multisafepay.client import Client | ||
|
||
msp_client = Client() | ||
# Here you can set the mode to TEST or LIVE based on the API you want to use | ||
msp_client.set_modus('TEST') | ||
msp_client.set_api_key('REPLACE WITH API KEY') | ||
|
||
print(msp_client.order.get(51)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
from multisafepay.client import Client | ||
|
||
msp_client = Client() | ||
# Here you can set the mode to TEST or LIVE based on the API you want to use | ||
msp_client.set_modus('TEST') | ||
msp_client.set_api_key('REPLACE WITH API KEY') | ||
|
||
# To retrieve all the gateways you can use the following | ||
print(msp_client.gateways.allgateways()) | ||
# To use filters use the following code | ||
print(msp_client.gateways.allgateways('?country=BE¤cy=EUR&amount=10000')) | ||
# To retrieve information about one gateway use the following | ||
print(msp_client.gateways.gateway('IDEAL')) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
from multisafepay.client import Client | ||
|
||
msp_client = Client() | ||
# Here you can set the mode to TEST or LIVE based on the API you want to use | ||
msp_client.set_modus('TEST') | ||
msp_client.set_api_key('REPLACE WITH API KEY') | ||
|
||
# to update a existing order use the following example | ||
print(msp_client.order.update(49, { | ||
"status":"shipped", | ||
"tracktrace_code":"3SMSP0123456789", | ||
"carrier":"MSP Logistics", | ||
"ship_date":"01-01-1911", | ||
"reason":"Fulfilled by warehouse", | ||
"invoice_id":"AB12345" | ||
})) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters