« Previous - Version 5/8 (diff) - Next » - Current version
nimetu, 12/18/2013 01:37 pm


guild

Access information from a guild.

Base URL

URL Parameters

apikey

The API Key of the guild.

Cache Duration

The information are cached for 1 hour.
Guild xml element has attributes created and cached_until (utc timestamp)

PHP Interface

ryzom_guild_api($key)

$key can be either string (single key) or array of strings.

On success, function returns associative array of SimpleXMLElement with $key as array index.
On failure, function returns boolean false.

XML structure

API is able to return information about multiple guilds at once and so each <guild> element is child of <ryzomapi> root element
<ryzomapi>
<guild apikey="key1" created="1387369332" modules="G01:G02:G03:G04:P01" cached_until="1387369632">
....
</guild>
<guild apikey="key2" created="1387369332" modules="P01" cached_until="1387369632">
....
</guild>
</ryzomapi>

Invalid key error

When provided key is invalid, then xml contains <error> element with code attribute.
<guild apikey="key1" created="1387369873">
<error code="404">invalid key</error>
</character>

Possible error codes are listed on API error codes.