anchor.diff:                              {<<"POST">>, post}
                              ]).
   
  --define(PATHMAPPING, [
  -                      {?CONFIG(ep_redirect), ep_redirect},
  -                      {?CONFIG(ep_return), ep_return},
  -                      {?CONFIG(ep_user), ep_user}
  -                     ]).
  -
   -define(QSMAPPING, [
                      {<<"action">>, action, value},
                      {<<"request">>, request},
  
positive.code: 
      {ok, Session} = tts_session_mgr:get_session(CookieSessionId),
      {ok, SessionId} = tts_session:get_id(Session),
      AtomPath = map_to_atom(Path, ?PATHMAPPING, ep_main),
      AtomMethod = map_to_atom(Method, ?HTTPMETHODMAPPING),
      QsMap = create_map_from_proplist(QsList),
      BodyQsMap = create_map_from_proplist(BodyQsList),
      UserAgent = get_header(<<"user-agent">>, Headers),
      Referer = get_header(<<"referer">>, Headers),
      LoggedIn = is_logged_in(UserAgent, PeerIP, Session),
      ReqMap = #{
        path => AtomPath,
        method => AtomMethod,
        session => Session,
        session_id => SessionId,
        logged_in => LoggedIn,
        referer => Referer,
        user_agent => UserAgent,
        qs => QsMap,
        body_qs => BodyQsMap
       },
      {ok, Req99, #state{req_map = ReqMap, config_loaded = true,
  
negative.code:             #state{req_map=ReqMap} = State) ->
      Cookie = maps:get(cookie, Result, clear),
      {ok, Req2} = perform_cookie_action(Cookie, Req, ReqMap),
      {ok, Req3} = cowboy_req:reply(302, Header, Req2),
      {ok, Req3, State}.
  
  
  show_html(Body, Status, Req, State) ->
      Req2 = cowboy_req:set_resp_body(Body, Req),
  