Expand my Community achievements bar.

SOLVED

Deploying mesh backend project using app builder gives auth error

Avatar

Community Advisor and Adobe Champion

Hi Team,

 

I have created mesh project on local and its working fine. Then i have created project using aio app init and in actions folders added required files as i don't have UI only backend mesh action so i want to deploy this only.

I have used aio app deploy and it has deployed web and non-web actions like 

HeenaMadan_2-1745784053116.png

 

when u try to access 
-> https://xxx-poc-stage.adobeio-static.net/api/v1/web/<xy>/mesh then i says

curl -H "Authorization: Bearer Apikey" -H "x-gw-ims-org-id: @XX@AdobeOrg" https://xxx-poc-stage.adobeio-static.net/api/v1/web/project/mesh
{
"error": "request is invalid, reason: failed authorization. Please verify your token and organization id."
}

and for secured:

curl -H "Authorization: Bearer APikey" -H "x-gw-ims-org-id: @AdobeOrg" https://xx-poc-stage.adobeio-static.net/api/v1/web/project/__secured_mesh
{
"code": "8iPxEOyhU2lHIT7HhFC5DwZLkmXhxLpK",
"error": "The requested resource does not exist."
}

Manifest.yml:

packages:
project:
actions:
mesh:
function: actions/mesh/index.js
runtime: 'nodejs:18'
web: yes
annotations:
require-adobe-auth: false
inputs:
LOG_LEVEL: debug

 

Can anyone help here.. what i am missing as api key is already generated and using for auth.

TIA

 

 

1 Accepted Solution

Avatar

Correct answer by
Level 7

Hi @HeenaMadan ,

 

You may want to check the following points to help resolve the issues you're encountering:

 

  1. Double-check that the x-gw-ims-org-id header is correct, matching the Adobe Org ID for your project.
  2. Ensure that the API key (Authorization: Bearer Apikey) you're using has the necessary permissions to access the mesh actions and associated resources.
  3. Verify that the API key is correctly configured with the correct scope, ensuring it can interact with the mesh and any related Adobe services.
  4. Ensure that the action name in the URL (mesh) matches the name specified in your manifest.yml file. It seems like you are using mesh in the action definition, but ensure it's correctly mapped and deployed.
  5. Double-check the deployment process to make sure the resources have been properly deployed to the correct path in Adobe I/O.
  6. Check the action's availability after deployment to ensure it's accessible at the given endpoint.

View solution in original post

3 Replies

Avatar

Correct answer by
Level 7

Hi @HeenaMadan ,

 

You may want to check the following points to help resolve the issues you're encountering:

 

  1. Double-check that the x-gw-ims-org-id header is correct, matching the Adobe Org ID for your project.
  2. Ensure that the API key (Authorization: Bearer Apikey) you're using has the necessary permissions to access the mesh actions and associated resources.
  3. Verify that the API key is correctly configured with the correct scope, ensuring it can interact with the mesh and any related Adobe services.
  4. Ensure that the action name in the URL (mesh) matches the name specified in your manifest.yml file. It seems like you are using mesh in the action definition, but ensure it's correctly mapped and deployed.
  5. Double-check the deployment process to make sure the resources have been properly deployed to the correct path in Adobe I/O.
  6. Check the action's availability after deployment to ensure it's accessible at the given endpoint.

Avatar

Community Advisor

Hi @HeenaMadan ,

1. Authorization Header – Incorrect Token Type

You’re using:

-H "Authorization: Bearer Apikey"

Issue: Apikey is not a bearer token. This header expects a JWT or IMS access token, not an API Key.

Fix: Generate a valid Access Token using Adobe I/O CLI or JWT flow, and replace the placeholder:

-H "Authorization: Bearer <ACCESS_TOKEN>"

2. Org ID Format

You're using:

-H "x-gw-ims-org-id: @AdobeOrg"

Issue: The @AdobeOrg placeholder must be replaced with the actual IMS Org ID (something like ABCD123456789@AdobeOrg).

Fix: Use the real Org ID from your Adobe Developer Console project.

3. Check Manifest Configuration

Your manifest snippet looks correct:
Since require-adobe-auth: false is set, you shouldn't need authentication for basic testing (unless secured path is invoked).

4. Mismatch in Deployed URL vs Action Name

Double-check that the deployed action name in the URL exactly matches the action path:

https://<your-app>.adobeio-static.net/api/v1/web/<package-name>/<action-name>

From your manifest, the path should be:

/api/v1/web/project/mesh

So project is the package name and mesh is the action.

5. For Secured Endpoint (__secured_mesh)

The error:

"error": "The requested resource does not exist."

 

Means: Either the action __secured_mesh doesn’t exist or wasn't deployed correctly.

Fix: Ensure your manifest declares:

mesh:
  web: yes
__secured_mesh:
  web: yes
  annotations:
    require-adobe-auth: true

Suggested curl for Non-Secured Action

Try:

curl https://xxx-poc-stage.adobeio-static.net/api/v1/web/project/mesh
If you're still asked for a token despite require-adobe-auth: false, try deploying again with:
aio app deploy --force


Regards,
Amit

Avatar

Community Advisor and Adobe Champion

worked.. issue with my access only. Thanks everyone