Skip to main content
Omeka S exposes a REST API rather than a standalone administration CLI. sitectl provides direct API helpers and resource shortcuts:
sitectl omeka-s api get items
sitectl omeka-s api get items 12
sitectl omeka-s api request POST items --identity "$OMEKA_S_KEY_IDENTITY" --credential "$OMEKA_S_KEY_CREDENTIAL" --file item.json
API helpers accept:
  • --url for the base API URL, defaulting to http://localhost/api
  • --identity for the Omeka S API key identity
  • --credential for the Omeka S API key credential
  • --query name=value for repeated query parameters
  • --data or --file for JSON request bodies on arbitrary requests

Reference

api get

GET an Omeka S API resource
sitectl omeka-s api get RESOURCE [ID]
FlagDefaultDescription
--credentialOmeka S API key credential.
--identityOmeka S API key identity.
-q, --query[]Additional query parameter as name=value. May be repeated.
--urlhttp://localhost/apiBase Omeka S API URL.

api request

Call an arbitrary Omeka S API path
sitectl omeka-s api request METHOD PATH
FlagDefaultDescription
--credentialOmeka S API key credential.
--dataJSON request body.
--filePath to a JSON request body file.
--identityOmeka S API key identity.
-q, --query[]Additional query parameter as name=value. May be repeated.
--urlhttp://localhost/apiBase Omeka S API URL.