Need some assistance with routing -- 'resource' using natural key

I want to create a resource, let’s say ‘cars’, which are accessed by
license_number rather than id.
The column in question is guaranteed to be unique and unchanging (and
no, it’s not actually a car table).

Best way to go about this?

Thank you,

class Cars < ActiveRecord::Base

def to_param
return self.license_number