anchor.diff:          Req:respond({200, [{"Content-Type", "text/html"}], integer_to_list(ChannelId)})
       end},
   
  -    {['DELETE', "/channels/(\\d+)"], fun(Req, [ChannelId]) ->
  +    {['DELETE', "/channels/(\\d+)$"], fun(Req, [ChannelId]) ->
           authorize(Req),
           logplex_channel:delete(list_to_binary(ChannelId)),
           Req:respond({200, [], <<"OK">>})
       end},
   
  -    {['POST', "/channels/(\\d+)/token"], fun(Req, [ChannelId]) ->
  +    {['POST', "/channels/(\\d+)/token$"], fun(Req, [ChannelId]) ->
           authorize(Req),
           {struct, Params} = mochijson2:decode(Req:recv_body()),
           TokenName = proplists:get_value(<<"name">>, Params),
  
positive.code:         Req:respond({200, [{"Content-Type", "text/html"}], Session})
      end},
  
      {['GET', "/sessions/([\\w-]+)"], fun(Req, [Session]) ->
          Body = logplex_session:lookup(list_to_binary(Session)),
          not is_binary(Body) andalso error_resp(Req, 404, <<"session not found">>),
  
  
negative.code:         Req:respond({200, [{"Content-Type", "text/html"}], Token})
      end},
  
      {['POST', "/sessions$"], fun(Req, _Match) ->
          authorize(Req),
          Body = Req:recv_body(),
          Session = logplex_session:create(Body),
  