Unix-Based Systems
Our APIs are deployed in isolated Sandbox and Production environments. Charter Supplier onboarding onto these environments requires authentication with the Walmart API Proxy/Gateway before initiating an API call. The first step to authenticating your access is generating your access keys.
Before you begin:
Please sure your business partners have already connected with a Walmart Data Ventures Account Manager.
Before you begin generating your API access keys, you need to have access to a command line terminal.
Generating API Keys - Unix-Based Systems
Complete the steps below to generate your public key.
-
Create a desktop folder, titled "RSA Keys" (optional)
-
Right-click the folder to open your terminal/command line (optional)
-
From command line, you will generate an RSA key-pair:
-
Paste the following command into the terminal and hit enter.
$ openssl genrsa -des3 -out my_rsa_key_pair 2048
-
Using -des3 ensures that the pem file generated in the above step will be passphrase protected. You will be prompted for the passphrase. The passphrase will be located directly above the prompt in the terminal. In the example below, 65537 is the passphrase:
Example:
e is 65537 (0x010001) Enter pass phrase for my_rsa_key_pair:
Note: Please note this passphrase in a safe location. You will use it again.
-
Type the passphrase into the terminal where prompted (note that while entering the passphrase, it will not look like you are actually typing) and hit enter.
-
You may be prompted to enter the passphrase twice.
-
-
Next, you will export the private key in the private_key.pem file:
-
Paste the following command into the terminal and hit enter.
$ openssl pkcs8 -topk8 -inform PEM -in my_rsa_key_pair -outform PEM -out private_key.pem -nocrypt
-
Type the same passphrase as before into the terminal where prompted (note that while entering the passphrase, it will not look like you are actually typing) and hit enter.
Note: Keep your private key secure. You will not share your private key.
-
-
Finally, you will export the public key in the public_key.pem file:
-
Paste the following command into the terminal and hit enter.
$ openssl rsa -in my_rsa_key_pair -outform PEM -pubout -out public_key.pem
-
Type the same passphrase as before into the terminal where prompted (note that while entering the passphrase, it will not look like you are actually typing) and hit enter.
-
What Happens Next
You should now have three files in the folder you created (or your chosen location): my_rsa_key_pair, public_key.pem, and private_key.pem.
If you are requesting access to multiple environments, remember to repeat the above steps for each environment you are requesting.
Once you have your key(s), you will be able to move on to Step 2.
©️Walmart | All Rights Reserved
Updated 7 months ago