Services return types documentation

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

Moderator: NADEO

User avatar
m4rcel
Posts: 653
Joined: 15 Jun 2010, 11:12
Contact:

Services return types documentation

Post by m4rcel » 08 Sep 2011, 20:28

This post is an overview of all the data structures which are returned from all the methods of the Maniaplanet WebService. The classes are sorted by their name, and the order of the methods within each class is the same as in the source files of the SDK. If several methods return the same structure, they got grouped together and the structure is only listed once.


This post is not a full documentation of the SDK but of the return types only. Whereas almost all methods are listed, the post lacks information to the parameters which must or may be passed to them. To get additional information to them, have a look at the generated documentation of the SDK.


Some information is still missing. For example, I did not figure out the meanings of all the fields, mostly because they always were empty during my tests. If you see any missing (or wrong) information, feel free to contact me so that I can correct them. Additionally, I did not have the time to look into the Competitions yet, so I cannot list the return data structure for the methods of this class. If you are using methods with missing information, feel free to send me a of the return value, so I can look into it and can add it to the list ;)


Last Update: 22.11.2013
SDK-Version: 4.2

Maniaplanet\WebServices\Competitions
  • getMapPool($competitionId)
  • getInvitationKey($competitionId, [...])
  • inviteTeam($competitionId, $teamId)
  • removeTeam($competitionId, $teamId)
  • create($name, $titleIdString, $isLan, [...])
  • update($id, $name, $titleIdString, $isLan, [...])
  • registerResults($competitionId, array $results)
    Unknown return data structure...
Maniaplanet\WebServices\Links
  • createForTeam($teamId, $link, $name, $category, [...])
  • createForCompetition($competitionId, $link, $name, $category, [...])
    Unknown return data structure...
