title: How to provide a route for current user in a REST API?
body: <p>So I have a simple <code>users</code> resource defined in my routes.</p>
  
  <pre><code>resources :users
  </code></pre>
  
  <p>I need to provide a route so that a logged in user can get his information in the front end. I thought about doing this:</p>
  
  <pre><code>resources :users do
    get 'current' , on: :collection
  end
  </code></pre>
  
  <p>But this semantically means that the route gives a list of current <strong>users</strong>, not the current <strong>user</strong>. And Indeed if I do <code>rake routes</code>, it shows the path prefix as: <code>current_users</code></p>
  
  <p>I can work around the path prefix by doing something like this:</p>
  
  <pre><code>get '/users/current' =&gt; 'users#current', as: 'current_user'
  </code></pre>
  
  <p>But this still looks like it provides a list of users. So, I was wondering if there was a 'right way' to do this kind of thing and how to do it in rails? Or am I thinking too much about this and what I have is fine?</p>