Bungie-net / api

Resources for the Bungie.net API
Other
1.22k stars 92 forks source link

Can't search by destiny name players #1677

Closed hugos closed 2 years ago

hugos commented 2 years ago

I'm using this GET request https://www.bungie.net/Platform/Destiny2/SearchDestinyPlayer/-1/itheomars

However I always get this response besides having my api key:

{
    "Response": [],
    "ErrorCode": 1,
    "ThrottleSeconds": 0,
    "ErrorStatus": "Success",
    "Message": "Ok",
    "MessageData": {}
}
soren42 commented 2 years ago

I did some digging and some testing. That endpoint doesn't appear in the documentation anymore. I could still get it to work, but only with exact matches. (For example, searching for "Soren#9399".) A couple things on that one: 1) it seems to require a trailing /, and 2) the search term needs to be URL encoded.

Regardless, it looks like that endpoint has been deprecated in favour of this one (SearchDestinyPlayerByBungieName). That's the only search endpoint in the current documentation, so the deprecation is an assumption on my part... but it seems to be the case.

Hopefully this helps!

hugos commented 2 years ago

I did some digging and some testing. That endpoint doesn't appear in the documentation anymore. I could still get it to work, but only with exact matches. (For example, searching for "Soren#9399".) A couple things on that one: 1) it seems to require a trailing /, and 2) the search term needs to be URL encoded.

Regardless, it looks like that endpoint has been deprecated in favour of this one (SearchDestinyPlayerByBungieName). That's the only search endpoint in the current documentation, so the deprecation is an assumption on my part... but it seems to be the case.

Hopefully this helps!

Yup, it did!! Cheers mate