Skip to main content

User-related API environment

Pre-live user-related API docs

These pages describe the Pre-live user-related API stack.

Use pre-live OAuth credentials, pre-live API base URLs, and pre-live app URLs when following this documentation. Keep your OAuth flow, API requests, callback URLs, and manual testing within the pre-live environment.

Add or update user reading session

Track the user's most recent reading location (Surah/Ayah) for "Continue reading" / "Recently read" UX. This endpoint stores location only; it does not credit reading time, streaks, goals, or activity-calendar progress.

A new reading session will be created if the user does not have an existing one in the past 20 minutes; otherwise, the existing reading session will be updated with the latest read Ayah.

Call this when the latest visible/read Ayah changes. Quran.com debounces this call so frequent scrolling updates the user's resume location without sending one request for every intersection event.

For streaks, goals, and calendar-style progress tracking, call POST /v1/activity-days with the read ranges, active reading seconds, and Mushaf id. See Reading Sessions vs Activity Days.

Request Body
    chapterNumber integer required

    Possible values: >= 1

    The Surah number of the latest visible/read Ayah. Used for resume and recently-read UX.

    verseNumber integer required

    Possible values: >= 1

    The Ayah number within chapterNumber for the latest visible/read Ayah.

Responses

Request has been handled successfully.


Schema
    success boolean
    data object
    message string

    Possible values: [reading session created, reading session updated]

Loading...