aboutsummaryrefslogtreecommitdiff
path: root/config/routes.rb
blob: 1e5eedb20a9521892429f37a33aefc644721b261 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
# frozen_string_literal: true

Rails.application.routes.draw do
  resources :searches do
    collection do
      get 'search'
      get 'shared' => 'shared_searches#index'
    end

    get 'shared' => 'shared_searches#show'

    resource :exports, only: %i[new show]
  end

  resources :tags, only: %i[index new create destroy]
  resources :things, except: %i[index] do
    resources :comments, only: %i[create update destroy]
  end

  resource :license, only: %i[show]
  resource :sessions, only: %i[new create destroy]

  # Provided by Rails for health checking :)
  get 'up' => 'rails/health#show', as: :rails_health_check

  root 'searches#index'
end