Attempting To Create AEM Folder Gives 409 | Community
Skip to main content
April 17, 2025

Attempting To Create AEM Folder Gives 409

  • April 17, 2025
  • 3 replies
  • 1247 views

I am attempting to create a new folder in the AEM cloud utilizing the assets/api. This is my payload

https://author-<author>.adobeaemcloud.com/api/assets/parentPath/*

 

Headers

Content-Type=application/x-www-form-urlencoded

Authorization=Bearer <token>

 

Request

name=test-folder

jcr:title=test-folder

class=assetFolder

 

When I run this, I get this error 

 

{ "class": [ "core/response" ], "properties": { "path": "/api/assets/parent/*", "parentLocation": "/api/assets/parent.json", "referer": "", "changes": [], "location": "/api/assets/parent/*.json", "status.message": "Resource /api/assets/parent/* already exist.", "status.code": 409 } }

 

I have also tried the json request utilizing https://author-<author>.adobeaemcloud.com/api/assets/parentPath/test-folder, which gives me a 200 OK message, but does not give me the 201 created message, and the "changes" field is still empty. Any help would be great. Thank you! 

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.

3 replies

SantoshSai
Community Advisor
Community Advisor
April 17, 2025

Hi @coltsm,

I think the error you're getting is because you're trying to create a folder using an invalid path - the * in the URL (/api/assets/parentPath/*) isn’t allowed, and it's probably treating it like the folder already exists. Have you tried without *?

Try to use the actual parent folder path where you want to create your new folder. For example, if you want to create the folder under /content/dam, your request should look like this:

URL: https://author-<author>.adobeaemcloud.com/api/assets/content/dam


Headers:

  • Content-Type: application/json

  • Authorization: Bearer <your_token>

Body:

{
  "name": "test-folder",
  "jcr:title": "test-folder",
  "class": "assetFolder"
}

Also, make sure the folder doesn’t already exist - if it does, you'll get a 409 Conflict. Try using a different folder name to test.

Hope that helps!

Regards,
Santosh

Santosh Sai
ColtSmAuthor
April 17, 2025

Hi @santoshsai,

 

Thanks for getting back to me on this. When I use /api/assets/content/dam I get a path not found error, which implies there is no /api/assets/content/dam. When I try to POST to /api/assets/<myparent>, using the credentials it should create a new folder under the <myparent> directory, correct? Or should I be trying to POST to /api/assets/<myparent>/test-folder? Either way it does not work, as the former returns a 409 conflict, as I showed before (saying that /api/assets/<myparent> already exists), and the latter returns a 200 with no changes, rather than a 201 created.  

sarav_prakash
Community Advisor
Community Advisor
April 18, 2025

Hi @coltsm ,

Here is an example curl 

curl --location 'https://author-**-**.adobeaemcloud.com/api/assets/web/myfoldername/*' \ --header 'Authorization: **' \ --header 'Content-Type: application/json' \ --data '{"properties":{"name":"newfolder","jcr:title":"jcrtitle"}}'

This will create a folder at `/content/dam/web/myfoldername/newfolder` Make sure its POST request. This should work like this 

 

 

ColtSmAuthor
April 18, 2025

Hi @sarav_prakash,

 

Thank you for reaching out. Using this request still gives me the 409 error. My company does not use /assets/api/web, so that returned a "parent not found". Using the path to our parent folder, which is at /assets/api/<folder>/, this is what my request returned. 

 

 

sarav_prakash
Community Advisor
Community Advisor
April 18, 2025

Yes, I am sure. Here is my payload with a different name 

 

 

you can see that the path that it is saying "already exists" is /api/assets/parent/*.json. It seems to be trying to create a folder called *.json, instead of the folder in my request. 


I see. This is weird, some job/launcher/listener, something is racing ahead of  your Assets API. This is this not OOTB. You may need to try under different root like /content/dam/new. Or try to spin new RDE/local environment, donot deploy any custom code and try Assets API. On vanilla instance, Assets API works.

 

Alternate, if assets API is troubling, AEM is moving to OpenAPI. You can this experimental API. 

https://developer.adobe.com/experience-cloud/experience-manager-apis/api/experimental/folders/

 Longterm, OpenAPI will takeover. Request looks like this 

No hassle of splitting parent folder and child folder in path and body. 

 

kautuk_sahni
Community Manager
Community Manager
June 26, 2025

@coltsm Just checking in — were you able to resolve your issue?
We’d love to hear how things worked out. If the suggestions above helped, marking a response as correct can guide others with similar questions. And if you found another solution, feel free to share it — your insights could really benefit the community. Thanks again for being part of the conversation!

Kautuk Sahni
ColtSmAuthor
June 26, 2025

Hi Kautuk, 

 

No, unfortunately this issue was not resolved, even after opening a ticket directly with adobe through my company. We decided to switch software as the API for cloud did not work, in addition to other limitations of AEMaaCS. Thank you for your help, though!