Could you please explain on how the two apps(serverless and you_first_app/ any other front-end app) differ in terms of functionality.
Basic use of serverless apps is when you want to listen to any standard event that happens in the Freshworks product and perform some action whenever that event occurs. For example, whenever a ticket is created in Freshdesk, you want to create an issue in GitHub. In this scenario, you have to listen to onTicketCreate Freshdesk product event and then write a method to create an issue in github once that event occurs.
Refer: Your First Serverless App
Baisc use of Front end apps can be used to show some information to the user and it will be rendered in some standard locations. For example, if you want to display the Github issues based on the issue id, you can fetch the information from Github and display the information in the UI to the users.
Refer: Your First App
This is the simple difference between these 2 apps. You can also combine these 2 features in a single app.
There are also other features that can be used in serverless and front-end apps. Please refer Quick Start
So, in a serverless app will I be able to get some data using data methods and use that particular data for request methods?
You cannot directly access data methods in a serverless app but you can achieve it using server method invocation. You can define the method in the server file with request method and expose that. From front end you can fetch the require data using data method and call the respective server method from front end by passing that information.
For detailed info on server method invocation refer : Server Method Invocation
Could you please provide me a sample app that uses SMI, the one present in the documentation isn’t working for me.
I also wanted to know how does key-value storage methods work in both serverless and front end apps?
What template is to be used when I want to create a custom app with both serverless as well as front end features?
- first select
your_first_appand a front-end app will be created
- then use fdk generate command to generate the server.js file with desired events
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.