mirror of
https://github.com/discourse/discourse.git
synced 2025-05-22 16:21:18 +08:00
FEATURE: Adding some more api scopes (#20420)
Adds api scopes for - deleting a topic - deleting a post - listing tags
This commit is contained in:
@ -31,6 +31,9 @@ class ApiKeyScope < ActiveRecord::Base
|
||||
actions: %w[topics#update topics#status],
|
||||
params: %i[topic_id category_id],
|
||||
},
|
||||
delete: {
|
||||
actions: %w[topics#destroy],
|
||||
},
|
||||
read: {
|
||||
actions: %w[topics#show topics#feed topics#posts],
|
||||
params: %i[topic_id],
|
||||
@ -55,6 +58,14 @@ class ApiKeyScope < ActiveRecord::Base
|
||||
actions: %w[posts#update],
|
||||
params: %i[id],
|
||||
},
|
||||
delete: {
|
||||
actions: %w[posts#destroy],
|
||||
},
|
||||
},
|
||||
tags: {
|
||||
list: {
|
||||
actions: %w[tags#index],
|
||||
},
|
||||
},
|
||||
categories: {
|
||||
list: {
|
||||
|
Reference in New Issue
Block a user