Skip to content

Commit c60aaff

Browse files
authored
docs: app_api session keys (#182)
Ref: #181 Ref: nextcloud/server#42479
1 parent b2be001 commit c60aaff

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

docs/tech_details/Authentication.rst

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -78,3 +78,14 @@ AppAPIAuth
7878

7979
AppAPI provides ``AppAPIAuth`` attribute with middleware to validate requests from ExApps.
8080
In your API controllers you can use it as an PHP attribute.
81+
82+
AppAPI session keys
83+
^^^^^^^^^^^^^^^^^^^
84+
85+
After successful authentication AppAPI sets `app_api` session key to ``true``.
86+
87+
.. code-block:: php
88+
89+
$this->session->set('app_api', true);
90+
91+
.. note:: The Nextcloud server verifies this session key and allows **CORS protection** and **Two-Factor authentication** to be bypassed for requests coming from ExApps.

0 commit comments

Comments
 (0)