[SOLVED] Self Host Cloud Function via REST API

Calling cloud function via REST API returns {"error":"unauthorized"}.

I have tried the following
Sample URL
https://URL/server/functions/getMetadata?_ApplicationId=xxxxxx&name=xxxxx

Full Morlis server url
/functions/
Cloud Function Name
?_ApplicationId=yourMoralisAppId
(optional) Cloud Function param key/value pairs: &param1=value&param2=value

usually you have to use latest version of moralis v1 sdk or to modify server side the code that handles cloud functions in order to set the app id for those requests

1 Like

Thanks @cryptokid for speedy help