An automated tool to check French exam results including DNB (Diplôme National du Brevet), BAC General & Technologique, and BAC Professionnel. This application periodically checks the official government website for exam results and notifies you when they become available.
- Multiple Exam Support: Configure to check DNB, BAC General & Technologique, or BAC Professionnel results
- Automated Checking: Continuously monitors the official results website
- Cookie Management: Automatically handles session cookies and refreshes them when needed
- Configurable: Easy configuration through JSON file - just change the exam_type
- Headless Browser: Runs Chrome in headless mode for efficient operation
- Error Handling: Robust error handling with automatic recovery
- Real-time Updates: Live status updates with timestamps
- DNB: Diplôme National du Brevet
- BGT: BAC General & Technologique
- BPR: BAC Professionnel
- Python 3.7 or higher
- Google Chrome browser
- ChromeDriver (automatically managed by Selenium 4.x)
-
Clone the repository:
git clone https://github.com/yourusername/CycladesNotifier.git cd CycladesNotifier -
Install dependencies:
pip install -r requirements.txt
-
Configure the application:
cp config.example.json config.json
Edit
config.jsonwith your personal information.
Edit the config.json file with your details:
{
"personal_info": {
"last_name": "YourLastName"
},
"exam_settings": {
"academy_code": "A25",
"year": "2025",
"exams_to_check": ["DNB", "BGT"]
},
"exam_types": {
"DNB": {
"name": "Diplôme National du Brevet",
"api_path": "DNB",
"contexte_format": "DNB,{academy_code},{year}:C:DNB-1.0,1,,,,"
},
"BGT": {
"name": "BAC General & Technologique",
"api_path": "BGT",
"contexte_format": "BGT,{academy_code},{year}:A:BGT-2.3,1,,,,"
}
},
"checker_settings": {
"check_interval": 15,
"max_consecutive_failures": 3
},
"browser_settings": {
"headless": true
}
}personal_info.last_name: Your last name for result lookupexam_settings.academy_code: Your academy code (e.g., "A25" for Besançon)exam_settings.year: Exam yearexam_settings.exam_type: The exam type to check (e.g., "DNB", "BGT", "BPR")exam_types: Configuration for each exam type (API paths and context formats)checker_settings.check_interval: Time between checks in secondschecker_settings.max_consecutive_failures: Max failures before refreshing cookiesbrowser_settings.headless: Run browser in headless mode (true/false)
Run the application:
python main.pyThe application will:
- Load configuration from
config.json - Automatically open a browser to get session cookies
- Start checking for results at the specified interval
- Display results when found
- Automatically refresh cookies if they expire
🎯 Exam Results Checker with Automatic Cookie Management
======================================================================
Checking for: YourLastName
Academy: A25
Year: 2025
Exam type: Diplôme National du Brevet
======================================================================
🌐 Opening browser to get cookies...
📖 Navigating to https://resultats.examens-concours.gouv.fr/DNB/A25/admis
✅ Retrieved 3 cookies
💾 Cookies saved to cookies.json
🔁 Starting Diplôme National du Brevet result checker with automatic cookie management...
⏰ 2025-07-09 14:30:00 - Checking results...
⏳ No Diplôme National du Brevet results yet for YourLastName.
😴 Waiting 15 seconds before next check...
main.py: Main application fileconfig.json: Configuration file (create from config.example.json)config.example.json: Example configuration filerequirements.txt: Python dependenciescookies.json: Automatically generated cookie storage (git-ignored)
- Cookie Acquisition: Opens Chrome browser to visit the official results page and collect session cookies
- API Requests: Uses the acquired cookies to make API requests to the configured exam result endpoint
- Result Parsing: Parses the JSON response to extract exam results for the configured exam type
- Continuous Monitoring: Repeats the process at configured intervals
- Error Recovery: Automatically refreshes cookies when they expire
To check a different exam type, simply change the exam_type in your config file:
- For DNB:
"exam_type": "DNB" - For BAC General & Technologique:
"exam_type": "BGT" - For BAC Professionnel:
"exam_type": "BPR"
To add support for a new exam type:
- Find the API endpoint: Use browser developer tools to find the exam's API endpoint
- Determine the context format: Analyze the request to understand the context parameter format
- Add to config: Add the new exam type to the
exam_typessection in your config file:
"NEW_EXAM": {
"name": "New Exam Name",
"api_path": "NEW",
"contexte_format": "NEW,{academy_code},{year}:X:NEW-1.0,1,,,,"
}- Update exam_type: Set
"exam_type": "NEW_EXAM"in your exam_settings
-
Chrome/ChromeDriver not found:
- Ensure Google Chrome is installed
- Selenium 4.x automatically manages ChromeDriver
-
Config file not found:
- Copy
config.example.jsontoconfig.json - Fill in your personal information
- Copy
-
No results found:
- Verify your last name spelling
- Check the academy code
- Ensure the exam year is correct
-
Cookie errors:
- The application automatically refreshes cookies
- If persistent, delete
cookies.jsonand restart
- Fork the repository
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This tool is for educational purposes only. Please ensure you comply with the terms of service of the official examination results website. Use responsibly and respect the server resources.
This project is licensed under the MIT License - see the LICENSE file for details.
This application is not affiliated with the French Ministry of Education or any official examination board. Results should always be verified through official channels. Use responsibly and respect the server resources.