Using PATCH requests


#1

Hi,

I am using a HTTPClient in C# to send various GET requests that are all working and returning data for my FACEIT profile.

I have tried some different variation of sending PATCH requests to modify some data like the “country” or “cover_image”. All of the return the 405 response for method not allowed.

First off, do you support any updates via POST etc, because i could only find GET request examples?
if the answer above is yes, what fields are able to be updated?

Thanks,
Brandon


#2

Hi Brandon,
happy to have your feedback.
The Data API are supposed to be used only to retrieve data.
That’s why POST, PATCH, PUT (and obviously DELETE) methods are not provided by the Data API.

Cheers
Lore


#3

Hi,

Thanks for the reply, even if the question might have seemed stupid but i am generally interested.

Have you considered allowing restricted PATCH requests to update certain fields?

Best Regards,
Brandon


#4

We are considering it and will increase the scope of the APIs based on proposed use cases. We already released the first POST int eh Chat API (to send messages to a specific room), but we are planning to more general use cases (the first ones we are looking at are changing / adding roles to users as well as joining hubs).

If you tell us the use cases you have in mind we can evaluate internally whether it’s something we can prioritize :slight_smile:


#5

Hi nvm,

Thank you for the quick replies!
Currently i don’t have a specific reason, i just want to test the API limits before i start on a little project.

Knowing the limits is the best place to start.

If you wanted an example of what i had in mind:
PATCH request to update the each player avatar & cover image in a team to be as specified.

I have no idea how it would be possible to update a player profile though (how would you auth that you have access to that account to send the PATCH? idk) anyway…

Many Thanks,
Brandon


#6

Technically I guess we could do it by adding a scope to the Oauth that the users agree to. Not sure if it is as high priority as others (join hub, manage roles etc.) in the pipeline though.


#7

Yeah, just some food for thought anyway.

Thanks a bunch! :slight_smile: