A Ruby on Rails API backend for the Grandeur car marketplace application.
- Ruby 3.0.4
- Rails 7.0.5
- SQLite3 (development/test)
- PostgreSQL (production)
- Clone the repository
- Install dependencies:
bundle install
- Setup database:
rails db:create
rails db:migrate
- Start the server:
rails server
POST /users/sign_up
- Register a new userGET /users/verify_email
- Verify user emailPOST /users/login
- User login
POST /cars/new
- Create a new car listingGET /cars/all
- Get all car listingsGET /cars/search
- Search cars by name, brand, or modelDELETE /cars/delete
- Delete car listings
Access the admin panel at /admin
. Features include:
- User management
- Car listings management
- Analytics dashboard
- Email verification status
- Active Admin - Admin interface
- Devise - Authentication for admin
- Mailgun - Email service
- JWT - Token authentication
- Active Model Serializers - JSON serialization
- Rack CORS - Cross-Origin Resource Sharing
Run the test suite:
rails test
Full API documentation available at: https://api.postman.com/collections/25610988-a1e5e10a-f219-46bc-aea8-72ab2882e409?access_key=PMAT-01H2DMPA8C0GP94KK9VCQDA9HF
For local development, emails are sent to letter_opener at: http://localhost:3000/letter_opener