Liste der gängigen AEM cURL-Befehle

In diesem Artikel erfahren Sie mehr über die Liste häufiger cURL-Befehle AEM.

Beschreibung description

Umgebung

Adobe Experience Manager (AEM) 6.4 und 6.5

Schritte

REPLIKATIONEN:

Aktivieren

curl -u admin:admin -X POST -F path="/content/path/to/page" -F cmd="activate" http://localhost:4502/bin/replicate.json

Deaktivieren
        curl -u admin:admin -X POST -F path="/content/path/to/page" -F cmd="deactivate" http://localhost:4502/bin/replicate.json

Aktivieren eines Baums
        curl -u admin:admin -F cmd=activate -F ignoredeactivated=true -F onlymodified=true -F path=/content/geometrixx http://localhost:4502/etc/replication/treeactivation.html

SEITEN:

Seite sperren
        curl -u admin:admin -X POST -F cmd="lockPage" -F path="/content/path/to/page" -F "charset"="utf-8" http://localhost:4502/bin/wcmcommand

Seite entsperren
        curl -u admin:admin -X POST -F cmd="unlockPage" -F path="/content/path/to/page" -F "charset"="utf-8" http://localhost:4502/bin/wcmcommand

Seite kopieren
        curl -u admin:admin -F cmd=copyPage -F destParentPath=/path/to/destination/parent -F srcPath=/path/to/source/location http://localhost:4502/bin/wcmcommand

REPLIKATIONSAGENTEN:

Erstellen von Replikationsagenten

curl -u admin:admin 'http://localhost:4502/bin/wcmcommand' -H 'Content-Type: application/x-www-form-urlencoded; charset=UTF-8' —data 'cmd=createPage&charset=utf-8&parentPath=/etc/replication/agents.author&title=ReplicationAgentTest&label=&template=/libs/cq/replication/templates/agent'

BUNDLES:

Bundle deinstallieren

curl -u admin:admin -daction=uninstall http://localhost:4502/system/console/bundles/"Name des Bundles"

Bundle installieren
        curl -u admin:admin -F action=install -F bundlestartlevel=20 -F bundlefile=@"name of jar.jar" http://localhost:4502/system/console/bundles

Erstellen eines Bundles
        curl -u admin:admin -F bundleHome=/apps/project_name_here/bundles/name of bundle -F descriptor=/apps/project_name_here/bundles/project_name_here/name_of_bundle.bnd http://localhost:4502/libs/crxde/build

Bundle stoppen
        curl -u admin:admin http://localhost:4502/system/console/bundles/org.apache.sling.scripting.jsp  -F action=stop

Bundle starten
        curl -u admin:admin http://localhost:4502/system/console/bundles/org.apache.sling.scripting.jsp  -F action=start

Bundle löschen
         curl -u admin:admin -X DELETE http://localhost:4502/apps/localhost/install/com.localhost.core-6.2.26-SNAPSHOT.jar

PACKAGES:

Neues Paket hochladen

curl -u admin:admin -F package=@"name_of_package.zip" http://localhost:4502/crx/packmgr/service/.json/?cmd=upload

Vorhandenes Paket installieren
        curl -u admin:admin -X POST http://localhost:4502/crx/packmgr/service/.json/etc/packages/export/name von package?cmd=install

Paket hochladen UND installieren
        curl -u admin:admin -F file=@"Name der ZIP-Datei" -F name="Name des Pakets" -F force=true -F install=true http://localhost:4502/crx/packmgr/service.jsp

Hochladen eines Pakets NICHT installieren
        curl -u admin:admin -F file=@"Name der ZIP-Datei" -F name="Name des Pakets" -F force=true -F install=false http://localhost:4502/crx/packmgr/service.jsp

Vorhandenes Paket in CQ neu erstellen
        curl -u admin:admin -X POST http://localhost:4502/crx/packmgr/service/.json/etc/packages/name_of_package.zip?cmd=build

Herunterladen (das Paket)
        curl -u admin:admin http://localhost:4502/etc/packages/export/name_of_package.zip > Name der lokalen Paketdatei

BENUTZERVERWALTUNG:

Hinzufügen eines Benutzers zu einer Gruppe

curl -u admin:admin -FaddMembers=testing http://localhost:4502/home/groups/c/contributor.rw.html

Benutzer aus einer Gruppe entfernen
        curl -u admin:admin -FremoveMembers=testing http://localhost:4502/home/groups/c/contributor.rw.html

BACKUP

Festlegen der Verzögerungszeit (optional - Standard ist 10)

curl -u admin:admin -X POST http://localhost:4502/system/console/jmx/com.adobe.granite:type=Repository/a/BackupDelay?value=0

curl -u admin:admin -X POST http://localhost:4502/system/console/jmx/com.adobe.granite%3Atype%3DRepository/op/startBackup/java.lang.String?target=mvtest

HOCHLADEN VON ASSETS IN DAM

Hochladen eines Assets (z. B. test.png)
curl -u admin:admin -X POST -F file=@"test.png" http://localhost:4502/content/dam/geometrixx/portraits.createasset.html

REINDEX

Neuindizieren eines bestimmten Index (z. B. damStatus)
curl -u admin:admin -F"reindex=true" http://localhost:4502/oak:index/damStatus

Lösung resolution

recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f