Maniaplanet\WebServices\ManiaConnect\Player
  • getPlayer()
    Requires Scope: basic
    Returns: object containing the following fields:
    • id: int - The ID of the player.
    • login: string - The login of the player.
    • nickname: string - The nick of the player, including the $-formats.
    • path: string - The path of the player, zones are separated with |.
    • idZone: int - The ID of the player's zone
  • getOnlineStatus()
    Requires Scope: online_status
    Returns: object containing the following fields:
    • online: boolean - Whether the player is currently online in the game.
    • login: string - The login of the player.
    • nickname: string - The nickname of the player.
    • serverLogin: string - The login of the server the player is currently playing on.
    • serverName: string - The name of the server the player is currently playing on.
    • serverJoinManialink: string - The ManiaLink to join the server the player is currently playing on.
  • getEmail()
    Requires Scope: email
    Returns: string - The email address.
  • getBuddies()
    Requires Scope: buddies
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the player.
    • login: string - The login of the player.
    • nickname: string - The nick of the player, including the $-formats.
    • path: string - The path of the player, zones are separated with |.
    • idZone: int - The ID of the player's zone
  • getDedicated()
    Requires Scope: dedicated
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the server.
    • login: string - The login of the server account.
    • owner: string - The login of the owning player.
    • serverName: string - The name of the server, including the $-formats.
    • description: string - The description of the server.
    • isOnline: boolean - Whether this server is currently online.
    • isDedicated: boolean - Whether this server is a dedicated server.
    • mapsList: array of string - The list of maps on the server.
    • idZone: int - The ID of the zone of the server.
    • playerCount: int - The number of players currently playing on the server.
    • maxPlayerCount: int - The maximal number of players allowed on the server.
    • titleId: int - The ID of the title played on the server.
    • isPrivate: boolean - Whether this server is a private server.
    • scriptName: string - The name of the script used by the server.
    • scriptVersion: string - The version of the script, format is 'YYYY-MM-DD'.
    • scriptTeam: boolean - Whether the script is using team mode.
    • isLadder: boolean - Whether this server is a ladder server.
    • isLobby: boolean - Whether this server is a lobby server.
    • ladderLimitMax: float - The upper ladder limit of the server.
    • ladderLimitMin: float - The lower ladder limit of the server.
    • adequacy: unknown field...
    • buildVersion: string - The build version of the server, format is 'YYYY-MM-DD_HH_MM'.
    • broadcasters: unknown field...
    • relayOf: unknown field...
    • ladderPointsAvg: float - The average ladder points of the players on the server.
    • ladderPointsMin: float - The minimal ladder points of the players on the server.
    • ladderPointsMax: float - The maximal ladder points of the players on the server.
    • zone: object containing the following fields:
      • id: int - The ID of the zone.
      • name: string - The name of the zone.
      • path: string - The path of the zone, separated with |.
      • iconDDSURL: string - The URL of the DDS icon of the zone, may be null.
      • iconURL: string - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • iconJPEGURL: string - The URL of the JPEG icon of the zone, may be empty.
      • pathIds: string - The IDs of the zones in the path of this zone.
    • title: object containing the following fields:
      • id: int - The ID of the title.
      • idString: string - The ID-String of the title.
      • name: string - The name of the title.
      • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
      • web: string - The website of the title.
      • cost: string - The cost of the title.
      • environment: unknown field...
      • dependencies: array of string - The titles this title depends on.
  • getReportAbuses($serverLogin)
    Requires Scope: dedicated
    Unknown return data structure...
  • getManialinks()
    Requires Scope: manialinks
    Returns: array of array of string - The ManiaLinks owned by the player.
  • getContracts()
    Requires Scope: teams
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the team contract.
    • teamId: int - The ID of the team involved in the contract.
    • team: object containing the following fields:
      • id: int - The id of the team.
      • creatorLogin: string - The login of the creator of the team.
      • tag: string - The tag of the team.
      • level: int - The level of the team.
      • name: string - The name of the team.
      • primaryColor: string - The primary color of the team, format RGB in hex.
      • secondaryColor: string - The secondary color of the team, format RGB in hex.
      • description: string - The description of the team.
      • emblem: string - The URL to the emblem image of the team.
      • emblemWeb: string - The URL to the emblem image of the team for the web.
      • logo: string - The URL to the logo of the team.
      • creationDate: object containing the following fields:
        • date: string - The date of creation, format is YYYY-MM-DD HH:MM:SS.
        • timezone_type: int - The timezone as id, seems to always be 3.
        • timezone: string - The timezone as string, seems to always be 'Europe/Berlin'
      • city: string - The city of the team.
      • zoneId: int - The id of the zone of the team.
      • zone: object containing the following fields:
        • id: int - The ID of the zone.
        • name: string - The name of the zone.
        • path: string - The path of the zone, separated with |.
        • iconDDSURL: string - The URL of the DDS icon of the zone, may be null.
        • iconURL: string - The URL of the icon of the zone, can be either a DDS or a JPEG.
        • iconJPEGURL: string - The URL of the JPEG icon of the zone, may be empty.
        • pathIds: string - The IDs of the zones in the path of this zone.
      • titleId: int - The id of the title of the team.
      • title: object containing the following fields:
        • id: int - The ID of the title.
        • idString: string - The ID-String of the title.
        • name: string - The name of the title.
        • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
        • web: string - The website of the title.
        • cost: string - The cost of the title.
        • environment: unknown field...
        • dependencies: array of string - The titles this title depends on.
      • rank: unknown field...
      • score: unknown field...
      • points: unknown field...
      • ladderPoints: int - The ladder points of the team.
      • teamSize: int - The size of the team.
      • maxTeamSize: int - The maximal size of the team.
      • minTeamSize: int - The minimal size of the team.
      • deleted: boolean - Whether the team has been deleted.
    • login: string - The login of the player involved in the contract.
    • player: object containing the following fields:
      • id: int - The ID of the player.
      • login: string - The login of the player.
      • nickname: string - The nick of the player, including the $-formats.
      • path: string - The path of the player, zones are separated with |.
      • idZone: int - The ID of the player's zone
    • state: int - The state of the contract, concrete values unknown.
    • date: object containing the following fields:
      • date: string - The date of the contract, format is 'YYYY-MM-DD HH:MM:SS'.
      • timezone_type: int - The timezone as id, seems to always be 3.
      • timezone: string - The timezone as string, seems to always be 'Europe/Berlin'
  • getTeams()
    Requires Scope: teams
    Returns: array of object, each element containing the following fields:
    • id: int - The id of the team.
    • creatorLogin: string - The login of the creator of the team.
    • tag: string - The tag of the team.
    • level: int - The level of the team.
    • name: string - The name of the team.
    • primaryColor: string - The primary color of the team, format RGB in hex.
    • secondaryColor: string - The secondary color of the team, format RGB in hex.
    • description: string - The description of the team.
    • emblem: string - The URL to the emblem image of the team.
    • emblemWeb: string - The URL to the emblem image of the team for the web.
    • logo: string - The URL to the logo of the team.
    • creationDate: object containing the following fields:
      • date: string - The date of creation, format is YYYY-MM-DD HH:MM:SS.
      • timezone_type: int - The timezone as id, seems to always be 3.
      • timezone: string - The timezone as string, seems to always be 'Europe/Berlin'
    • city: string - The city of the team.
    • zoneId: int - The id of the zone of the team.
    • zone: object containing the following fields:
      • id: int - The ID of the zone.
      • name: string - The name of the zone.
      • path: string - The path of the zone, separated with |.
      • iconDDSURL: string - The URL of the DDS icon of the zone, may be null.
      • iconURL: string - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • iconJPEGURL: string - The URL of the JPEG icon of the zone, may be empty.
      • pathIds: string - The IDs of the zones in the path of this zone.
    • titleId: int - The id of the title of the team.
    • title: object containing the following fields:
      • id: int - The ID of the title.
      • idString: string - The ID-String of the title.
      • name: string - The name of the title.
      • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
      • web: string - The website of the title.
      • cost: string - The cost of the title.
      • environment: unknown field...
      • dependencies: array of string - The titles this title depends on.
    • rank: unknown field...
    • score: unknown field...
    • points: unknown field...
    • ladderPoints: int - The ladder points of the team.
    • teamSize: int - The size of the team.
    • maxTeamSize: int - The maximal size of the team.
    • minTeamSize: int - The minimal size of the team.
    • deleted: boolean - Whether the team has been deleted.
  • getOwnedTitles()
    Requires Scope: titles
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the title.
    • idString: string - The ID-String of the title.
    • name: string - The name of the title.
    • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
    • web: string - The website of the title.
    • cost: string - The cost of the title.
    • environment: unknown field...
    • dependencies: array of string - The titles this title depends on.
  • getInstalledTitles()
    Requires Scope: titles
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the title.
    • idString: string - The ID-String of the title.
    • name: string - The name of the title.
    • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
    • web: string - The website of the title.
    • cost: string - The cost of the title.
    • environment: unknown field...
    • dependencies: array of string - The titles this title depends on.
  • getFavoriteServers()
    Requires Scope: favorite_servers
    Unknown return data structure...
