Depending on the value you set in buildtemplate.yaml for the OW_RUNTIME_PLATFORM
parameter, you will need to invoke different endpoints to execute the test.
curl -H "Host: nodejs-helloworld.default.example.com" -X POST http://localhost/
Initialize the runtime with the function and other configuration data using the /init
endpoint.
curl -H "Host: nodejs-helloworld.default.example.com" -d "@data-init.json" -H "Content-Type: application/json" http://localhost/init {"OK":true}
Execute the function using the /run
endpoint.
curl -H "Host: nodejs-helloworld.default.example.com" -d "@data-run.json" -H "Content-Type: application/json" -X POST http://localhost/run {"payload":"Hello"}