Hi @veerawong
Please see my example, use that as basis and extend it with whatever you require for your script. The example already shows the usage of new Mollie_API_Client
https://gist.github.com/davdebcom/8e5c39c30f87b2a77a18b2644d893365
The API key is stored as a WordPress option. So you could also get it directly with ID mollie-payments-for-woocommerce_live_api_key or mollie-payments-for-woocommerce_test_api_key.
If you need more details, check out these files:
mollie-payments-for-woocommerce/includes/mollie/wc/gateway/abstract.php
mollie-payments-for-woocommerce/includes/mollie/wc/helper/settings.php
Kind regards
David