Note: Before diving into this implementation, consider that there are more popular and potentially easier-to-use solutions for implementing Sign in with Apple in Ruby on Rails, such as Omniauth. If you prefer a more out-of-the-box approach, explore those alternatives.
This implementation of the Sign in with Apple service in Ruby on Rails is suitable for APIs, eliminating the need for views.