API for gcm-erlang