npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2025 – Pkg Stats / Ryan Hefner

ges-api-react-native

v1.0.3

Published

Client TypeScript pour l'API GES

Downloads

15

Readme

GES API Client

Un client TypeScript moderne et organisé pour l'API GES (Kordis) compatible seulement react-native.

🙏 Remerciements

Ce projet s'inspire du travail de quantumsheep/myges-cli. Merci pour l'exploration initiale de l'API GES !

🚀 Installation

npm install

🏗️ Build

npm run build

📖 Utilisation

import { GesAPI, ProfileService, TimetableService, ProjectService } from './src';

// Connexion pour récupérer le token
const token = await GesAPI.login('username', 'password');

// Utilisation des services avec le token
const profile = await ProfileService.getProfile(token);
const years = await ProfileService.getYears(token);
const absences = await ProfileService.getAbsences(token, '2024');
const grades = await ProfileService.getGrades(token, '2024');

// Agenda
const start = new Date();
const end = new Date(Date.now() + 7 * 24 * 60 * 60 * 1000); // Semaine suivante
const timetable = await TimetableService.getTimetable(token, start, end);

// Projets
const projects = await ProjectService.getProjects(token, '2024');
const project = await ProjectService.getProject(token, 'project-id');
const nextSteps = await ProjectService.getNextProjectSteps(token);

📁 Structure du projet

src/
├── interfaces/           # Interfaces TypeScript
│   ├── timetable.ts
│   └── project.ts
├── types/               # Types généraux
│   └── auth.ts
├── services/            # Services organisés par domaine
│   ├── base.ts             # Service de base
│   ├── auth.ts             # Authentification
│   ├── profile.ts          # Profil utilisateur
│   ├── timetable.ts        # Emploi du temps
│   └── project.ts          # Projets
├── ges-api.ts           # Client principal
└── index.ts            # Point d'entrée

🎯 Fonctionnalités

🔐 Authentification

  • Login avec identifiants
  • Gestion des tokens OAuth

👤 Profil

  • Récupération du profil utilisateur
  • Années disponibles
  • Absences, notes, cours

📅 Emploi du temps

  • Récupération des événements de l'emploi du temps
  • Filtrage par dates

📝 Projets

  • Liste des projets
  • Détails d'un projet
  • Gestion des groupes de projet
  • Messages des groupes
  • Étapes de projet

🛠️ Scripts disponibles

  • npm run build - Compile le projet

📦 Export

Le projet exporte tout ce dont vous avez besoin :

  • Le client principal GesAPI pour l'authentification
  • Tous les types et interfaces
  • Les services individuels (ProfileService, TimetableService, ProjectService)

🔧 Architecture

Le projet utilise une architecture fonctionnelle avec des services statiques :

  • Services statiques : Chaque fonction prend le token en paramètre
  • Indépendance : Pas de gestion d'état, facilite l'intégration dans d'autres services
  • Simplicité : Authentification séparée des appels API
  • Flexibilité : Permet l'utilisation avec différents systèmes de gestion de tokens

Avantages de cette approche

  • Intégration facile : Compatible avec tous les frameworks et architectures
  • Pas de singleton : Évite les problèmes de state management
  • Testabilité : Chaque fonction est pure et testable indépendamment
  • Performance : Pas d'instanciation d'objets nécessaire