Refactoring Grape API methods into normal controllers & other things
This commit is contained in:
parent
11ff92c9d7
commit
0e8f59c16f
63 changed files with 336 additions and 406 deletions
|
@ -2,12 +2,15 @@ Rails.application.routes.draw do
|
|||
get '.well-known/host-meta', to: 'xrd#host_meta', as: :host_meta
|
||||
get '.well-known/webfinger', to: 'xrd#webfinger', as: :webfinger
|
||||
|
||||
get 'atom/entries/:id', to: 'atom#entry', as: :atom_entry
|
||||
get 'atom/users/:id', to: 'atom#user_stream', as: :atom_user_stream
|
||||
get 'users/:name', to: 'profile#show', as: :profile
|
||||
get 'users/:name/:id', to: 'profile#entry', as: :status
|
||||
resources :accounts, path: 'users', only: [:show], param: :username do
|
||||
resources :stream_entries, path: 'updates', only: [:show]
|
||||
end
|
||||
|
||||
mount Mastodon::API => '/api/'
|
||||
namespace :api do
|
||||
resources :subscriptions, only: [:show]
|
||||
post '/subscriptions/:id', to: 'subscriptions#update'
|
||||
post '/salmon/:id', to: 'salmon#update', as: :salmon
|
||||
end
|
||||
|
||||
root 'home#index'
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue