MP3: API/SDK Version 5.x

Maniaplanet public API, ManiaConnect system and the open source PHP SDK.

Moderator: NADEO

User avatar
magnetik
Posts: 1673
Joined: 01 Feb 2012, 19:13
Location: Bordeaux
Contact:

Re: API/SDK Version 4.x

Post by magnetik »

updated with 4.0 :

Only one object for all rankings: \Maniaplanet\WebServices\Rankings

All methods take the title id (string) as first parameter to specify the title.

(Api endpoint does not change)
ManiaPlanet technical documentation portal (Dedicated, ManiaLink, ManiaScript, Titles...) -- contribute!
User avatar
magnetik
Posts: 1673
Joined: 01 Feb 2012, 19:13
Location: Bordeaux
Contact:

Re: API/SDK Version 4.x

Post by magnetik »

Updated to 4.1

Incoming change on the API: Elite rankings will be moved on a separate endpoint : /elite/rankings/...
(Just like royal).

You can upgrade to SDK 4.1 with allows you to use only one class for all rankings.
ManiaPlanet technical documentation portal (Dedicated, ManiaLink, ManiaScript, Titles...) -- contribute!
User avatar
Xymph
Posts: 1399
Joined: 15 Jun 2010, 20:35
Contact:

Re: API/SDK Version 4.x

Post by Xymph »

magnetik wrote:Incoming change on the API: Elite rankings will be moved on a separate endpoint : /elite/rankings/...
(Just like royal).
Thanks, could you do the same for TM2C Platform multiplayer?

And would it be possible to add a method that returns a up-to-date list of all titleIds that are supported for rankings? Or preferably two separate lists for solo and multiplayer rankings?

These would help me generalise my MetaStats page to all ManiaPlanet titles, not just TM2C.

Also, in class Rankings the first method's description is "Get player ranking for the give title", which should be "Get player ranking for the given title" (or even "...player's multiplayer ranking..."). Descriptions for the other methods would be nice as well.
Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
User avatar
magnetik
Posts: 1673
Joined: 01 Feb 2012, 19:13
Location: Bordeaux
Contact:

Re: API/SDK Version 4.x

Post by magnetik »

The change has been made to reflect our internal architecture. It's quite not logical for you (API users) but we have no choice for now.

You can have the list of different rankings endpoint in the SDK line 137+.

You can access al other titles on the /titles/ endpoint.

No other titles will be moved to another endpoint for now.

I've added "SDK documentation" on my todo list.
ManiaPlanet technical documentation portal (Dedicated, ManiaLink, ManiaScript, Titles...) -- contribute!
User avatar
Xymph
Posts: 1399
Joined: 15 Jun 2010, 20:35
Contact:

Re: API/SDK Version 4.x

Post by Xymph »

magnetik wrote:The change has been made to reflect our internal architecture. It's quite not logical for you (API users) but we have no choice for now.

You can have the list of different rankings endpoint in the SDK line 137+.

You can access al other titles on the /titles/ endpoint.

No other titles will be moved to another endpoint for now.
Okay, but I am not really concerned with endpoints and which titleIds have their own or not -- that's up to you. I did see the switch statement but that doesn't help to automate things.

In order to look up rankings for a login on all official titleIds, it would be helpful to be able to 'get' a list (or two) of those, so that I don't have to update my script again once TMValley or another SM env or QuestMania comes out. But I guess I'll just maintain those lists in the script then.
magnetik wrote:I've added "SDK documentation" on my todo list.
Thanks.
Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
User avatar
steeffeen
Translator
Translator
Posts: 2463
Joined: 14 Oct 2012, 16:22
Location: Germany

Re: API/SDK Version 4.x

Post by steeffeen »

i know it's kind of unimportant but i think cleaning up the maniaconnect and web service packages would be great
  • there are some files in the web service package which are obsolete or empty
  • the few web service files included in manialib are just old as hell and this stuff inside the manialib package has been really confusing for some users ;)
not to mention that some examples might not work anymore (i don't care about these though ^^)
    Game Mode and Title Pack Creator, Developer, ShootMania-Player & more

    ManiaControl, FancyManiaLinks
    User avatar
    Xymph
    Posts: 1399
    Joined: 15 Jun 2010, 20:35
    Contact:

    Re: API/SDK Version 4.x

    Post by Xymph »

    magnetik wrote:updated with 4.0 :

    Only one object for all rankings: \Maniaplanet\WebServices\Rankings

    All methods take the title id (string) as first parameter to specify the title.
    With the getSoloPlayer method for, say, titleId TMStadium, the 'environment' property returned is Stadium (no TM).
    With the getMultiplayerPlayer method for titleId TMStadium, the 'environment' property returned is TMStadium.
    Same for [TM]Canyon.

    Can you please make the Solo environment property consistent with the Multiplayer one? Thanks.
    Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
    Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
    User avatar
    Xymph
    Posts: 1399
    Joined: 15 Jun 2010, 20:35
    Contact:

    Re: API/SDK Version 4.x

    Post by Xymph »

    Another question: are the number of stars and stardays for a player login already available via the API? Or can they be added to the Players->get results (or as a new method)? Thanks.
    Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
    Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
    User avatar
    magnetik
    Posts: 1673
    Joined: 01 Feb 2012, 19:13
    Location: Bordeaux
    Contact:

    Re: API/SDK Version 4.x

    Post by magnetik »

    I can add the number of stars but I think it will be on a seperated endpoint.

    I've added this to my list :thumbsup:
    ManiaPlanet technical documentation portal (Dedicated, ManiaLink, ManiaScript, Titles...) -- contribute!
    User avatar
    Xymph
    Posts: 1399
    Joined: 15 Jun 2010, 20:35
    Contact:

    Re: API/SDK Version 4.x

    Post by Xymph »

    magnetik wrote:I can add the number of stars but I think it will be on a separate endpoint.
    Okay, but not the number of starday votes? That was available via the TMN ESWC "API" too.
    magnetik wrote:I've added this to my list
    Coolio.
    Developer of XASECO for TMF/TMN ESWC & XASECO2 for TM²: see XAseco.org
    Find your way around the Mania community from the TMN ESWC hub, TMF hub, TM² hub, and SM hub
    Post Reply

    Return to “Maniaplanet Web Services”

    Who is online

    Users browsing this forum: No registered users and 0 guests