Browser Local storage vs Freshdesk Data storage

Hi,
I was going through Freshdesk API docs and found that Freshdesk provides its own data storage :-
https://developers.freshdesk.com/docs/data-storage/

My question is, how should I decide where to put a key value pair i.e. should I put it in the browser local storage or should I put it in freshdesk data storage. I am well aware that browser local storage is not exactly secure but let’s say I won’t be saving any confidential/security sensitive data. All I need to do is to save the state of the app so that on page reload I can read from storage and render the last saved state.
Thanks in Advance !

Hey @Himanshu_Sehgal

Hope you are safe and doing well,

I can understand your dilemma, whether to use the Data Storage provided by Freshworks developer platform or the browser’s local storage, To be honest with you it boils down to a matter of choice and choosing which is best for the app rather than which is better between the two in general, both the Freshworks data storage and the browser’s local storage have their pros and cons, For example

Data Availability:-

Data saved in Freshworks data storage is available across the account and can be accessed across multiple agents and multiple browsers and devices as long they have access to the object saved in the data storage.

whereas in local storage the data is available is only to the agent/instance of the app that saves the value.
So if your preference is one of the below, Freshworks data storage is the way to go, Hands down!

  1. Data Persistence
  2. Data sharing across multiple agents in the account
  3. Reliability and security
Data Access Frequency

Freshworks data storage does have it’s limitations in terms of

size
  • Though there is no limit on the number of JSON objects that can be saved in Freshworks data storage, the size of each object cannot exceed 8kb
Frequency of access
  • Data storage also has a rate limit of 5o requests/minute (Read + write + update).

So, if your app doesn’t have to save the data securely, or require frequent access to the data, or save data local to that instance/agent, the browsers’s local storage seems to be the better option

TLDR:- For your Use Case, the Browsers’s local storage seems to be the better option

Hope this helps!

Stay Safe :slight_smile:

3 Likes

Thanks for your prompt reply, just another query regarding the rate limit of 50 requests/minute -
Suppose a customer has 10 agents, doing the calling and managing tickets etc. So the 50 requests/minute limit applies to each agent individually i.e. in this scenario total max count of requests limit will be 500 requests/minute, OR is this limit shared among all agents, i.e. in this scenario for each agent, maximum 5 requests can be made to data storage. ?

Hi @Himanshu_Sehgal,

50 request/minute limit is based on an Account level, i.e. limit shared among all agents.

@velmurugan - Please Correct me If I am wrong.

3 Likes

That will be a problem for me, as my use case scenario is strictly based on business hours, so suppose there are 100 agents in an account and they all try to login in our Custom App at the same time. Now as per our current implementation we save some sensitive data in freshdesk storage, if the login credentials are correct, so in this case if at exact 9:30 am all agents i.e. 100 agents login at the same time, it means more than 50 requests to freshdesk storage within a minute and thus our app functionality will break. Need to figure out a way around if this is the case. @velmurugan would love to have your insight on this.

@Himanshu_Sehgal Sorry for not making it clear, @Dineshkumar_Ravichan is correct, the 50 requests/minute limit is Per app, Per account basis shared by all agents,

Could you please let me know, what kind of sensitive data do you save in the data storage in the current setup? how does it relate to agent sign in?

1 Like

Well actually it’s something like this - Whenever an agent signs in our custom app, our api is hit internally(Not freshdesk APis), which takes credentials as input and if the credentials are correct, the api sends a passkey in response, this pass key has to be sent in the Auth headers of every further API request to our system. Now i was actually storing this passkey in the Freshdesk data storage for security reasons, however now it looks like I might have to save it somewhere else. This pass key is retrieved from the freshdesk data storage everytime a api request is to be made to our system, and this passkey is deleted when the agent logs out of the custom app.