anchor.diff:  %%------------------------------------------------------------------------------
   %% Authorization Response
   %%------------------------------------------------------------------------------
  +
  +%%
  +%% @todo this route per se must be accessible by authenticated resourse owners!
  +%%
   
   authorization_decision(Req, State = #state{response_type = <<"code">>,
       client_id = ClientId, redirect_uri = RedirectUri,
  
positive.code:     redirect_uri,
      scope,
      opaque,
      response_type,
      code
    }).
  
  init(_Transport, Req, Opts) ->
    % apply apigen pragmatic REST recommendations
    Req2 = cowboy_patch:patch_pragmatic_rest(
         cowboy_patch:patch_method(
         cowboy_patch:patch_headers(Req))),
    % go rest
    {upgrade, protocol, cowboy_rest, Req2, #state{
        options = Opts
      }}.
  
  terminate(_Reason, _Req, _State) ->
    ok.
  
negative.code:   {_, Value} = lists:keyfind(Key, 1, List),
    Value.
  
  urlencode(Bin) when is_binary(Bin) ->
    cowboy_http:urlencode(Bin);
  urlencode(Atom) when is_atom(Atom) ->
    urlencode(atom_to_binary(Atom, latin1));
  urlencode(Int) when is_integer(Int) ->
    urlencode(list_to_binary(integer_to_list(Int)));
  urlencode({K, undefined}) ->
    << (urlencode(K))/binary, $= >>;
  urlencode({K, V}) ->
    << (urlencode(K))/binary, $=, (urlencode(V))/binary >>;
  urlencode(List) when is_list(List) ->
    binary_join(List, $&).
  
  binary_join([], _Sep) ->
    <<>>;
  binary_join([H], _Sep) ->
    << H/binary >>;
  binary_join([H | T], Sep) ->
    << H/binary, Sep/binary, (binary_join(T, Sep))/binary >>.
  
  %%
  %%------------------------------------------------------------------------------
  