Maniaplanet\WebServices\ManiaFlash
  • getChannel($id)
    Returns: object containing the following fields:
    • id: string - The ID of the channel.
    • name: string - The name of the channel.
    • description: string - The description of the channel.
  • getMessages($id, [...])
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the message.
    • login: string - The login of the author of the message.
    • dateCreated: string - The date when the message has been created, format is 'YYYY-MM-DD HH:MM:SS'.
    • message: string - The actual message.
    • link: string - The link associated with the message.
    • iconStyle: string - The style of the icon of the message.
    • iconSubStyle: string - The substyle of the icon of the message.
    • mediaURL: string - The URL of the image used instead of the icon.
  • postMessage($channelId, $message, [...])
    Returns: boolean - Whether posting the message has succeeded.
Maniaplanet\WebServices\ManiaHome\Comments
  • count($notificationId)
    Returns: int - The number of comments of the specified notification.
Maniaplanet\WebServices\ManiaHome\ManialinkPublisher
  • postPublicNotification($message, [...])
  • postPersonalNotification($message, $receiverName, [...])
  • postPrivateNotification($message, $receiverName, [...])
    Returns: int - The ID of the created notification.
  • postPrivateEvent($message, $eventDate, $receiverName, [...])
  • postPublicEvent($message, $eventDate, [...])
    Returns: int - The ID of the created event.
Maniaplanet\WebServices\ManiaHome\ServerPublisher
  • postPublicNotification($message, [...])
  • postPersonalNotification($message, $receiverName, [...])
  • postPrivateNotification($message, $receiverName, [...])
    Returns: int - The ID of the created notification.
  • postPrivateEvent($message, $eventDate, $receiverName, [...])
  • postPublicEvent($message, $eventDate, [...])
    Returns: int - The ID of the created event.
Maniaplanet\WebServices\Manialinks
  • get($code)
    Returns: object containing the following fields:
    • code: string - The code of the ManiaLink.
    • url: string - The URL of the ManiaLink.
    • planetCost: int - The planet cost of this ManiaLink.
    • login: string - The login of the owner of this ManiaLink.
Maniaplanet\WebServices\Payments
  • create($transaction)
    Returns: int - The ID of the created transaction.
  • isPaid($id)
    Returns: boolean - Whether the transaction has been paid.
  • pay($transaction)
    Returns: Nothing
Maniaplanet\WebServices\Players
  • get($login)
    Returns: object containing the following fields:
    • id: int - The ID of the player.
    • login: string - The login of the player.
    • nickname: string - The nick of the player, including the $-formats.
    • path: string - The path of the player, zones are separated with |.
    • idZone: int - The ID of the player's zone
  • getManiaStars($login)
    Returns: int - The ManiaStars of the player.
