In the /setup directory, locate the file setenv.sh. Edit this file to set your organization, the email address associated with your username, and the environment (prod or test) where you want to deploy the API proxies.

After you edit setenv.sh, run:

$ sh deploy_all.sh

This script deploys all API proxy samples to your organization. (The process takes 3-4 minutes.) Follow prompts to deploy API products, developers, and apps (which are used for OAuth).

After the deploy script completes, navigate to the sample-proxies directory. In the directory sample-proxies, you will find one directory per sample proxy. In each directory is a README.md file with information about running the sample, and two scripts that help you as you make small changes to the samples, deploy, and then invoke the sample to see what effect you change had:

invoke.sh: Run this script to invoke the deployed version of the API proxy.

deploy.sh: Run this script to deploy the API proxy after you make any changes.

Try the apikey sample. This sample shows how to perform a simple "API key" style of API security using Apigee. Change to the sample-proxies/apikey directory:

$ cd sample-proxies/apikey

Invoke the sample:

$ sh invoke.sh

You will be prompted to enter your password. The sample then displays information about the app used to make requests to the API, displays the API key used to access the API, makes a request to the API using the key, and then makes a request using an invalid key.