You can use the AbcImport and AbcExport MEL commands to import and export Alembic files. For example, use the following to export a polygon torus:
AbcExport -j "-frameRange 1 120 -root pTorus1 -file c:/temp/test.abc";
Help for the commands is available in the Script Editor using either AbcExport -h; and AbcImport -h;.
You can use the following commands to export GPU caches.
gpuCache -f filename dagObject
gpuCache -directory "/dest/path" -fileName "filename" -saveMultipleFiles false [object1 object2 ....]
result: /dest/path/filename.abc
gpuCache -directory "/dest/path" -filePrefix "ddd_" -clashOption nodeName [object1 object2 ...]
result: /dest/path/ddd_object1.abc, /dest/path/ddd_object2.abc, ...
When caching multiple objects or files you can use the -prompt flag to display a warning message if existing files are going to be overwritten.
For GPU caches, there is no import command. Instead, you create the gpuCache node and set attributes for cache file name and path. For example:
createNode -n "mine" gpuCache;
setAttr -e -type "string" mine.cacheFileName "dd.abc";
setAttr -e -type "string" mine.cacheGeomPath "|"; // eg the root.
Help for the gpuCache commands is available in the Script Editor using help gpuCache;.