Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions docs/oauth2_apis_versioned/1.0.0/revoke-oidc-session.api.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description: "This endpoint handles the user logout process in Quran.Foundation'
sidebar_label: "OpenID Connect Logout"
hide_title: true
hide_table_of_contents: true
api: {"description":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nThe logout process follows the OpenID Connect specifications:\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","operationId":"revokeOidcSession","responses":{"302":{"description":"Successful logout. The user will be redirected to complete the logout process."}},"tags":["OIDC"],"method":"get","path":"/oauth2/sessions/logout","servers":[{"url":"https://oauth2.quran.foundation","description":"Production Server"},{"url":"https://staging-oauth2.quran.foundation","description":"Staging Server"}],"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token authentication"},"basicAuth":{"type":"http","scheme":"basic","description":"Basic authentication for client credentials"}},"info":{"title":"OAuth2 APIs","version":"1.0.0","description":"Quran.Foundation OAuth2 APIs are a set of APIs that allow you to integrate your app with Quran.Foundation's OAuth2 capabilities. This includes endpoints for OpenID Connect Userinfo, OAuth2 Token Exchange, and OAuth2 Authorize. The APIs are designed to be simple and easy to use, with a focus on security and privacy. Integrating with Quran.Foundation's OAuth2 APIs is required to access Quran.Foundation's APIs."},"postman":{"name":"OpenID Connect Logout","description":{"content":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nThe logout process follows the OpenID Connect specifications:\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","type":"text/plain"},"url":{"path":["oauth2","sessions","logout"],"host":["{{baseUrl}}"],"query":[],"variable":[]},"method":"GET"}}
api: {"description":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nTo redirect users back to your app after logout, include `post_logout_redirect_uri`. The redirect URI must be pre-registered in your OAuth2 client configuration.\n\nThe logout process follows the OpenID Connect specifications:\n- [RP-Initiated Logout](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","operationId":"revokeOidcSession","parameters":[{"in":"query","name":"id_token_hint","description":"The ID token received during authentication. Optional but recommended for identifying the user session.","required":false,"schema":{"type":"string","example":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."}},{"in":"query","name":"post_logout_redirect_uri","description":"Where to redirect the user after logout. Must be pre-registered in your OAuth2 client's `post_logout_redirect_uris`.","required":false,"schema":{"type":"string","example":"https://your-app.com/"}},{"in":"query","name":"state","description":"Opaque value passed back to the `post_logout_redirect_uri` for CSRF protection.","required":false,"schema":{"type":"string","example":"af0ifjsldkj"}}],"responses":{"302":{"description":"Successful logout. The user will be redirected to complete the logout process."}},"tags":["OIDC"],"method":"get","path":"/oauth2/sessions/logout","servers":[{"url":"https://oauth2.quran.foundation","description":"Production Server"},{"url":"https://staging-oauth2.quran.foundation","description":"Staging Server"}],"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token authentication"},"basicAuth":{"type":"http","scheme":"basic","description":"Basic authentication for client credentials"}},"info":{"title":"OAuth2 APIs","version":"1.0.0","description":"Quran.Foundation OAuth2 APIs are a set of APIs that allow you to integrate your app with Quran.Foundation's OAuth2 capabilities. This includes endpoints for OpenID Connect Userinfo, OAuth2 Token Exchange, and OAuth2 Authorize. The APIs are designed to be simple and easy to use, with a focus on security and privacy. Integrating with Quran.Foundation's OAuth2 APIs is required to access Quran.Foundation's APIs."},"postman":{"name":"OpenID Connect Logout","description":{"content":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nTo redirect users back to your app after logout, include `post_logout_redirect_uri`. The redirect URI must be pre-registered in your OAuth2 client configuration.\n\nThe logout process follows the OpenID Connect specifications:\n- [RP-Initiated Logout](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","type":"text/plain"},"url":{"path":["oauth2","sessions","logout"],"host":["{{baseUrl}}"],"query":[{"disabled":false,"description":{"content":"The ID token received during authentication. Optional but recommended for identifying the user session.","type":"text/plain"},"key":"id_token_hint","value":""},{"disabled":false,"description":{"content":"Where to redirect the user after logout. Must be pre-registered in your OAuth2 client's `post_logout_redirect_uris`.","type":"text/plain"},"key":"post_logout_redirect_uri","value":""},{"disabled":false,"description":{"content":"Opaque value passed back to the `post_logout_redirect_uri` for CSRF protection.","type":"text/plain"},"key":"state","value":""}],"variable":[]},"method":"GET"}}
sidebar_class_name: "get api-method"
info_path: docs/oauth2_apis_versioned/1.0.0/oauth-2-apis
custom_edit_url: null
Expand All @@ -29,15 +29,16 @@ This endpoint handles the user logout process in Quran.Foundation's OAuth2 & Ope
1. Ends the user's current session
2. Revokes associated access and refresh tokens

To redirect users back to your app after logout, include `post_logout_redirect_uri`. The redirect URI must be pre-registered in your OAuth2 client configuration.

The logout process follows the OpenID Connect specifications:
- [RP-Initiated Logout](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)
- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)
- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)

**Post-logout redirect:** If you pass `post_logout_redirect_uri`, you must also include `id_token_hint` (the ID token from the login response). Requests with `post_logout_redirect_uri` but without `id_token_hint` will be rejected.

<div><ApiTabs><TabItem label={"302"} value={"302"}><div>
<details style={{"marginBottom":"1rem"}} data-collapsed={false} open={true}><summary style={{}}><strong>Query Parameters</strong></summary><div><ul><ParamsItem className={"paramsItem"} param={{"in":"query","name":"id_token_hint","description":"The ID token received during authentication. Optional but recommended for identifying the user session.","required":false,"schema":{"type":"string","example":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"post_logout_redirect_uri","description":"Where to redirect the user after logout. Must be pre-registered in your OAuth2 client's `post_logout_redirect_uris`.","required":false,"schema":{"type":"string","example":"https://your-app.com/"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"state","description":"Opaque value passed back to the `post_logout_redirect_uri` for CSRF protection.","required":false,"schema":{"type":"string","example":"af0ifjsldkj"}}}></ParamsItem></ul></div></details><div><ApiTabs><TabItem label={"302"} value={"302"}><div>

Successful logout. The user will be redirected to complete the logout process.

</div><div></div></TabItem></ApiTabs></div>


11 changes: 6 additions & 5 deletions docs/oauth2_apis_versioned/revoke-oidc-session.api.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ description: "This endpoint handles the user logout process in Quran.Foundation'
sidebar_label: "OpenID Connect Logout"
hide_title: true
hide_table_of_contents: true
api: {"description":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nThe logout process follows the OpenID Connect specifications:\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","operationId":"revokeOidcSession","responses":{"302":{"description":"Successful logout. The user will be redirected to complete the logout process."}},"tags":["OIDC"],"method":"get","path":"/oauth2/sessions/logout","servers":[{"url":"https://oauth2.quran.foundation","description":"Production Server"},{"url":"https://staging-oauth2.quran.foundation","description":"Staging Server"}],"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token authentication"},"basicAuth":{"type":"http","scheme":"basic","description":"Basic authentication for client credentials"}},"info":{"title":"OAuth2 APIs","version":"1.0.0","description":"Quran.Foundation OAuth2 APIs are a set of APIs that allow you to integrate your app with Quran.Foundation's OAuth2 capabilities. This includes endpoints for OpenID Connect Userinfo, OAuth2 Token Exchange, and OAuth2 Authorize. The APIs are designed to be simple and easy to use, with a focus on security and privacy. Integrating with Quran.Foundation's OAuth2 APIs is required to access Quran.Foundation's APIs."},"postman":{"name":"OpenID Connect Logout","description":{"content":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nThe logout process follows the OpenID Connect specifications:\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","type":"text/plain"},"url":{"path":["oauth2","sessions","logout"],"host":["{{baseUrl}}"],"query":[],"variable":[]},"method":"GET"}}
api: {"description":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nTo redirect users back to your app after logout, include `post_logout_redirect_uri`. The redirect URI must be pre-registered in your OAuth2 client configuration.\n\nThe logout process follows the OpenID Connect specifications:\n- [RP-Initiated Logout](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","operationId":"revokeOidcSession","parameters":[{"in":"query","name":"id_token_hint","description":"The ID token received during authentication. Optional but recommended for identifying the user session.","required":false,"schema":{"type":"string","example":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."}},{"in":"query","name":"post_logout_redirect_uri","description":"Where to redirect the user after logout. Must be pre-registered in your OAuth2 client's `post_logout_redirect_uris`.","required":false,"schema":{"type":"string","example":"https://your-app.com/"}},{"in":"query","name":"state","description":"Opaque value passed back to the `post_logout_redirect_uri` for CSRF protection.","required":false,"schema":{"type":"string","example":"af0ifjsldkj"}}],"responses":{"302":{"description":"Successful logout. The user will be redirected to complete the logout process."}},"tags":["OIDC"],"method":"get","path":"/oauth2/sessions/logout","servers":[{"url":"https://oauth2.quran.foundation","description":"Production Server"},{"url":"https://staging-oauth2.quran.foundation","description":"Staging Server"}],"securitySchemes":{"bearerToken":{"type":"http","scheme":"bearer","bearerFormat":"JWT","description":"Bearer token authentication"},"basicAuth":{"type":"http","scheme":"basic","description":"Basic authentication for client credentials"}},"info":{"title":"OAuth2 APIs","version":"1.0.0","description":"Quran.Foundation OAuth2 APIs are a set of APIs that allow you to integrate your app with Quran.Foundation's OAuth2 capabilities. This includes endpoints for OpenID Connect Userinfo, OAuth2 Token Exchange, and OAuth2 Authorize. The APIs are designed to be simple and easy to use, with a focus on security and privacy. Integrating with Quran.Foundation's OAuth2 APIs is required to access Quran.Foundation's APIs."},"postman":{"name":"OpenID Connect Logout","description":{"content":"This endpoint handles the user logout process in Quran.Foundation's OAuth2 & OpenID Connect system. When called, it:\n\n1. Ends the user's current session\n2. Revokes associated access and refresh tokens\n\nTo redirect users back to your app after logout, include `post_logout_redirect_uri`. The redirect URI must be pre-registered in your OAuth2 client configuration.\n\nThe logout process follows the OpenID Connect specifications:\n- [RP-Initiated Logout](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)\n- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)\n- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)","type":"text/plain"},"url":{"path":["oauth2","sessions","logout"],"host":["{{baseUrl}}"],"query":[{"disabled":false,"description":{"content":"The ID token received during authentication. Optional but recommended for identifying the user session.","type":"text/plain"},"key":"id_token_hint","value":""},{"disabled":false,"description":{"content":"Where to redirect the user after logout. Must be pre-registered in your OAuth2 client's `post_logout_redirect_uris`.","type":"text/plain"},"key":"post_logout_redirect_uri","value":""},{"disabled":false,"description":{"content":"Opaque value passed back to the `post_logout_redirect_uri` for CSRF protection.","type":"text/plain"},"key":"state","value":""}],"variable":[]},"method":"GET"}}
sidebar_class_name: "get api-method"
info_path: docs/oauth2_apis_versioned/oauth-2-apis
custom_edit_url: null
Expand All @@ -29,15 +29,16 @@ This endpoint handles the user logout process in Quran.Foundation's OAuth2 & Ope
1. Ends the user's current session
2. Revokes associated access and refresh tokens

To redirect users back to your app after logout, include `post_logout_redirect_uri`. The redirect URI must be pre-registered in your OAuth2 client configuration.

The logout process follows the OpenID Connect specifications:
- [RP-Initiated Logout](https://openid.net/specs/openid-connect-rpinitiated-1_0.html)
- [Front-Channel Logout](https://openid.net/specs/openid-connect-frontchannel-1_0.html)
- [Back-Channel Logout](https://openid.net/specs/openid-connect-backchannel-1_0.html)

**Post-logout redirect:** If you pass `post_logout_redirect_uri`, you must also include `id_token_hint` (the ID token from the login response). Requests with `post_logout_redirect_uri` but without `id_token_hint` will be rejected.

<div><ApiTabs><TabItem label={"302"} value={"302"}><div>
<details style={{"marginBottom":"1rem"}} data-collapsed={false} open={true}><summary style={{}}><strong>Query Parameters</strong></summary><div><ul><ParamsItem className={"paramsItem"} param={{"in":"query","name":"id_token_hint","description":"The ID token received during authentication. Optional but recommended for identifying the user session.","required":false,"schema":{"type":"string","example":"eyJhbGciOiJSUzI1NiIsInR5cCI6IkpXVCJ9..."}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"post_logout_redirect_uri","description":"Where to redirect the user after logout. Must be pre-registered in your OAuth2 client's `post_logout_redirect_uris`.","required":false,"schema":{"type":"string","example":"https://your-app.com/"}}}></ParamsItem><ParamsItem className={"paramsItem"} param={{"in":"query","name":"state","description":"Opaque value passed back to the `post_logout_redirect_uri` for CSRF protection.","required":false,"schema":{"type":"string","example":"af0ifjsldkj"}}}></ParamsItem></ul></div></details><div><ApiTabs><TabItem label={"302"} value={"302"}><div>

Successful logout. The user will be redirected to complete the logout process.

</div><div></div></TabItem></ApiTabs></div>


Loading