Jump to content

Endpoint to get clubs by members?


Go to solution Solved by Daniel F,

Recommended Posts

  • 4 weeks later...
  • Solution

The /core/clubs endpoint will return only visible clubs if you're using oAuth 🙂 

	/**
	 * GET /core/clubs
	 * Get list of clubs
	 *
	 * @apiparam	int		page			Page number
	 * @apiparam	int		perPage			Number of results per page - defaults to 25
	 * @note		For requests using an OAuth Access Token for a particular member, only clubs the authorized user can view will be included
	 * @return		\IPS\Api\PaginatedResponse<IPS\Member\Club>
	 */

That said, I have raised an internal suggestion to add an additional parameter to pass a specific member 

Link to comment
Share on other sites

On 8/27/2021 at 1:18 PM, Daniel F said:

The /core/clubs endpoint will return only visible clubs if you're using oAuth 🙂 

	/**
	 * GET /core/clubs
	 * Get list of clubs
	 *
	 * @apiparam	int		page			Page number
	 * @apiparam	int		perPage			Number of results per page - defaults to 25
	 * @note		For requests using an OAuth Access Token for a particular member, only clubs the authorized user can view will be included
	 * @return		\IPS\Api\PaginatedResponse<IPS\Member\Club>
	 */

That said, I have raised an internal suggestion to add an additional parameter to pass a specific member 

Thank you! That would be great. I imagine requesting an oauth token for every member wouldn’t be wonderful. 

Our usecase is that we want to add a discord bot to pair with brilliantdiscord - giving clubs their own channel, giving members points for using it, and so on. 🙂 

Link to comment
Share on other sites

  • 2 months later...
On 11/4/2021 at 7:42 PM, Daniel F said:

This was implemented for 4.6.9 🙂

 

Is this just a change for this specific endpoint? It would be nice to filter other things down too. For example, getting Topics or Events using an API Key brings back stuff most people should not be able to see, it would be nice to be able to pass a member id for these too.

I tried to figure out how to impersonate a user with oAuth to do just this and never figured it out. I am sure if I had more hours in the day I could, but it's not exactly an easy task for someone like me.

Link to comment
Share on other sites

 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...