Maniaplanet\WebServices\Rankings
  • getMultiplayerPlayer($titleId, $login)
    Returns: object containing the following fields:
    • environment: string - The ID-String fo the title of the rank.
    • unit: string - The unit of the rank.
    • points: float - The points of the rank.
    • ranks: array of object, each element containing the following fields:
      • idZone: int - The ID of the zone of the rank.
      • path: string - The path of the zone, separated with |.
      • rank: int - The actual rank in the zone.
    • environment: string - The ID-String fo the title of the rank.
    • unit: string - The unit of the rank, either 'Ladder Points' or 'Skill Points'.
    • points: float - The points of the rank.
    • ranks: array of object, each element containing the following fields:
      • idZone: int - The ID of the zone of the rank.
      • path: string - The path of the zone, separated with |.
      • rank: int - The actual rank in the zone.
  • getMultiplayerWorld($titleId, [...])
  • getMultiplayerZone($titleId, $path, [...])
    Returns: object containing the following fields:
    • idZone: int - The ID of the zone.
    • path: string - The path of the zone, separated with |.
    • environment: string - The ID-String fo the title of the ranks.
    • unit: string - The unit of the ranks.
    • players: array of object, each element containing the following fields:
      • rank: int - The actual rank of the player.
      • points: float - The points of the rank.
      • player: object containing the following fields:
        • id: int - The ID of the player.
        • login: string - The login of the player.
        • nickname: string - The nick of the player, including the $-formats.
        • path: string - The path of the player, zones are separated with |.
        • idZone: int - The ID of the player's zone
  • getSoloPlayer($titleId, $login)
    Returns: object containing the following fields:
    • environment: string - The ID-String fo the title of the rank.
    • unit: string - The unit of the rank.
    • points: float - The points of the rank.
    • ranks: array of object, each element containing the following fields:
      • idZone: int - The ID of the zone of the rank.
      • path: string - The path of the zone, separated with |.
      • rank: int - The actual rank in the zone.
    • environment: string - The ID-String fo the title of the rank.
    • unit: string - The unit of the rank, either 'Ladder Points' or 'Skill Points'.
    • points: float - The points of the rank.
    • ranks: array of object, each element containing the following fields:
      • idZone: int - The ID of the zone of the rank.
      • path: string - The path of the zone, separated with |.
      • rank: int - The actual rank in the zone.
  • getSoloWorld($titleId, [...])
  • getSoloZone($titleId, $path, [...])
    Returns: object containing the following fields:
    • idZone: int - The ID of the zone.
    • path: string - The path of the zone, separated with |.
    • environment: string - The ID-String fo the title of the ranks.
    • unit: string - The unit of the ranks.
    • players: array of object, each element containing the following fields:
      • rank: int - The actual rank of the player.
      • points: float - The points of the rank.
      • player: object containing the following fields:
        • id: int - The ID of the player.
        • login: string - The login of the player.
        • nickname: string - The nick of the player, including the $-formats.
        • path: string - The path of the player, zones are separated with |.
        • idZone: int - The ID of the player's zone
  • getSoloChallengeWorld($titleId, $challengeuid, [...])
  • getSoloChallengeZone($titleId, $challengeuid, $path, [...])
    Returns: object containing the following fields:
    • idZone: int - The ID of the zone of the ranks.
    • path: string - The path of the zone, separated with |.
    • environment: string - The ID-String fo the title of the ranks.
    • challengeUID: string - The unique ID of the challenge.
    • gameMode: string - The game mode of the challenge.
    • unit: string - The unit of the ranks.
    • players: array of object, each element containing the following fields:
      • rank: int - The actual rank of the player.
      • points: float - The points of the rank.
      • player: object containing the following fields:
        • id: int - The ID of the player.
        • login: string - The login of the player.
        • nickname: string - The nick of the player, including the $-formats.
        • path: string - The path of the player, zones are separated with |.
        • idZone: int - The ID of the player's zone
Maniaplanet\WebServices\Servers
  • get($login)
    Returns: object containing the following fields:
    • id: int - The ID of the server.
    • login: string - The login of the server account.
    • owner: string - The login of the owning player.
    • serverName: string - The name of the server, including the $-formats.
    • description: string - The description of the server.
    • isOnline: boolean - Whether this server is currently online.
    • isDedicated: boolean - Whether this server is a dedicated server.
    • mapsList: array of string - The list of maps on the server.
    • idZone: int - The ID of the zone of the server.
    • playerCount: int - The number of players currently playing on the server.
    • maxPlayerCount: int - The maximal number of players allowed on the server.
    • titleId: int - The ID of the title played on the server.
    • isPrivate: boolean - Whether this server is a private server.
    • scriptName: string - The name of the script used by the server.
    • scriptVersion: string - The version of the script, format is 'YYYY-MM-DD'.
    • scriptTeam: boolean - Whether the script is using team mode.
    • isLadder: boolean - Whether this server is a ladder server.
    • isLobby: boolean - Whether this server is a lobby server.
    • ladderLimitMax: float - The upper ladder limit of the server.
    • ladderLimitMin: float - The lower ladder limit of the server.
    • adequacy: unknown field...
    • buildVersion: string - The build version of the server, format is 'YYYY-MM-DD_HH_MM'.
    • broadcasters: unknown field...
    • relayOf: unknown field...
    • ladderPointsAvg: float - The average ladder points of the players on the server.
    • ladderPointsMin: float - The minimal ladder points of the players on the server.
    • ladderPointsMax: float - The maximal ladder points of the players on the server.
    • zone: object containing the following fields:
      • id: int - The ID of the zone.
      • name: string - The name of the zone.
      • path: string - The path of the zone, separated with |.
      • iconDDSURL: string - The URL of the DDS icon of the zone, may be null.
      • iconURL: string - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • iconJPEGURL: string - The URL of the JPEG icon of the zone, may be empty.
      • pathIds: string - The IDs of the zones in the path of this zone.
    • title: object containing the following fields:
      • id: int - The ID of the title.
      • idString: string - The ID-String of the title.
      • name: string - The name of the title.
      • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
      • web: string - The website of the title.
      • cost: string - The cost of the title.
      • environment: unknown field...
      • dependencies: array of string - The titles this title depends on.
  • getOnlinePlayers($login)
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the player.
    • login: string - The login of the player.
    • nickname: string - The nick of the player, including the $-formats.
    • path: string - The path of the player, zones are separated with |.
    • idZone: int - The ID of the player's zone
  • getFavoritedCount($login)
    Returns: int - The number of players having the server favorited.
  • getReportAbuses($login)
    Unknown return data structure...
  • getFilteredList($filteredList = array())
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the server.
    • login: string - The login of the server account.
    • owner: string - The login of the owning player.
    • serverName: string - The name of the server, including the $-formats.
    • description: string - The description of the server.
    • isOnline: boolean - Whether this server is currently online.
    • isDedicated: boolean - Whether this server is a dedicated server.
    • mapsList: array of string - The list of maps on the server.
    • idZone: int - The ID of the zone of the server.
    • playerCount: int - The number of players currently playing on the server.
    • maxPlayerCount: int - The maximal number of players allowed on the server.
    • titleId: int - The ID of the title played on the server.
    • isPrivate: boolean - Whether this server is a private server.
    • scriptName: string - The name of the script used by the server.
    • scriptVersion: string - The version of the script, format is 'YYYY-MM-DD'.
    • scriptTeam: boolean - Whether the script is using team mode.
    • isLadder: boolean - Whether this server is a ladder server.
    • isLobby: boolean - Whether this server is a lobby server.
    • ladderLimitMax: float - The upper ladder limit of the server.
    • ladderLimitMin: float - The lower ladder limit of the server.
    • adequacy: unknown field...
    • buildVersion: string - The build version of the server, format is 'YYYY-MM-DD_HH_MM'.
    • broadcasters: unknown field...
    • relayOf: unknown field...
    • ladderPointsAvg: float - The average ladder points of the players on the server.
    • ladderPointsMin: float - The minimal ladder points of the players on the server.
    • ladderPointsMax: float - The maximal ladder points of the players on the server.
    • zone: object containing the following fields:
      • id: int - The ID of the zone.
      • name: string - The name of the zone.
      • path: string - The path of the zone, separated with |.
      • iconDDSURL: string - The URL of the DDS icon of the zone, may be null.
      • iconURL: string - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • iconJPEGURL: string - The URL of the JPEG icon of the zone, may be empty.
      • pathIds: string - The IDs of the zones in the path of this zone.
    • title: object containing the following fields:
      • id: int - The ID of the title.
      • idString: string - The ID-String of the title.
      • name: string - The name of the title.
      • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
      • web: string - The website of the title.
      • cost: string - The cost of the title.
      • environment: unknown field...
      • dependencies: array of string - The titles this title depends on.
Maniaplanet\WebServices\Teams
  • get($id)
    Returns: object containing the following fields:
    • id: int - The id of the team.
    • creatorLogin: string - The login of the creator of the team.
    • tag: string - The tag of the team.
    • level: int - The level of the team.
    • name: string - The name of the team.
    • primaryColor: string - The primary color of the team, format RGB in hex.
    • secondaryColor: string - The secondary color of the team, format RGB in hex.
    • description: string - The description of the team.
    • emblem: string - The URL to the emblem image of the team.
    • emblemWeb: string - The URL to the emblem image of the team for the web.
    • logo: string - The URL to the logo of the team.
    • creationDate: object containing the following fields:
      • date: string - The date of creation, format is YYYY-MM-DD HH:MM:SS.
      • timezone_type: int - The timezone as id, seems to always be 3.
      • timezone: string - The timezone as string, seems to always be 'Europe/Berlin'
    • city: string - The city of the team.
    • zoneId: int - The id of the zone of the team.
    • zone: object containing the following fields:
      • id: int - The ID of the zone.
      • name: string - The name of the zone.
      • path: string - The path of the zone, separated with |.
      • iconDDSURL: string - The URL of the DDS icon of the zone, may be null.
      • iconURL: string - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • iconJPEGURL: string - The URL of the JPEG icon of the zone, may be empty.
      • pathIds: string - The IDs of the zones in the path of this zone.
    • titleId: int - The id of the title of the team.
    • title: object containing the following fields:
      • id: int - The ID of the title.
      • idString: string - The ID-String of the title.
      • name: string - The name of the title.
      • isCustom: boolean - Whether this is a custom (i.e. user-made) title.
      • web: string - The website of the title.
      • cost: string - The cost of the title.
      • environment: unknown field...
      • dependencies: array of string - The titles this title depends on.
    • rank: unknown field...
    • score: unknown field...
    • points: unknown field...
    • ladderPoints: int - The ladder points of the team.
    • teamSize: int - The size of the team.
    • maxTeamSize: int - The maximal size of the team.
    • minTeamSize: int - The minimal size of the team.
    • deleted: boolean - Whether the team has been deleted.
  • getContracts($id)
    Returns: array of object, each element containing the following fields:
    • id: int - The ID of the team contract.
    • teamId: int - The ID of the team involved in the contract.
    • team: object containing the following fields:
      • id: int - The id of the team.
      • creatorLogin: string - The login of the creator of the team.
      • tag: string - The tag of the team.
      • level: int - The level of the team.
      • name: string - The name of the team.
      • primaryColor: string - The primary color of the team, format RGB in hex.
      • secondaryColor: string - The secondary color of the team, format RGB in hex.
      • description: string - The description of the team.
      • emblem: string - The URL to the emblem image of the team.
      • emblemWeb: string - The URL to the emblem image of the team for the web.
      • logo: string - The URL to the logo of the team.
      • creationDate: object containing the following fields:
        • date: string - The date of creation, format is YYYY-MM-DD HH:MM:SS.
        • timezone_type: int - The timezone as id, seems to always be 3.
        • timezone: string - The timezone as string, seems to always be 'Europe/Berlin'
      • city: string - The city of the team.
      • zoneId: int - The id of the zone of the team.
      • zone: object containing the following fields:
        • id: int - The ID of the zone.
        • [b]name[/b]: [b]string[/b] - The name of the zone.
        • [b]path[/b]: [b]string[/b] - The path of the zone, separated with |.
        • [b]iconDDSURL[/b]: [b]string[/b] - The URL of the DDS icon of the zone, may be null.
        • [b]iconURL[/b]: [b]string[/b] - The URL of the icon of the zone, can be either a DDS or a JPEG.
        • [b]iconJPEGURL[/b]: [b]string[/b] - The URL of the JPEG icon of the zone, may be empty.
        • [b]pathIds[/b]: [b]string[/b] - The IDs of the zones in the path of this zone.
      • [b]titleId[/b]: [b]int[/b] - The id of the title of the team.
      • [b]title[/b]: [b]object[/b] containing the following fields:
        • [b]id[/b]: [b]int[/b] - The ID of the title.
        • [b]idString[/b]: [b]string[/b] - The ID-String of the title.
        • [b]name[/b]: [b]string[/b] - The name of the title.
        • [b]isCustom[/b]: [b]boolean[/b] - Whether this is a custom (i.e. user-made) title.
        • [b]web[/b]: [b]string[/b] - The website of the title.
        • [b]cost[/b]: [b]string[/b] - The cost of the title.
        • [b]environment[/b]: [b]unknown field...[/b]
        • [b]dependencies[/b]: [b]array[/b] of [b]string[/b] - The titles this title depends on.
      • [b]rank[/b]: [b]unknown field...[/b]
      • [b]score[/b]: [b]unknown field...[/b]
      • [b]points[/b]: [b]unknown field...[/b]
      • [b]ladderPoints[/b]: [b]int[/b] - The ladder points of the team.
      • [b]teamSize[/b]: [b]int[/b] - The size of the team.
      • [b]maxTeamSize[/b]: [b]int[/b] - The maximal size of the team.
      • [b]minTeamSize[/b]: [b]int[/b] - The minimal size of the team.
      • [b]deleted[/b]: [b]boolean[/b] - Whether the team has been deleted.
    • [b]login[/b]: [b]string[/b] - The login of the player involved in the contract.
    • [b]player[/b]: [b]object[/b] containing the following fields:
      • [b]id[/b]: [b]int[/b] - The ID of the player.
      • [b]login[/b]: [b]string[/b] - The login of the player.
      • [b]nickname[/b]: [b]string[/b] - The nick of the player, including the $-formats.
      • [b]path[/b]: [b]string[/b] - The path of the player, zones are separated with |.
      • [b]idZone[/b]: [b]int[/b] - The ID of the player's zone
    • [b]state[/b]: [b]int[/b] - The state of the contract, concrete values unknown.
    • [b]date[/b]: [b]object[/b] containing the following fields:
      • [b]date[/b]: [b]string[/b] - The date of the contract, format is 'YYYY-MM-DD HH:MM:SS'.
      • [b]timezone_type[/b]: [b]int[/b] - The timezone as id, seems to always be 3.
      • [b]timezone[/b]: [b]string[/b] - The timezone as string, seems to always be 'Europe/Berlin'
  • [b]getAdmins($id)[/b]
    Returns: [b]array[/b] of [b]object[/b], each element containing the following fields:
    • [b]id[/b]: [b]int[/b] - The ID of the player.
    • [b]login[/b]: [b]string[/b] - The login of the player.
    • [b]nickname[/b]: [b]string[/b] - The nick of the player, including the $-formats.
    • [b]path[/b]: [b]string[/b] - The path of the player, zones are separated with |.
    • [b]idZone[/b]: [b]int[/b] - The ID of the player's zone
  • [b]getRank($id)[/b]
    Returns: [b]array[/b] of [b]object[/b], each element containing the following fields:
    [b]Maniaplanet\WebServices\Titles[/b]
    • [b]get($idString)[/b]
      Returns: [b]object[/b] containing the following fields:
      • [b]id[/b]: [b]int[/b] - The ID of the title.
      • [b]idString[/b]: [b]string[/b] - The ID-String of the title.
      • [b]name[/b]: [b]string[/b] - The name of the title.
      • [b]isCustom[/b]: [b]boolean[/b] - Whether this is a custom (i.e. user-made) title.
      • [b]web[/b]: [b]string[/b] - The website of the title.
      • [b]cost[/b]: [b]string[/b] - The cost of the title.
      • [b]environment[/b]: [b]unknown field...[/b]
      • [b]dependencies[/b]: [b]array[/b] of [b]string[/b] - The titles this title depends on.
    [b]Maniaplanet\WebServices\TrustCircles[/b]
    • [b]getKarma($circle, $player)[/b]
      Returns: [b]object[/b] containing the following fields:
      • [b]whites[/b]: [b]int[/b] - The number of times the player has been whitelisted.
      • [b]blacks[/b]: [b]int[/b] - The number of times the player has been blacklisted.
    • [b]getBlackList($circle = null)[/b]
    • [b]getWhiteList($circle = null)[/b]
      Returns: [b]object[/b] containing the following fields:
      • [b]login[/b]: [b]string[/b] - The login of the player.
      • [b]count[/b]: [b]int[/b] - The number of times the player has been set on this list.
    • [b]blackList($player)[/b]
    • [b]whiteList($player)[/b]
    • [b]unBlackList($player)[/b]
    • [b]unWhiteList($player)[/b]
      Returns: Nothing
    [b]Maniaplanet\WebServices\Zones[/b]
    • [b]get($id)[/b]
    • [b]getByPath($path)[/b]
      Returns: [b]object[/b] containing the following fields:
      • [b]id[/b]: [b]int[/b] - The ID of the zone.
      • [b]name[/b]: [b]string[/b] - The name of the zone.
      • [b]path[/b]: [b]string[/b] - The path of the zone, separated with |.
      • [b]iconDDSURL[/b]: [b]string[/b] - The URL of the DDS icon of the zone, may be null.
      • [b]iconURL[/b]: [b]string[/b] - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • [b]iconJPEGURL[/b]: [b]string[/b] - The URL of the JPEG icon of the zone, may be empty.
      • [b]pathIds[/b]: [b]string[/b] - The IDs of the zones in the path of this zone.
    • [b]getAll([...])[/b]
    • [b]getChildren($id, [...])[/b]
    • [b]getChildrenByPath($path, [...])[/b]
      Returns: [b]array[/b] of [b]object[/b], each element containing the following fields:
      • [b]id[/b]: [b]int[/b] - The ID of the zone.
      • [b]name[/b]: [b]string[/b] - The name of the zone.
      • [b]path[/b]: [b]string[/b] - The path of the zone, separated with |.
      • [b]iconDDSURL[/b]: [b]string[/b] - The URL of the DDS icon of the zone, may be null.
      • [b]iconURL[/b]: [b]string[/b] - The URL of the icon of the zone, can be either a DDS or a JPEG.
      • [b]iconJPEGURL[/b]: [b]string[/b] - The URL of the JPEG icon of the zone, may be empty.
      • [b]pathIds[/b]: [b]string[/b] - The IDs of the zones in the path of this zone.
    • [b]getId($path)[/b]
      Returns: [b]int[/b] - The id of the zone with the specified path.
    • [b]getPopulation($id)[/b]
      Returns: [b]int[/b] - The number of players in the zone.
    Last edited by m4rcel on 22 Nov 2013, 21:25, edited 5 times in total.
    ImageImage
    Image

    User avatar
    Slig
    Posts: 637
    Joined: 15 Jun 2010, 11:52
    Location: TraXicoLand

    Re: Services return types documentation

    Post by Slig » 27 Sep 2011, 17:29

    Nice and quick update of the api description, thx M4rcel ! :thumbsup:

    User avatar
    Jojo_44
    Posts: 500
    Joined: 12 Jul 2010, 15:58
    Location: Germany->Bavaria
    Contact:

    Re: Services return types documentation

    Post by Jojo_44 » 27 Sep 2011, 18:05

    Vielen Dank ;) :1010

    regards, Jojo
    Image
    my english sounds very unfriendly but it isn´t ;)

    User avatar
    m4rcel
    Posts: 653
    Joined: 15 Jun 2010, 11:12
    Contact:

    Re: Services return types documentation

    Post by m4rcel » 30 Oct 2011, 10:20

    I updated the first post to match the version 1.1 of the SDK, so it should be again up-to-date now ;)
    Mostly only the new Canyon-classes to get the rankings have been added, at least I did not noticed any changes in the other classes ^^
    ImageImage
    Image

    User avatar
    m4rcel
    Posts: 653
    Joined: 15 Jun 2010, 11:12
    Contact:

    Re: Services return types documentation

    Post by m4rcel » 10 Jan 2012, 11:16

    I updated the documentation to the latest version 1.2 of the SDK.

    I found the following changes:
    • New class ManiaHome to send Notifications and Events to ManiaHome. All methods simply return a boolean value whether its execution succeeded.
    • Wherever the details of a Zone is printed, it now includes the URL of the Zone-icon (dds file).
    • In Multiplayer- and SoloRanking, getPlayer() no longer provides the points of the different zones of the player, but the rank within these zones.
    If you find anything else, please feel free to report it ;)
    ImageImage
    Image

    User avatar
    w1lla
    Posts: 2359
    Joined: 15 Jun 2010, 11:09
    Location: Netherlands
    Contact:

    Re: Services return types documentation

    Post by w1lla » 07 Feb 2012, 16:00

    An addition towards the Maniaplanet\WebServices\Zones:


    Maniaplanet\WebServices\Zones
    • get($id)

      Returns: object containing the following fields:
      • id: int - The ID of the zone
      • name: string - The name of the zone
      • path: string - The path of the zone
      • iconURL: string - The URL to the icon of the zone
    • getByPath($path)

      Returns: object containing the following fields:
      • id: int - The ID of the zone
      • name: string - The name of the zone
      • path: string - The path of the zone
      • iconURL: string - The URL to the icon of the zone
    • getAll($offset = 0, $length = 10, $sort = '', $order = '')

      $sort can be listed as: 'id' or 'name'.
      $sort = 'id'; will show all ID's first.
      $sort = 'name' will show all names first beginning with A.
      $order can be listed as '1' or '-1'.
      $order = 1; will show ascending records.
      $order = -1; will show descending records.

      Returns: object containing the following fields
      • id: int - The ID of the zone
      • name: string - The name of the zone
      • path: string - The path of the zone
      • iconURL: string - The URL to the icon of the zone
      • pathIds: string - Shows the ID of the path and the number of the zone. For example: World|France|Ile-de-France = 1,2 as World|France|Ile-de-France|Paris = 1,2,83
    • getChildren($id, $offset = 0, $length = 10, $sort = '', $order = '')

      $sort can be listed as: 'id' or 'name'.
      $sort = 'id'; will show all ID's first.
      $sort = 'name' will show all names first beginning with A.
      $order can be listed as '1' or '-1'.
      $order = 1; will show ascending records.
      $order = -1; will show descending records.

      Returns: object containing the following fields
      • id: int - The ID of the zone
      • name: string - The name of the zone
      • path: string - The path of the zone
      • iconURL: string - The URL to the icon of the zone
      • pathIds: string - Shows the ID of the path and the number of the zone. For example: World|France|Ile-de-France = 1,2 as World|France|Ile-de-France|Paris = 1,2,83
    • getChildrenByPath($path, $offset = 0, $length = 10, $sort = '', $order = '')

      $sort can be listed as: 'id' or 'name'.
      $sort = 'id'; will show all ID's first.
      $sort = 'name' will show all names first beginning with A.
      $order can be listed as '1' or '-1'.
      $order = 1; will show ascending records.
      $order = -1; will show descending records.

      Returns: array of object, each element containing the following fields:
      • id: int - The ID of the zone
      • name: string - The name of the zone
      • path: string - The path of the zone
      • iconURL: string - The URL to the icon of the zone
      • pathIds: string - A comma separated list of the Zone-IDs, beginning with the World-Zone, ending with the Zone's parent
    • getId($path)
      Returns: int - The ID of the zone
    TM² Info
    SM Info
    QM Info

    OS: Windows 10 x64 Professional
    MB: MSI 970A-G46
    Processor: AMD FX-6300 3500 mHz
    RAM Memory: 16 GB DDR3
    Video: SAPPHIRE DUAL-X R9 280X 3GB GDDR5
    KB: Logitech G510s
    Mouse: Logitech G300s
    Mode Creation
    ManiaScript Docs

    User avatar
    m4rcel
    Posts: 653
    Joined: 15 Jun 2010, 11:12
    Contact:

    Re: Services return types documentation

    Post by m4rcel » 04 May 2012, 10:07

    I finally took the time to update the first post to the latest version 1.4 of the MPWS SDK. Main changes are the introduction of the Payments class, and that the ManiaHome methods return the ID of the created Notification or Event. Additionally, I noticed that the objects of Dedicated servers now have a "playerCount" field.


    EDIT: I fixed a little error in the first post: The_Big_Boo pointed out that pay() does not return anything.
    ImageImage
    Image

    User avatar
    Rots
    Translator
    Translator
    Posts: 1134
    Joined: 01 Sep 2010, 14:39
    Location: España, Barcelona

    Re: Services return types documentation

    Post by Rots » 26 Jun 2013, 12:02

    I'm getting started into the mpws api and this is a useful accesible documentation ty m4rcel.

    Since the last modification was almost one year ago It would be useful to know if it is uptodate so I can trust everything.

    Last update was for 1.4 and we are on 4.x.
    Last edited by Rots on 26 Jun 2013, 12:04, edited 1 time in total.
    Image
    Image
    Image
    TrackMania Original brought me here... Here I am since 2006

    User avatar
    steeffeen
    Translator
    Translator
    Posts: 2471
    Joined: 14 Oct 2012, 16:22
    Location: Germany

    Re: Services return types documentation

    Post by steeffeen » 26 Jun 2013, 12:04

    Rots wrote:I'm getting started into the mpws api and this is a useful accesible documentation ty m4rcel.

    Since the last modification was almost one year ago It would be useful to know if it is uptodate so I can trust everything.
    easiest way to check return values is simply dumping them

    Code: Select all

    print_r($result);
    var_dump($result);
      Game Mode and Title Pack Creator, Developer, ShootMania-Player & more

      ManiaControl, FancyManiaLinks

      User avatar
      Rots
      Translator
      Translator
      Posts: 1134
      Joined: 01 Sep 2010, 14:39
      Location: España, Barcelona

      Re: Services return types documentation

      Post by Rots » 26 Jun 2013, 12:06

      Yea I know but I spend time dumping everything to check every single variable. I was wondering if there was already any other doc with the current 4.x. I mean, to see the possibilities of the api
      Image
      Image
      Image
      TrackMania Original brought me here... Here I am since 2006

      Post Reply

      Return to “Maniaplanet Web Services”

      Who is online

      Users browsing this forum: No registered users and 6 guests