And now I've figured it out.
Doorkeeper provides doorkeeper_token
, which can be accessed in the controller. This is a Doorkeeper::AccessToken
object, which references the app the token belongs to (as doorkeeper_token.application
). This is referenced (in the example code) here.