X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/3b143dc2b4623e0ca23502e36f19c1c16b71d010..cfaae9eadd794d646950421c8d21a6fe356e727f:/app/abilities/api_capability.rb diff --git a/app/abilities/api_capability.rb b/app/abilities/api_capability.rb index f27dd2e63..44e676345 100644 --- a/app/abilities/api_capability.rb +++ b/app/abilities/api_capability.rb @@ -19,6 +19,8 @@ class ApiCapability can [:gpx_files], User if scope?(token, :read_gpx) can [:index, :show], UserPreference if scope?(token, :read_prefs) can [:update, :update_all, :destroy], UserPreference if scope?(token, :write_prefs) + can [:inbox, :outbox, :show, :update, :destroy], Message if scope?(token, :consume_messages) + can [:create], Message if scope?(token, :send_messages) if user.terms_agreed? can [:create, :update, :upload, :close, :subscribe, :unsubscribe], Changeset if scope?(token, :write_api)