Skip to main content

Unofficial Python API for Odyssee

Project description

PyPI Version Downloads

Odyssee API

Provides an unofficial API for the Odyssee platform, allowing users to access and interact with their data programmatically.

Features

  • get information about candidates
  • get information about committee members
  • get information about institutions
  • get keywords
  • assign applications to committee members
  • get reports from committee members
  • provide decision on each candidate after the first round of evaluation

Installation

pip install odysseeapi

Getting the authentication token

  1. Go to the Odyssee platform using Chrome
  2. Open the developer tools (F12 or right-click and select "Inspect")
  3. Go to the "Network" tab
  4. Refresh the page
  5. Look for a request
    • Click on the request and go to the "Headers" tab
    • Look for the "Authorization" header and copy its value (it should start with "Bearer")
  6. Copy the token and use it in your code to authenticate with the API

Note that the authentication uses both cookies and a bearer token, so you need to provide both to access the API. The API automatically handles the cookie (using browsercookie), so you only need to provide the bearer token.

Note that the token is valid for a limited time, so you may need to repeat this process periodically to obtain a new token.

image

Minimal example

from odysseeapi.Odyssee import Odyssee

numposte = "123456"
token = """eyJhbGciOiJSUzI1N... (token value) ..."""

# Initialize the API client with the numposte, token and use_cache set to True
# setting use_cache to False forces the API client to fetch fresh data from the server for each request, while setting it to True allows the client to use cached data if available
odyssee = Odyssee(numposte, token, True)

candidates = odyssee.get_candidates()
print(candidates)

rapporteurs = odyssee.get_committee_members()
print(rapporteurs)

etablissements = odyssee.get_institutions()
print(etablissements)

keywords = odyssee.get_keywords()
print(keywords)

candidates_with_details = odyssee.get_candidates_with_details()
print(candidates_with_details)

# odyssee.assign_jury_members_to_candidate("f1e2d3c4-b5a6-4789-9876-543210fedcba", "98765432-10fe-dcba-9876-543210fedcba", "abcd1234-5678-90ef-ghij-klmnopqrstuv")

# Download the reports of the committee members for the candidates in the specified directory
odyssee.downloadReports("rapportsOdyssee")

# A l'issue de la première réunion du jury, enregistrer l'avis pour chaque candidat et les résultats du vote
# odyssee.opinion_for_interview("f1e2d3c4-b5a6-4789-9876-543210fedcba", "A", "Motif audition", 16, 16, 0, 0, 16, 0)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

odysseeapi-0.1.0.tar.gz (7.1 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

odysseeapi-0.1.0-py3-none-any.whl (7.2 kB view details)

Uploaded Python 3

File details

Details for the file odysseeapi-0.1.0.tar.gz.

File metadata

  • Download URL: odysseeapi-0.1.0.tar.gz
  • Upload date:
  • Size: 7.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for odysseeapi-0.1.0.tar.gz
Algorithm Hash digest
SHA256 2ff18c18aa651891df73348b341b820372d8127cd4509dead7a811fbcc85e8e3
MD5 7353198720a82a6c8ca0e0f8c21aff49
BLAKE2b-256 2573e0db296814c8ee7649ba9153408dea4c50302967037322ee71ff7021fe67

See more details on using hashes here.

File details

Details for the file odysseeapi-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: odysseeapi-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 7.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.11

File hashes

Hashes for odysseeapi-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 ada9cba114efe6cccfc31761997177f03074fc3091d37165a0191991f1ef4fc3
MD5 68d148633b80bfdf546f77eec5a07610
BLAKE2b-256 44cf930829fb8d97b34f70c938c8ded97c183386c51cdf4f35137b64d94f0dd9

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page