Bungie-net / api

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

Question: How to get a list of (ideally recent) activities that are all one type (Ex. Just raids, just dungeons, etc..) #1820

Open nsmith31415 opened 1 year ago

nsmith31415 commented 1 year ago

I'd like to sift through specific recently-completed activities. Whether that be sorted by type (raid/dungeon/nightfall/etc) or by activity name (Root of Nightmares, Vow of the Disciple, Spire of the Watcher, The Arms Dealer, etc...) would be helpful.

The best way I can do that so far (to my knowledge) is to simply loop through activities based on their ID and then check what activity it was. That requires several API calls per raid/dungeon - activity I'm interested in. I would like to only need to send one request to get a list of activities I'm interested in, and then one request per activity to get the additional details. Is this possible? Possible in the future? If this isn't something I can do now, is it possible if I learn the openAI details on the README?

Any advice is greatly appreciated!

nsmith31415 commented 1 year ago

After reading this issue, it seems like the activity IDs aren't generated until several minutes after activity completion, which counteracts the use I'm looking for.

Is there a better way to access guardian info mere seconds after they complete an activity?

Mijago commented 1 year ago

No, sadly you have to wait.

The only Info you can get right away is https://bungie-net.github.io/multi/schema_Destiny-Components-Profiles-DestinyProfileTransitoryComponent.html#schema_Destiny-Components-Profiles-DestinyProfileTransitoryComponent, which you get from the GetProfile endpoint.

nsmith31415 commented 1 year ago

Any chance you know how to get the membership ID from the display name? I've seen applications that do this, like https://raid.report, but I haven't figured out what they're doing to convert that display name into bungie membership ID

Mijago commented 1 year ago

Raid report has their own elastic api that solves it for them, even with

There's a Bungie endpoint, but as far as I know you need to know the entire name, including the #1234 part.

Probably this one: https://bungie-net.github.io/multi/operation_post_Destiny2-SearchDestinyPlayerByBungieName.html#operation_post_Destiny2-SearchDestinyPlayerByBungieName

(currently on my phone).

Check out https://data.destinysets.com - they have an api browser to play around with :)

nsmith31415 commented 1 year ago

Do you know how to grab someone's current subclass information? (Current subclass, aspects, fragments, etc) I haven't been able to find the right API endpoint to call for this. I was able to access the "Loadouts" information through the get profile/get character endpoint, but I was only receiving information about the armor equips. Nothing about the subclass info.

(Also - I appreciate the help and advice you're given so far! Thank you very much!)