asset-manager

Migrate AssetManager create and delete APIs to AEM Cloud Service patterns.

1|Updated Jun 22, 2026
Ready to run
npx skills add https://github.com/aemgdc/aemdev --skill asset-manager-aemgdc
💬 Prompt for ChatGPT / Claude Chat▼
Please help me install this Agent Skill.
Skill: asset-manager
Source: https://github.com/aemgdc/aemdev/tree/main/.agents/skills/asset-manager
Command: npx skills add https://github.com/aemgdc/aemdev --skill asset-manager-aemgdc

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @adobe/aem-upload, axios, and includes references (resource) components.

What problem does it solve? Legacy AEM code using AssetManager binary-path APIs (createAssetForBinary, getAssetForBinary, removeAssetForBinary) breaks on AEM as a Cloud Service because those APIs no longer exist, and client-facing upload servlets violate the cloud runtime's Direct Binary Access model. ## Core Features & Use Cases - Path A migration (create/upload): Replaces removed createAssetForBinary/getAssetForBinary calls and client-facing upload servlets with Direct Binary Access via @adobe/aem-upload and the HTTP Assets API. - Path B migration (delete): Replaces removeAssetForBinary with in-JVM resolver.delete() plus commit using a service-user resolver, or external HTTP Assets API DELETE calls authenticated with IMS bearer tokens. - Governance and setup: Covers Repoinit service-user creation, ServiceUserMapperImpl.amended mapping, SCR-to-DS annotation conversion, SLF4J logging, and a full review checklist. - Use Case: A team migrating a legacy AEM 6.5 codebase to AEMaaCS finds servlets calling removeAssetForBinary; this Skill rewrites them to use a service-user ResourceResolver with idempotent deletes and proper jcr:removeNode permissions. ## Quick Start Ask the assistant to migrate this legacy servlet that uses AssetManager.removeAssetForBinary to an AEM Cloud Service compatible implementation.

Frequently Asked Questions about asset-manager

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I migrate AssetManager.createAssetForBinary to AEM Cloud Service?▼

Replace createAssetForBinary with Direct Binary Access using the @adobe/aem-upload JavaScript SDK, which uploads bytes directly between the client and Adobe's binary store. The AEM JVM orchestrates the upload via the HTTP Assets API but never carries the binary.

How do I delete assets programmatically on AEM as a Cloud Service?▼

In-JVM code should use a service-user ResourceResolver with resolver.delete(resource) followed by resolver.commit(). External callers use the HTTP Assets API DELETE /api/assets{path} with an IMS bearer token from Adobe Developer Console.

Is AssetManager.createAsset still supported on AEMaaCS?▼

Yes, createAsset(path, InputStream, mimeType, doSave) still works for in-JVM utilities where the binary is small and already in the JVM, such as bundled resources or fixtures. Client-facing uploads must use Direct Binary Access instead.

Why does resolver.commit() throw AccessDeniedException when deleting assets?▼

The service user lacks jcr:removeNode and jcr:removeChildNodes privileges on /content/dam; rep:write alone is insufficient. Grant these privileges via Repoinit and map the subservice through ServiceUserMapperImpl.amended.

Can AEM call its own HTTP Assets API from inside the JVM?▼

No, self-looping HTTP calls add latency, require credentials the JVM should not store, and break idempotency. In-JVM code should use the Sling resource API directly with a service-user resolver.

What authentication replaces admin:admin basic auth on AEMaaCS?▼

AEMaaCS has no static admin password. External callers must use IMS bearer tokens from Adobe Developer Console service credentials or short-lived user tokens from the AEM login flow.