I have the session timeout set to 20min but when I try to access this value from action I\'m getting 1min instead.
Web.Config setti
Every first request for a new user is considered as a possible bot request. That's why session timeout is set to 1 minute for those requests.
If the request is executed by the proper end user, there should be VisitorIdentification
code on your page which in fact will cause another background call to the server and extend the session for the user.
Just add
@using Sitecore.Mvc.Analytics.Extensions
...
@Html.Sitecore().VisitorIdentification()
to your layout .cshtml file.
Timeout will be set to 1 minute for the first request, but then automatically changed back to 20 (or whatever is configured), when Sitecore does the VisitorIdentification
call.