OIDC implementation in APIGEE X

devrel/references/oidc-mock at main · apigee/devrel · GitHub  trying to download this code getting error- 

export PATH="$PATH:/home/priya_dwivedi/devrel/references/oidc-mock"priya_dwivedi@cloudshell:~/devrel/tools/apigee-sackmesser (z-sbx-agile-playground)$ sackmesser deploy --apigeeapi -o "$APIGEE_ORG" -e "$APIGEE_ENV" -u "$APIGEE_USER" -p "$APIGEE_PASS"
curl: (22) The requested URL returned error: 401 Unauthorized

 

need guidance how I can implement authorization by ODIC(OKTA) in APIGEE X.

0 1 212
1 REPLY 1

I'm sorry to hear you're having trouble.

A 401 response indicates the Apigee management server rejects the call as unauthorized. This can occur for a number of reasons, among them: 

  • you've not specified an organization name after the -o option, or you've specified an incorrect organization name.
  • you've not specified a valid apigee user after -u
  • you've not specified a valid password for that apigee user with the -p option
  • your organization is set up to required multifactor authentication, or SAML signin. 

What troubleshooting or diagnostic efforts have you performed yourself?

  1. Have you verified that you have all the required environmnet variables set? This includes APIGEE_ORG, APIGEE_ENV, APIGEE_USER, APIGEE_PASS.
  2. Can you independently verify that you have access to your Apigee organization using curl, by invoking curl -i  -u $APIGEE_USER https://api.enterprise.apigee.com/v1/o/ORG_NAME ?  Does that succeed? 

Before you can get started playing around with the OIDC mock, you need to insure you have administrative access to the Apigee management API.