Skip to content

NatiqQuran/nq-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

πŸ“– Natiq Quran API

Natiq Logo

A comprehensive open-source Quran API providing easy access to Quranic content

β€’ 🌐 Website β€’ πŸ› οΈ Developer Portal β€’ πŸ“– Test api in browser β€’ πŸ“¦ SDK β€’ πŸ› Issues

Django CI Docker Image CI Docker Publish License: GPL v3 Contributors Stars


πŸ“‘ Table of Contents


Description

Natiq Quran API is a powerful, open-source RESTful API designed to provide developers with seamless access to the Holy Quran's contentβ€”including full Arabic text, multilingual translations, and audio recitations.

This API is at the heart of the Natiq ecosystem, powering various digital Islamic tools such as:

  • βœ… Natiq SDKs for effortless integration into your mobile, web, or backend apps
  • 🌍 natiq.net β€” our fully-featured platform built on top of this API
  • βš™οΈ Conversion and content tools to help you extend and customize Quranic data
  • πŸ“± Frontend apps using Next.js and PWA technologies

Whether you're building an educational platform, a personal Quran app, or integrating spiritual content into your existing products, nq-api provides a fast, developer-friendly, and scalable foundation.

If you're looking to get started quickly, consider using our nq-sdk or ready-to-use hosted services at api.natiq.net.

Key Features

  • πŸ“š Complete Quranic Text - Access all 114 Surahs with original Arabic text
  • 🌍 Multi-language Support - Translations in multiple languages
  • πŸ”Š Audio Integration - Links to recitation files
  • πŸ“– Tafsir Support - Commentary and explanations
  • πŸ“– Word-by-Word Data - Get detailed information for each word in an Ayah
  • ⚑ High Performance - Fast response times with optimized data structure
  • πŸ”“ Open Source - Free to use and contribute
  • πŸ“± Developer Friendly - Simple REST endpoints with JSON responses
  • πŸ›‘οΈ Reliable - Stable API with consistent uptime

πŸ› οΈ Developer Tools

developer.natiq.net - Test all endpoints directly in your browser!

  • 🎯 Zero Setup Required - Start testing immediately
  • πŸ” Live API Testing - Interactive playground for all endpoints
  • πŸ“– Real-time Documentation - See responses as you explore
  • πŸ’‘ Code Examples - Copy-paste ready code snippets
  • πŸ”§ Request Builder - Visual interface for API calls

πŸ“¦ Official SDK

nq-sdk - Official SDK for faster development

  • ⚑ Quick Integration - Get started in minutes, not hours
  • πŸ”„ Auto-completion - Full TypeScript support

API Endpoints

The following are the main API endpoints available:

  • /users/: User management.
  • /groups/: Group management.
  • /mushafs/: Mushaf (Quran version) information.
  • /surahs/: List of Surahs.
  • /ayahs/: List of Ayahs.
  • /words/: List of words.
  • /translations/: Available translations.
  • /ayah-translations/: Ayah translations.
  • /recitations/: Recitation information.
  • /auth/: Authentication endpoints.
  • /profile/: User profiles.
  • /phrases/: Quranic phrases.

Project Structure

nq-api/
β”œβ”€β”€ πŸ“ account/         # User management app
β”œβ”€β”€ πŸ“ api/             # Core API configuration and routing
β”œβ”€β”€ πŸ“ core/            # Core functionalities
β”œβ”€β”€ πŸ“ data/            # Data files
β”œβ”€β”€ πŸ“ quran/           # Quran-related app (Surahs, Ayahs, etc.)
β”œβ”€β”€ πŸ“„ .dockerignore
β”œβ”€β”€ πŸ“„ .gitignore
β”œβ”€β”€ πŸ“„ Dockerfile       # Docker image configuration
β”œβ”€β”€ πŸ“„ LICENSE          # project license
β”œβ”€β”€ πŸ“„ README.md         # This file
β”œβ”€β”€ πŸ“„ docker-compose.yaml # Docker orchestration
β”œβ”€β”€ πŸ“„ entrypoint.prod.sh
β”œβ”€β”€ πŸ“„ manage.py         # Django management script
β”œβ”€β”€ πŸ“„ nginx.conf        # Django management script
└── πŸ“„ requirements.txt  # Python dependencies

Install/Deploy Options

With Docker


πŸ”Ή Step 1 – Update your system

sudo apt update

πŸ”Ή Step 2 – Install Docker

If Docker is not already installed, you can install it with the official script:

curl -fsSL https://get.docker.com | sh

You can verify the installation with:

docker --version

πŸ”Ή Step 3 – Create the project folder

mkdir -p nq-api
cd nq-api

πŸ”Ή Step 4 – Download required files

curl -fsSL https://raw.githubusercontent.com/NatiqQuran/nq-api/refs/heads/main/docker-compose.yaml -o docker-compose.yaml
curl -fsSL https://raw.githubusercontent.com/NatiqQuran/nq-api/refs/heads/main/nginx.conf -o nginx.conf

πŸ”Ή Step 5 – Review your docker-compose.yaml

Make sure the following values are properly set inside the environment: section under the api service:

  • SECRET_KEY: Generate one using:
cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 40 | head -n 1
  • DJANGO_ALLOWED_HOSTS: Get your public IP:
curl -s https://api.ipify.org

You can now edit the file and insert these values as shown below:

api:
    image: natiqquran/nq-api:main 
environment:
  SECRET_KEY: your-generated-secret
  DJANGO_ALLOWED_HOSTS: your-ip-address

Open the file with:

nano docker-compose.yaml

Or use any other editor you prefer.


πŸ”Ή Step 6 – Run the containers

From inside the nq-api folder:

docker compose up -d

βœ… Done!

After a few seconds, the API should be up and running.

You can now access it at:

http://<your-server-ip>

Replace <your-server-ip> with your actual server IP or Domain address .

About

Natiq Quran open API.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Sponsor this project

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages