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:

Before you begin generating your API access keys:

  • Please make sure your business partners have already connected with a Walmart Data Ventures Account Manager and have submitted an onboarding request form.
  • If you've already onboarded to any of our API offerings (including Data Feeds, NRT, or DSC v1), you do not need to generate keys again - please reach out to a Walmart Data Ventures Account Manager to request your client Secret so you can begin generating Bearer Tokens.
  • You need to have access to a command line terminal.

Generating API Keys - Unix-Based Systems

Watch the video or continue reading below to generate your keys.

  1. Create a desktop folder, titled "RSA Keys" (optional)

  2. Right-click the folder to open your terminal/command line (optional)

  3. 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.

  4. 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.

  5. 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