1

i'm trying to develop tools for my sport club and for that i would like use an API requests with python automatically obtain information from french handball federation website.

For that a use a classic python request with the library "requests" :

import requests

URL = 'https://www.ffhandball.fr/wp-json/competitions/v1/computeBlockAttributes'
PARAMS = {'block':'competitions---rencontre-list',
         'url_competition':'174907',
        'ext_equipe_id':'5138009'}
r = requests.get(url = URL, params = PARAMS)
data = r.json()
print(data)

This request return au status code 200, but i'm not obtaining a classic "JSON" values, only a long string :

TVE/LwNtSgUKBzxZOR0UEHFBYF9TEQgILAcIFzICDRFCGjU5KEZAFAZWaRVEWFJHOQ8dAAUWDwcHERUfYF1bWhpRLyUbbVoLDgQ2Qw8AGV0lQXhRQFNOXUNTRVZgAgEMaQM1IhtXZg0HVmkVRFhSXD4OJwEeOxALBhYJHydFQ1oUX3gyD0ZmARIBOkcDKxlWaVlgRkBXQlRDXUVWYAIBDGkBPzkUXVcQEREMXgJWShBpT2ADHhEWAVFeRVhuRQodWhY5IxJWZgoWGTZFCSsaXT4RLBYURkBGUUhFCCcJGhdYBygyBBADPz4J

I think I forgot something but i don't know what... Somebody can help me to understand my mistake ?

5
  • It is just encoded data. Commented Oct 16 at 17:25
  • What if you include an "Accept: application/json" header? Commented Oct 16 at 17:32
  • Can you show the main URL that you opened in your browser in order to generate that request? (I assume it came from Dev Tools after you clicked something?) Commented Oct 16 at 17:41
  • 1
    I checked for example page ffhandball.fr/competitions/saison-2025-2026-21/coupe-de-france and in DevTools I see it sends the same type of output. It encoded with base64 but this still gives strange string starting with MQ. I tried to search if it is some kind of compression of data but I found nothing. Page may use some system to send less data or to hide infromation so others couldn't get them (without paying?) Commented Oct 17 at 16:00
  • If I click into a competition e.g. ffhandball.fr/competitions/saison-2025-2026-21/coupe-de-france/… then the data is embedded in the page in <smartfire-component tags i.e. soup.find('smartfire-component', {'name': 'competitions---rencontre-list'}) But I can't find any requests to the endpoint in the question. Commented Oct 18 at 11:49

0

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.