codingame_tools.client.service.services.achievement¶
achievement
¶
Async Achievement service endpoint.
CgAchievementServiceHelper
¶
CgAchievementServiceHelper(service)
Bases: CgServiceHelper['CgAchievementService']
Helper methods for CgAchievementService. Currently empty.
Source code in codingame_tools/client/service/cg_service.py
124 125 | |
CgAchievementService
¶
CgAchievementService(client)
Bases: CgService
Async Achievement service endpoint.
Source code in codingame_tools/client/service/services/achievement.py
26 27 28 | |
find_by_codingamer_id
async
¶
find_by_codingamer_id(codingamer_id=None)
Find the achievements a codingamer has unlocked.
Parameters:
-
codingamer_id(int | None, default:None) –The codingamer whose achievements to list. If not provided, defaults to the logged-in codingamer's ID.
Returns:
-
list[CgAchievement]–A list of CgAchievement objects.
Raises:
-
CgAuthenticationError–If the session is not authenticated and cannot implicitly login, or if
codingamer_idis not provided and no codingamer ID can be resolved from the session's credentials. -
CgClientHttpError–If a transport error occurs, if the response content could not be decoded at all, if the status code is not 2xx, or if the decoded content is not a list.
Source code in codingame_tools/client/service/services/achievement.py
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 | |