Getting Started
If you are looking for a quick and easy way to get started with our APIs with no additional code, this is the place for you.
Follow these steps to get up and running quickly with the APIs:
- Sign up with Mastercard Developers
- Follow the Quick Start Guide to get your project setup and get access to your API keys
Fork the collection of your choice with the environment
**Mastercard API Sandbox Environment
** into your own Qodex workspace.Open the Environments tab and choose Mastercard API Sandbox Environment as the environment
Go to your Mastercard Developers Project Dashboard and copy the consumer key into the the consumerKey variable
The private key is a little trickier. We need to convert the P12 key into an RSA key. To do that, first download the P12 key file
Then convert the P12 key into an RSA key using the following command:
openssl pkcs12 -in 'mykey.p12' | openssl rsa -out myrsa.key
If the openssl command isn't recognised, you can download the toolkit from hereWhen prompted, use the password/passphrase you configured when you first created the key
Now you can open the
myrsa.key
file you just created and copy the entire string value into the privateKey variable.These keys are picked up through the {{privateKey}} and {{consumerKey}} variables in the Authorisation tab for each Collection which has already been configured to use OAuth 1.0
Make sure you set the Environment before you start calling the API endpoints in the collections