Body: <p>I would like for stats reasons to get all the games played between members of a same team. Is there a way with a direct call to the API ?</p>
  
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-22T15:21:01.300Z
Comments.Text: no there is no direct way but you have https://lichess.org/api#tag/Games/operation/apiGamesUser  (use with vs parameter)  and you can get the team members of a team using api https://lichess.org/api#tag/Teams/operation/teamIdUsers. so basically you'll have to do a little bit of coding
Comments.UserDisplayName: cmgchess
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-22T19:59:34.780Z
Comments.Text: Yes, I was arrived to the same point and so need to code to extract a string composed from users Id separated with comma but  to set the "players" parameter and not the vs one if I'm right.
Comments.UserDisplayName: Alain BUFERNE
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-23T07:59:43.710Z
Comments.Text: If you come up with some kind of solution it might be nice to share - in history this could have helped me. Only if you want to, of course!
Comments.UserDisplayName: Ian Bush
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-23T16:03:05.307Z
Comments.Text: I will do it as soon as I will have a working solution. I'm working with Electron but I've stopped developping for some time so little bit rusted
Comments.UserDisplayName: Alain BUFERNE
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-24T12:04:56.323Z
Comments.Text: @AlainBUFERNE so I assume you're looking for a JavaScript/node implementation?
Comments.UserDisplayName: double-beep
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-25T06:48:59.177Z
Comments.Text: yes I will work with Javascript. I realized this morning that I was wrong conerning the players parameter which is only used for pgn modification. I'm now more oriented toward a solution where I will download team'smembers data periodically in a database and will work on this small extracted database locally which is far enough for what I need where a pseudo real time is not necesary at all. Besides it will be better for Lichess server load.
Comments.UserDisplayName: Alain BUFERNE
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-26T18:02:06.330Z
Comments.Text: I’m voting to close this question because this is more of a programming problem (suited for stackoverflow, or other sites), but not a chess problem.
Comments.UserDisplayName: bakunin
Comments.ContentLicense: CC BY-SA 4.0
Comments.CreationDate: 2024-09-27T13:48:59.780Z
Comments.Text: @bakunin "_Chess-specific questions about programming ...other chess software are welcome_" ([source](https://chess.stackexchange.com/help/on-topic)).
Comments.UserDisplayName: SecretAgentMan
Tags: <online-chess><lichess><download-games>
Title: Get games between members of a team with Lichess API
ThreadText: # Get games between members of a team with Lichess API
  
  (Asked by: username_0 on 2024-09-22)
  
  I would like for stats reasons to get all the games played between members of a same team. Is there a way with a direct call to the API ?
  
  **Tags:** online-chess, lichess, download-games
  
  > **Comments:**
  > **username_1**: no there is no direct way but you have https://lichess.org/api#tag/Games/operation/apiGamesUser  (use with vs parameter)  and you can get the team members of a team using api https://lichess.org/api#tag/Teams/operation/teamIdUsers. so basically you'll have to do a little bit of coding  
  > **username_0**: Yes, I was arrived to the same point and so need to code to extract a string composed from users Id separated with comma but  to set the "players" parameter and not the vs one if I'm right.  
  > **username_2**: If you come up with some kind of solution it might be nice to share - in history this could have helped me. Only if you want to, of course!  
  > **username_0**: I will do it as soon as I will have a working solution. I'm working with Electron but I've stopped developping for some time so little bit rusted  
  > **username_3**: @AlainBUFERNE so I assume you're looking for a JavaScript/node implementation?  
  > **username_0**: yes I will work with Javascript. I realized this morning that I was wrong conerning the players parameter which is only used for pgn modification. I'm now more oriented toward a solution where I will download team'smembers data periodically in a database and will work on this small extracted database locally which is far enough for what I need where a pseudo real time is not necesary at all. Besides it will be better for Lichess server load.  
  > **username_4**: I’m voting to close this question because this is more of a programming problem (suited for stackoverflow, or other sites), but not a chess problem.  
  > **username_5**: @username_4 "_Chess-specific questions about programming ...other chess software are welcome_" ([source](https://chess.stackexchange.com/help/on-topic)).  
  
  ---
  
  ## 0 answers
  
  