|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
public interface API
The public Gbanga Puppetmaster API which is publicly available. The URL to access documentation and to communicate with the RESTful API is at http://api.gbanga.com.
| Field Summary | |
|---|---|
static short |
ANDROID
Android phone category. |
static short |
ANDROID_PLAT
Android platform. |
static short |
BADA
bada platform. |
static short |
BLACKBERRY
BlackBerry phone category. |
static short |
BLACKBERRY_PLAT
BlackBerry platform. |
static int |
BUG_SEVERITY_CRITICAL
A critical bug. |
static int |
BUG_SEVERITY_ENHANCEMENT
Not a bug, but a possible enhancement. |
static int |
BUG_SEVERITY_MAJOR
A major bug. |
static int |
BUG_SEVERITY_MINOR
A minor bug. |
static int |
BUG_SEVERITY_NORMAL
A medium bug. |
static int |
BUG_SEVERITY_TRIVIAL
A trivial bug. |
static int |
DEFAULT_EVENTS_AT_N
The default number of local Events that are returned when calling getEventsAt(String). |
static int |
DEFAULT_FEATURED_STORIES_N
The default number of featured Story objects that are requested with getFeaturedStories(). |
static int |
DEFAULT_GLOBAL_EVENTS_N
The number of events to list in a getGlobalEvents() call. |
static int |
DEFAULT_HIGHSCORE_FIRST
Parameter to indicate the rank of the first entry in the highscore. |
static int |
DEFAULT_HIGHSCORE_N
Parameter to indicate the number of entries in the highscore. |
static byte |
DEFAULT_HIGHSCORE_TYPE
Default value for highscore type (is one of the following values: daily, weekly, monthly, annual or all times). |
static int |
DEFAULT_MOST_POPULAR_N
The default number of the most popular Tags that are requested with getMostPopular(). |
static int |
DEFAULT_NEWCOMERS_N
The default number of newcomers that are requested with getNewcomers(). |
static byte |
DROP
Drop a Gbangoo. |
static int |
HIGHSCORE_TYPE_EVER
Parameter to get the highscore of all times. |
static int |
HIGHSCORE_TYPE_OFDAY
Parameter to get the daily highscore. |
static int |
HIGHSCORE_TYPE_OFMONTH
Parameter to get the monthly highscore. |
static int |
HIGHSCORE_TYPE_OFWEEK
Parameter to get the weekly highscore. |
static int |
HIGHSCORE_TYPE_OFYEAR
Parameter to get the annual highscore with. |
static short |
IPHONE
iPhone phone category. |
static short |
IPHONE_PLAT
iPhone platform. |
static byte |
LIFT
Lift a Gbangoo. |
static short |
MAEMO
Maemo platform. |
static int |
MAX_EVENTS_AT_N
The maximum number of local Events that can be retrieved with getEventsAt(String, int). |
static int |
MAX_FEATURED_STORIES_N
The maximum number of featured Story objects that can be requested with getFeaturedStories(int). |
static int |
MAX_GLOBAL_EVENTS_N
Maximum value for event global requests. |
static int |
MAX_HIGHSCORE_N
Maximum value for highscore entry count. |
static int |
MAX_MESSAGES
This is the maximum number of messages returned by the methods getConversationWithGbangoo(String, long) and
getConversationWithPlayer(String, String). |
static int |
MAX_MESSAGES_N
The maximum number of messages returned by the API methods such as getShouts(String) and getStatusFeed(String). |
static int |
MAX_MOST_POPULAR_N
The maximum number of the most popular Tags objects that can be requested with getMostPopular(int). |
static int |
MAX_NEWCOMERS_N
The maximum of newcomers that can be requested with getNewcomers(int). |
static short |
MOTOROLA
Motorola phone category. |
static short |
MOTOROLA_PLAT
Motorola platform. |
static short |
NOKIA
Nokia phone category. |
static short |
OPEN_MOKO
Open Moko platform. |
static short |
OTHER
Other phone category. |
static int |
PIECE_AT_RANDOM_TILE
Specifies to piece a Tag to a random tile within the current Cell of the logged in Player (this is standard behaviour on clients). |
static int |
PIECE_AWAY
Specifies to piece a Tag to nowhere in order to dispose it from the current Pocket. |
static short |
SAMSUNG
Samsung phone category. |
static short |
SONYERICSSON
Sony Ericsson phone category. |
static short |
SONYERICSSON_PLAT
Sony Ericsson platform. |
static short |
SYMBIAN_S60
Symbian S60 platform. |
static short |
UIQ
UIQ platform. |
static short |
UNKNOWN
The phone model was not listed so the platform is unknown. |
static short |
UNSUPPORTED
Unsupported platform. |
static int |
VERSION
The major version number of this API. |
static short |
WINDOWS_MOBILE
Windows Mobile phone category. |
static short |
WINDOWS_MOBILE_PLAT
Windows Mobile platform. |
| Method Summary | |
|---|---|
Trade |
abort(java.lang.String sessionKey,
long tradeId)
Decline an incoming trade offer. |
Trade |
accept(java.lang.String sessionKey,
long tradeId)
Accept an incoming trade offer. |
Player |
acceptFriendship(java.lang.String sessionKey,
java.lang.String player)
Accepts the friendship offer of another player. |
Trade |
addToOffer(java.lang.String sessionKey,
long tradeId,
long offeredGoodId,
long requestedGoodId)
Add goods to the indicated offer. |
Player |
adjustInterests(java.lang.String sessionKey,
boolean play,
boolean collecting,
boolean trading,
boolean events,
boolean networking,
boolean travel,
boolean dating)
Update your keywords of interest. |
Gbangoo |
beamGbangoo(java.lang.String sessionKey,
long gbangooId,
java.lang.String cellName)
Teleport a Gbangoo to a given cell. |
Infrastructure |
beamInfrastructure(java.lang.String sessionKey,
long infrastructureId,
java.lang.String cellName)
Teleport an infrastructure to a given cell. |
Resource |
beamResource(java.lang.String sessionKey,
long resourceId,
java.lang.String cellName)
Teleport a resource to a given cell. |
Player |
breakWith(java.lang.String sessionKey,
java.lang.String player,
java.lang.String lastMessage)
Break with a prior friend and, optionally, let him know why. |
void |
broadcast(java.lang.String sessionKey,
java.lang.String message)
Sends a Message to all player friends. |
Infrastructure |
build(java.lang.String sessionKey,
long gbangooId,
long type,
java.lang.String screenname)
A Gbangoo starts with a construction of a building of given type at its current location. |
Challenge |
challenge(java.lang.String sessionKey,
long challengerId,
long opponentId)
Start a match between the initiating challenger and the challenged opponent. |
Player |
changeSettings(java.lang.String sessionKey,
boolean friendCanSeeMyPosition,
boolean everybodyCanSeeMyPosition,
boolean notifyBySMS,
boolean notifyByEmail)
Update your privacy sensitive settings. |
Tile |
clear(java.lang.String sessionKey,
long tileId)
Remove the indicated tile from the Gbanga world. |
void |
collectResource(java.lang.String sessionKey,
long id)
Collects a resource. |
long |
createAvatar(java.lang.String sessionKey,
java.io.InputStream image)
Creates a new avatar from the given InputStream. |
long |
createDescription(java.lang.String sessionKey,
java.lang.String text)
Creates a new description from the given text. |
Gbangoo |
createGbangoo(java.lang.String sessionKey,
long type,
java.lang.String name,
long avatar,
long description)
Creates a Gbangoo. |
long |
createGbangooType(java.lang.String sessionKey,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
Creates a new Gbangoo type. |
Gube |
createGube(java.lang.String sessionKey,
long tileId,
int lifetime,
int color)
Pulls a Gube at the given location. |
Infrastructure |
createInfrastructure(java.lang.String sessionKey,
long type,
java.lang.String name,
long avatar,
long description)
Creates an Infrastructure. |
long |
createInfrastructureType(java.lang.String sessionKey,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
Creates a new Infrastructure type. |
Resource |
createResource(java.lang.String sessionKey,
long type,
short amount)
Creates a particular amount of a resource of given type. |
long |
createResourceType(java.lang.String sessionKey,
java.lang.String screenname,
java.io.InputStream avatar,
java.lang.String description)
Creates a new Resource type. |
Tag |
createTag(java.lang.String sessionKey,
long content,
long avatar)
|
Cell |
decorate(java.lang.String sessionKey,
long cellId,
int[] flag)
Set the flag for a given cell. |
Feature |
discover(java.lang.String sessionKey,
java.lang.String cellName,
float latitude,
float longitude,
java.lang.String cellFlagString)
Creates a new cell based on the the geographical location of a given player. |
void |
dispose(java.lang.String sessionKey,
long goodId)
Disposes of the given Good. |
FeatureCollection |
findOnMap(java.lang.String queryPhrase)
Locates the given phrase in Gbanga (Cell name, city name, ZIP code, etc.) |
Player |
forceFriendship(java.lang.String sessionKey,
java.lang.String offerer,
java.lang.String receiver)
Forces a friendship offer to be sent from one player to another one. |
void |
free(java.lang.String sessionKey,
long entityId)
Releases the given entity to be freely available to other Players. |
Message[] |
getAllMessages(java.lang.String sessionKey)
Returns a list with Messages that have not been read by the recieving Player yet. |
Cell |
getCell(java.lang.String cellName)
Retrieves the cell with the given name. |
java.lang.String[] |
getCellNames(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
Retrieves the names of all cells within the specified area. |
Message[] |
getConversationWithGbangoo(java.lang.String sessionKey,
long gbangoo)
Returns the last messages between you and a Gbangoo (max. 5 messages) |
Message[] |
getConversationWithPlayer(java.lang.String sessionKey,
java.lang.String player)
Returns the last messages between two players (max. |
int |
getCountEntitiesWithMemory(java.lang.String sessionKey,
java.lang.String key,
java.lang.String value)
Counts the entities containing a specific entry in the memory db. |
java.lang.String |
getDownloadLink(java.lang.String sessionKey)
Requests a message with the download location for the client software. |
EntitiesFromMemory |
getEntitiesWithMemory(java.lang.String sessionKey,
java.lang.String memkey,
java.lang.String value)
Gets the entities containing a specific entry in the memory db. |
Event[] |
getEventsAt(java.lang.String cellname)
Assorts a list with local Events at a given Cell. |
Event[] |
getEventsAt(java.lang.String cellname,
int n)
Assorts a list with a given number of local Events at a given Cell. |
Story[] |
getFeaturedStories()
Returns a list of featured stories interesting to be displayed on the frontpage. |
Story[] |
getFeaturedStories(int n)
Returns a list of featured stories interesting to be displayed on the frontpage. |
Player[] |
getFriends(java.lang.String sessionKey)
Returns a list with friend Players of a given authenticated Player. |
Player[] |
getFriendsInDetail(java.lang.String sessionKey)
Returns a list with friend Players containing the location if allowed
of a given authenticated Player. |
Gbangoo |
getGbangoo(java.lang.String gbangooName,
java.lang.String ownerName)
Retrieve a Gbangoo owned by the indicated player. |
Gbangoo |
getGbangooById(long gbangooId)
Retrieve a Gbangoo given its ID. |
Gbangoo |
getGbangooById(java.lang.String sessionKey,
long gbangooId,
java.lang.String lang)
Retrieve a Gbangoo given its ID containing the description in the player's language. |
Event[] |
getGlobalEvents()
Returns a number of events that take place right now. |
Event[] |
getGlobalEvents(int n)
Returns a number of events that take place right now. |
Player[] |
getHighscore(int first,
int n,
byte type)
Assorts a list with entries for the given type of highscore with the given number of entries with a given rank. |
Infrastructure |
getInfrastructure(long infrastructureId)
Retrieve an Infrastructure given its ID. |
Infrastructure |
getInfrastructure(java.lang.String sessionKey,
long infrastructureId,
java.lang.String lang)
Retrieve an Infrastructure given its ID containing the description in the player's language. |
int |
getLoginType(java.lang.String playerName)
Request a membership for the given person with the given details. |
FeatureCollection |
getMapTile(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
Returns a list of placemarks that are within the specified area. |
java.lang.String |
getMemory(java.lang.String sessionKey,
java.lang.String entityId,
java.lang.String key)
Return the value of a given key in a given Entity's memory. |
Tag[] |
getMostPopular()
Returns a list with the most popular Tags. |
Tag[] |
getMostPopular(int n)
Returns a gien number of the most popular Tags. |
Player[] |
getNewcomers()
Assorts a list with Players that have recently signed up. |
Player[] |
getNewcomers(int n)
Assorts a list with Players that have recently signed up. |
int |
getNumCells(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
Gets the number of cells within the specified area. |
Player |
getPlayer(java.lang.String playerName)
Retrieve a player indicated the player name. |
Player |
getPlayer(java.lang.String sessionKey,
java.lang.String playerName)
Retrieve a player indicated the player name and extra details if the caller is a friend. |
FeatureCollection |
getPlayersIn(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
Returns a list of players that are present within the specified area. |
FeatureCollection |
getPlayersIn(java.lang.String sessionKey,
float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
Returns a list of players that are present within the specified area. |
Pocket |
getPocket(java.lang.String sessionKey)
Returns the personal pocket. |
Pocket |
getPocketOf(java.lang.String sessionKey,
java.lang.String playerName)
Returns the pocket of the given player. |
java.lang.String |
getPromotion()
Returns HTML and Javascript code with a currently promoted subject. |
Cell |
getRandomCell(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
Retrieves a random cell within the specified area. |
java.lang.String[] |
getRanking(java.lang.String memkey,
int from,
int count)
Gets the ranking of players according to the natural ordering of values in the players' memory for a given key and rank range. |
Resource |
getResource(long id)
Retrieve a resource given the id. |
Resource |
getResource(java.lang.String sessionKey,
long id,
java.lang.String lang)
Retrieve a resource given the id containing the description in the player's language.. |
Message[] |
getShouts(java.lang.String sessionKey)
Gets the most recent shouts. |
Message[] |
getStatusFeed(java.lang.String sessionKey)
Gets the status feed messages. |
Tag |
getTag(long id)
Retrieve a tag given the id. |
Message[] |
getUnreadMessages(java.lang.String sessionKey)
Returns a list with Messages that have not been read by the recieving Player yet. |
java.lang.String |
getVersion()
Returns a canonical version String including assembly information and server time. |
WebHookSubscription[] |
getWebHookSubscriptions(java.lang.String sessionKey)
Gets all subscriptions to any Web Hook for the given user. |
Event[] |
getYourEvents(java.lang.String sessionKey)
Returns a number of events that are relevant to an authenticated player personally. |
Event[] |
getYourEvents(java.lang.String sessionKey,
int n)
Returns a number of events that are relevant to an authenticated player personally. |
Good |
give(java.lang.String sessionKey,
java.lang.String receivingPlayer,
long goodId)
Transfers the given Good from one Pocket to another Players Pocket. |
void |
interact(java.lang.String sessionKey,
long id)
Interact with an infrastructure. |
boolean |
invite(java.lang.String sessionKey,
java.lang.String name,
java.lang.String contactInfo)
Send an invitation to the given contact. |
boolean |
isAvailable(java.lang.String name)
Checks if the given name is available. |
boolean |
isEmailAvailable(java.lang.String email)
Checks if the given email address is available. |
java.lang.String |
isFBUidGbangaUsr(long fbuid,
java.lang.String fBsessionKey)
Checks if the given name is available. |
boolean |
isPhoneAvailable(java.lang.String phone)
Checks if the given (cell) phone number address is available. |
boolean |
isTimedOut(java.lang.String sessionKey)
Checks whether a given session is timed-out. |
boolean |
isTradable(long entityId)
Checks if a given entity is tradable. |
java.lang.String |
isUDIDGbangaUsr(java.lang.String udid)
Checks if the given name is available. |
Gube |
jump(java.lang.String sessionKey,
long gbangooId)
A Gbangoo should jump to the current location of the player and produce the prepared Gube. |
Feature |
locate(java.lang.String sessionKey,
float latitude,
float longitude)
Retrieve the geographical location of a given cell. |
WebSession |
login(java.lang.String playerName,
java.lang.String password)
Authenticates and generates a session key. |
void |
logout(java.lang.String sessionKey)
Close a currently open session by indicating the sessionKey. |
Message |
mail(java.lang.String sessionKey,
java.lang.String receivingPlayer,
java.lang.String message)
Send a Message to a remote Player. |
void |
makeProductItemAvailableTo(java.lang.String sessionKey,
long productItemId,
java.lang.String player,
boolean available)
Collect a resource. |
Gbangoo |
mine(java.lang.String sessionKey,
long gbangooId)
A Gbangoo starts mining at its current location. |
Event |
move(java.lang.String sessionKey,
long entityId,
long direction)
Move a placeable Entity towards a given direction |
void |
notify(java.lang.String sessionKey,
java.lang.String player,
java.lang.String title,
java.lang.String description,
long avatar,
boolean shareable)
Sends a notification message to a player. |
Player |
offerFriendship(java.lang.String sessionKey,
java.lang.String player,
java.lang.String introduction)
Offer friendship to another player. |
Pocket |
pick(java.lang.String sessionKey,
long tagId)
Pick up a copy of a tag |
Tile |
piece(java.lang.String sessionKey,
long tagId,
long tileId)
Create a tag at a given position. |
Challenge |
playCard(java.lang.String sessionKey,
long challengeId,
long tagId)
Play a given card in a given match. |
void |
playSound(java.lang.String sessionKey,
java.lang.String name,
long melodyId)
Plays a sound on the device of the given Player if logged in and if settings allow. |
Trade |
postOffer(java.lang.String sessionKey,
long tradeId)
Sends the created offer to the trading partner. |
Trade |
prepareOffer(java.lang.String sessionKey,
java.lang.String partnerName)
Prepare a trade (initial offer or re-offer) with a given player. |
Cell |
rateCell(java.lang.String sessionKey,
long cellId,
byte rating,
java.lang.String comment)
Rate a given cell. |
Tag |
rateTag(java.lang.String sessionKey,
long tagId,
byte rating,
java.lang.String comment)
Vote for the rating of a Cell. |
void |
register(java.lang.String playerName,
java.lang.String password,
java.lang.String cellPhone,
java.lang.String email,
java.lang.String model,
java.lang.String language,
java.lang.String method)
Request a membership for the given person with the given details. |
void |
registerFB(java.lang.String playerName,
java.lang.String fbuid,
java.lang.String fbsession,
java.lang.String model,
java.lang.String language,
java.lang.String method)
Request a membership for the given person with the given details. |
void |
registerFQ(java.lang.String playerName,
java.lang.String fquid,
java.lang.String fbsession,
java.lang.String model,
java.lang.String language,
java.lang.String method)
Request a membership for the given person with the given details. |
void |
registerLess(java.lang.String playerName,
java.lang.String iphoneid,
java.lang.String model,
java.lang.String language,
java.lang.String method)
Register a player with the iphone id as the identifier. |
void |
registerTwitter(java.lang.String playerName,
java.lang.String tuid,
java.lang.String fbsession,
java.lang.String model,
java.lang.String language,
java.lang.String method)
Request a membership for the given person with the given details. |
void |
remindPassword(java.lang.String phoneOrEmail)
Request a password reminder message to an email address or a cell phone. |
void |
removeMemory(java.lang.String sessionKey,
java.lang.String entityId,
java.lang.String key)
Remove a key-value pair from a Entity's memory. |
Cell |
renameCell(java.lang.String sessionKey,
long cellId,
java.lang.String name)
Gives a new name to a given cell. |
int |
reportBug(java.lang.String author,
java.lang.String content,
int severity)
Post a bug report indicating the author, a problem description and the severity. |
Report |
reportPlayer(java.lang.String sessionKey,
java.lang.String player,
java.lang.String explanation)
Report an incident about a player that didn't comply with the regulations (rudeness in chat messages, privacy tricks, fraud, creating dangerous quests, etc.). |
DownloadRequest |
requestDownloadSMS(java.lang.String playerName,
java.lang.String password)
Request a message with the download location for the client software. |
DownloadRequest |
requestDownloadSMSByHeader(java.lang.String playerName,
java.lang.String password,
java.lang.String header)
Same as requestDownloadSMS(String, String) but also uses the given
http header to guess the user's device. |
DownloadRequest |
requestDownloadSMSBySessionKey(java.lang.String sessionKey)
Request a message with the download location for the client software. |
void |
requestPurchasedItem(java.lang.String sessionKey,
java.lang.String appleProductId,
java.lang.String transactionId,
java.lang.String receipt)
Counts the entities containing a specific entry in the memory db. |
WebSession |
resume(java.lang.String playerName,
java.lang.String sessionKey)
Password-less resume into existing session. |
void |
reward(java.lang.String sessionKey,
java.lang.String player,
int points)
Reward the given Player with points. |
boolean |
setCode(java.lang.String key,
long id,
java.lang.String code)
Applies a "download code" for the given entity. |
void |
setMemory(java.lang.String sessionKey,
java.lang.String entityId,
java.lang.String key,
java.lang.String value)
Add a key-value pair to a Entity's memory. |
void |
setMemoryForAll(java.lang.String sessionKey,
java.lang.String key,
java.lang.String value)
Set a key-value pair to all the Entity's memory having the key. |
void |
setTradable(java.lang.String sessionKey,
long entityId,
boolean yes)
Sets if a given entity is tradable. |
Message |
shout(java.lang.String sessionKey,
java.lang.String receivingCell,
java.lang.String message)
Shout a text Message to a Cell. |
void |
showTicker(java.lang.String sessionKey,
java.lang.String name,
java.lang.String ticker)
Shows a ticker message on the device of the given Player if logged in and if settings allow. |
Event |
speak(java.lang.String sessionKey,
long gbangooId,
java.lang.String message)
Lets the given Gbangoo send the message to everyone in its current cell. |
Event |
speakTo(java.lang.String sessionKey,
long gbangooId,
java.lang.String player,
java.lang.String message)
Lets the given Gbangoo send a message to the specified player. |
Gbangoo |
stop(java.lang.String sessionKey,
long gbangooId)
Halts the given Gbangoo. |
void |
submitStatistics(java.lang.String sessionKey,
java.lang.String data)
This method is used to submit statistics for research purposes. |
java.lang.String |
subscribeToWebHook(java.lang.String sessionKey,
int event,
java.lang.String filter,
java.lang.String url)
Registers a Web Hook listener at the given URL for the given user. |
int |
takeOverCell(java.lang.String sessionKey,
java.lang.String playerName,
java.lang.String cellName,
java.lang.String newOwner)
Transfer the ownership of a cell to a new family |
Trade |
trade(java.lang.String sessionKey,
java.lang.String partnerName,
java.lang.String offeredGoodIdString,
java.lang.String requestedGoodIdString)
Add goods to the indicated offer. |
int |
transferInfrastructuresAndCells(java.lang.String sessionKey,
java.lang.String playerName,
java.lang.String newFamily)
Transfer the infrstructures owned by a player from a family to another one |
java.lang.String |
unsubscribeFromWebHook(java.lang.String sessionKey,
java.lang.String url)
Unregisters a Web Hook listener at the given URL for the given user. |
void |
updateAvatar(java.lang.String sessionKey,
long entityId,
java.io.InputStream is)
Updates the image of a given entity. |
void |
updateAvatarByRef(java.lang.String sessionKey,
long entityId,
long avatarId)
Sets the image of a given entity by referencing an existing image. |
void |
updateDescription(java.lang.String sessionKey,
long entityId,
java.lang.String description)
Sets the description field of the given entity. |
void |
updateEmail(java.lang.String sessionKey,
java.lang.String playerName,
java.lang.String email)
Update the email of a Player. |
void |
updateGbangooType(java.lang.String sessionKey,
long type,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
Updates an existing Gbangoo type. |
void |
updateInfrastructureType(java.lang.String sessionKey,
long type,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
Updates an existing Infrastructure type. |
Player |
updateProfile(java.lang.String sessionKey,
java.lang.String cellphone,
java.lang.String email)
Update the details of a Player. |
void |
updateProfileImage(java.lang.String sessionKey,
java.io.InputStream image)
Update the profile image of the authenticated Player. |
void |
updateResourceType(java.lang.String sessionKey,
long type,
java.lang.String screenname,
java.io.InputStream avatar,
java.lang.String description)
Updates an existing Resource type. |
Player |
updateStatus(java.lang.String sessionKey,
java.lang.String status)
Updates the status message of a Player in a manner similar to a Twitter message, Facebook's status or a tagline in any instant messenger (eg, MSN and Skype). |
Feature |
whereAmI()
Tries to locate the requester of this method with the help of HTTP header information, IP localization, etc. |
| Field Detail |
|---|
static final short ANDROID
static final short ANDROID_PLAT
static final short BADA
static final short BLACKBERRY
static final short BLACKBERRY_PLAT
static final int BUG_SEVERITY_CRITICAL
static final int BUG_SEVERITY_ENHANCEMENT
static final int BUG_SEVERITY_MAJOR
static final int BUG_SEVERITY_MINOR
static final int BUG_SEVERITY_NORMAL
static final int BUG_SEVERITY_TRIVIAL
static final int DEFAULT_EVENTS_AT_N
Events that are returned when calling getEventsAt(String).
static final int DEFAULT_FEATURED_STORIES_N
Story objects that are requested with getFeaturedStories().
static final int DEFAULT_GLOBAL_EVENTS_N
getGlobalEvents() call.
static final int DEFAULT_HIGHSCORE_FIRST
getHighscore(int, int, byte),
Constant Field Valuesstatic final int DEFAULT_HIGHSCORE_N
getHighscore(int, int, byte),
Constant Field Valuesstatic final byte DEFAULT_HIGHSCORE_TYPE
getHighscore(int, int, byte),
Constant Field Valuesstatic final int DEFAULT_MOST_POPULAR_N
Tags that are requested with getMostPopular().
static final int DEFAULT_NEWCOMERS_N
getNewcomers().
static final byte DROP
move(String, long, long),
Constant Field Valuesstatic final int HIGHSCORE_TYPE_EVER
getHighscore(int, int, byte),
Constant Field Valuesstatic final int HIGHSCORE_TYPE_OFDAY
getHighscore(int, int, byte),
Constant Field Valuesstatic final int HIGHSCORE_TYPE_OFMONTH
getHighscore(int, int, byte),
Constant Field Valuesstatic final int HIGHSCORE_TYPE_OFWEEK
getHighscore(int, int, byte),
Constant Field Valuesstatic final int HIGHSCORE_TYPE_OFYEAR
getHighscore(int, int, byte),
Constant Field Valuesstatic final short IPHONE
static final short IPHONE_PLAT
static final byte LIFT
move(String, long, long),
Constant Field Valuesstatic final short MAEMO
static final int MAX_EVENTS_AT_N
Events that can be retrieved with getEventsAt(String, int).
static final int MAX_FEATURED_STORIES_N
Story objects that can be requested with getFeaturedStories(int).
static final int MAX_GLOBAL_EVENTS_N
getGlobalEvents(int).
getGlobalEvents(int),
DEFAULT_GLOBAL_EVENTS_N,
Constant Field Valuesstatic final int MAX_HIGHSCORE_N
getHighscore(int, int, byte).
getHighscore(int, int, byte),
DEFAULT_HIGHSCORE_N,
Constant Field Valuesstatic final int MAX_MESSAGES
getConversationWithGbangoo(String, long) and
getConversationWithPlayer(String, String).
getConversationWithGbangoo(String, long),
getConversationWithPlayer(String, String),
Constant Field Valuesstatic final int MAX_MESSAGES_N
getShouts(String) and getStatusFeed(String).
static final int MAX_MOST_POPULAR_N
Tags objects that can be requested with getMostPopular(int).
static final int MAX_NEWCOMERS_N
getNewcomers(int).
static final short MOTOROLA
static final short MOTOROLA_PLAT
static final short NOKIA
static final short OPEN_MOKO
static final short OTHER
static final int PIECE_AT_RANDOM_TILE
Tag to a random tile within the current Cell of the logged in Player (this is standard behaviour on clients).
piece(String, long, long),
Constant Field Valuesstatic final int PIECE_AWAY
Tag to nowhere in order to dispose it from the current Pocket.
piece(String, long, long),
Constant Field Valuesstatic final short SAMSUNG
static final short SONYERICSSON
static final short SONYERICSSON_PLAT
static final short SYMBIAN_S60
static final short UIQ
static final short UNKNOWN
In this case the user should be contacted to include his phone model in the list.
static final short UNSUPPORTED
static final int VERSION
static final short WINDOWS_MOBILE
static final short WINDOWS_MOBILE_PLAT
| Method Detail |
|---|
Trade abort(java.lang.String sessionKey,
long tradeId)
throws APIException
sessionKey - the session key of the authenticated usertradeId - the offer to be declined
APIException - fails if the session key is wrong,
Trade accept(java.lang.String sessionKey,
long tradeId)
throws APIException
sessionKey - the session key of the authenticated usertradeId - the offer to be accepted
APIException - fails if the session key is wrong,
Player acceptFriendship(java.lang.String sessionKey,
java.lang.String player)
throws APIException
sessionKey - the session key of the authenticated userplayer - the player who offered his friendship
APIException - fails if the session key is wrong,
Trade addToOffer(java.lang.String sessionKey,
long tradeId,
long offeredGoodId,
long requestedGoodId)
throws APIException
sessionKey - the session key of the authenticated usertradeId - the current trade/offerofferedGoodId - an id of a good that is offered (may be 0, if nothing to offer)requestedGoodId - an id of a good that is requested (may be 0, if nothing is requested)
APIException - fails if the session key is wrong,
Player adjustInterests(java.lang.String sessionKey,
boolean play,
boolean collecting,
boolean trading,
boolean events,
boolean networking,
boolean travel,
boolean dating)
throws APIException
sessionKey - the session key of the authenticated userplay - true if you want to play in general (quests, etc.)collecting - true if you are interested in collecting for puzzlestrading - true if you are interested in trading goodsevents - true if you are interested in local eventsnetworking - true if you are interested in chatting up new peers in your neighbourhoodtravel - true if you are interested in travelling tipps on sitedating - true if you are interested
APIException - if the session key does not exist
Gbangoo beamGbangoo(java.lang.String sessionKey,
long gbangooId,
java.lang.String cellName)
throws APIException
sessionKey - the session key of the authenticated usergbangooId - the id of the Gbangoo that sould be teleportedcellName - the id of the destination cell
APIException - fails if the session key is wrong,
Infrastructure beamInfrastructure(java.lang.String sessionKey,
long infrastructureId,
java.lang.String cellName)
throws APIException
sessionKey - the session key of the authenticated userinfrastructureId - the id of the infrastructure that sould be teleportedcellName - the id of the destination cell
Infrastructure object
APIException - fails if the session key is wrong,
Resource beamResource(java.lang.String sessionKey,
long resourceId,
java.lang.String cellName)
throws APIException
sessionKey - the session key of the authenticated userresourceId - the id of the resource that sould be teleportedcellName - the id of the destination cell
Resource object
APIException - fails if the session key is wrong,
Player breakWith(java.lang.String sessionKey,
java.lang.String player,
java.lang.String lastMessage)
throws APIException
sessionKey - the session key of the authenticated userplayer - the prior friendlastMessage - the good-bye message
APIException - if the session key does not exist
void broadcast(java.lang.String sessionKey,
java.lang.String message)
throws APIException
Message to all player friends.
sessionKey - the session key of the authenticated Playermessage - the content of the message
APIException - if the given session key is invalid, or
Infrastructure build(java.lang.String sessionKey,
long gbangooId,
long type,
java.lang.String screenname)
throws APIException
sessionKey - the session key of the authenticated usergbangooId - the id of the Gbangoo that should start with the constructiontype - the type of building to be builtscreenname - the name to be given to the building
APIException - fails if the session key is wrong,
Challenge challenge(java.lang.String sessionKey,
long challengerId,
long opponentId)
throws APIException
sessionKey - the session key of the authenticated userchallengerId - the initiating GbangooopponentId - the challenged Gbangoo
APIException - fails if the session key is wrong,
Player changeSettings(java.lang.String sessionKey,
boolean friendCanSeeMyPosition,
boolean everybodyCanSeeMyPosition,
boolean notifyBySMS,
boolean notifyByEmail)
throws APIException
sessionKey - the session key of the authenticated userfriendCanSeeMyPosition - true if your friends should be able to see your last position within the game (cell-precision, only)everybodyCanSeeMyPosition - true if all players should be able to see your last position within the game (cell-precision, only)notifyBySMS - true if you want to receive notifications to your cell phone number indicated in your profilenotifyByEmail - true if you want to receive notifications to your email address indicated in your profile
APIException - if the session key does not exist
Tile clear(java.lang.String sessionKey,
long tileId)
throws APIException
sessionKey - the session key of the authenticated usertileId - the id of the tile to remove
APIException - if the session key does not exist, or
void collectResource(java.lang.String sessionKey,
long id)
throws APIException
sessionKey - the key of the session of the Player who created the product itemid - the id of the resource
APIException - If the session key is invalid or the id doesn't correspond to a resource
long createAvatar(java.lang.String sessionKey,
java.io.InputStream image)
throws APIException
InputStream.
sessionKey - the session key of the authenticated Playerimage - the image to create an avatar from
APIException - if the session key is invalid, or
long createDescription(java.lang.String sessionKey,
java.lang.String text)
throws APIException
sessionKey - the session key of the authenticated Playertext - the String to create a description from
APIException - if the session key is invalid, or
Gbangoo createGbangoo(java.lang.String sessionKey,
long type,
java.lang.String name,
long avatar,
long description)
throws APIException
Gbangoo. It will belong to the authenticated Player.
sessionKey - the session key of the authenticated Playertype - the Gbangoo's typename - the screen name of the Gbangooavatar - the optional avatar IDdescription - the optional description ID
Gbangoo created
APIException - if the session key is invalid, or
long createGbangooType(java.lang.String sessionKey,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
throws APIException
Gbangoo type. The type encompasses an avatar image and a description.
The new type will be assigned a numerical id uniquely identifying it.
sessionKey - the session key of the authenticated Playeravatar - the avatar image displayed for Gbangoos of the new typedescription - the description displayed for Gbangoos of the new typecomment - an optional comment describing the purpose of the new type
APIException - if the session key is invalid, or
Gube createGube(java.lang.String sessionKey,
long tileId,
int lifetime,
int color)
throws APIException
Gube at the given location.
sessionKey - the session key of the authenticated PlayertileId - the location where the Gube should be placedlifetime - the number of ticks the Gube should remaincolor - the colour the Gube should have
Gube created
APIException - if the session key is invalid, or
Infrastructure createInfrastructure(java.lang.String sessionKey,
long type,
java.lang.String name,
long avatar,
long description)
throws APIException
Infrastructure. It will belong to the authenticated Player. If
no avatar image is specified, the default image for the given type will be used.
sessionKey - the session key of the authenticated Playertype - the type of the infrastructurename - the screen name of the Infrastructureavatar - the optional avatar IDdescription - the optional description ID
Infrastructure created
APIException - if the session key is invalid, or
long createInfrastructureType(java.lang.String sessionKey,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
throws APIException
Infrastructure type. The type encompasses an avatar image and a description.
The new type will be assigned a numerical id uniquely identifying it.
sessionKey - the session key of the authenticated Playeravatar - the avatar image displayed for infrastructures of the new typedescription - the description displayed for infrastructures of the new typecomment - an optional comment describing the purpose of the new type
APIException - if the session key is invalid, or
Resource createResource(java.lang.String sessionKey,
long type,
short amount)
throws APIException
sessionKey - the session key of the authenticated Playertype - the type of the resource to be createdamount - the amount
Resource created
APIException - if the session key is invalid, or
long createResourceType(java.lang.String sessionKey,
java.lang.String screenname,
java.io.InputStream avatar,
java.lang.String description)
throws APIException
Resource type. The type encompasses a screen name, an avatar image
and a description. The new type will be assigned a numerical id uniquely identifying it.
sessionKey - the session key of the authenticated Playerscreenname - the screen name displayed for resources of the new typeavatar - the avatar image displayed for resources of the new typedescription - the description displayed for resources of the new type
APIException - if the session key is invalid, or
Tag createTag(java.lang.String sessionKey,
long content,
long avatar)
throws APIException
sessionKey - the session key of the authenticated Playercontent - the content IDavatar - the avatar ID
Tag created
APIException - if the session key is invalid, or
Cell decorate(java.lang.String sessionKey,
long cellId,
int[] flag)
throws APIException
sessionKey - the session key of the authenticated usercellId - the id of the cell with a new flatflag - the dots of the new flag
APIException - fails if the session key is wrong,
Feature discover(java.lang.String sessionKey,
java.lang.String cellName,
float latitude,
float longitude,
java.lang.String cellFlagString)
throws APIException
sessionKey - the session key of the authenticated usercellName - the name of the new celllatitude - the latitudelongitude - the longitudecellFlagString - the flag encoded as a string of comma separated integers
APIException - fails if the session key is wrong,
void dispose(java.lang.String sessionKey,
long goodId)
throws APIException
Good. Only the creator of a good (but not
the owner) can dispose of it. If the requester is not the creator, the good won't be disposed
of, but no APIException will be thrown.
sessionKey - the key of the session of the Player who created the entitygoodId - the id of the good which should be disposed of
APIException - if the session key is invalid,
FeatureCollection findOnMap(java.lang.String queryPhrase)
throws APIException
Locates the given phrase in Gbanga (Cell name, city name, ZIP code, etc.)
queryPhrase - a freeform text that describes a geo location or a game entity
APIException - if the query was empty or the query phrase invalid in another manner
Player forceFriendship(java.lang.String sessionKey,
java.lang.String offerer,
java.lang.String receiver)
throws APIException
sessionKey - the session key of the authenticated userofferer - the player forced to send a friendship offerreceiver - the receiver of the friendship offer
APIException - fails if the session key is wrong,
void free(java.lang.String sessionKey,
long entityId)
throws APIException
Players.
NOTE: the entity must not be in the player's pocket when calling this method.
sessionKey - the key of the session of the owning PlayerentityId - the id of the entity which should be released
APIException - if the session key is invalid, the entity id unknown
Message[] getAllMessages(java.lang.String sessionKey)
throws APIException
Messages that have not been read by the recieving Player yet.
sessionKey - the session key of the authenticated user
Messages
APIException - if the given session key is invalid
Cell getCell(java.lang.String cellName)
throws APIException
cellName - the unique cell name
APIException - thrown if cell name does not exist
java.lang.String[] getCellNames(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
throws APIException
topLatitude - the north-west point's latitudeleftLongitude - the north-west point's longitudebottomLatitude - the south-east point's latituderightLongitude - the south-east point's longitude
APIException - if the specified area is invalid
Message[] getConversationWithGbangoo(java.lang.String sessionKey,
long gbangoo)
throws APIException
sessionKey - the key of the session to checkgbangoo - the id of the Gbangoo you have chatted with
Messages
APIException - if the session key is invalid, or
Message[] getConversationWithPlayer(java.lang.String sessionKey,
java.lang.String player)
throws APIException
MAX_MESSAGES messages)
sessionKey - the key of the session to checkplayer - the player one has chatted with
Messages
APIException - if the session key is invalid, or
int getCountEntitiesWithMemory(java.lang.String sessionKey,
java.lang.String key,
java.lang.String value)
throws APIException
sessionKey - the temporarily valid key of a player's sessionkey - the memory keyvalue - the value to filter with
APIException
java.lang.String getDownloadLink(java.lang.String sessionKey)
throws APIException
sessionKey -
http://)
APIException - if the service is currently not available or the session key is invalid.
EntitiesFromMemory getEntitiesWithMemory(java.lang.String sessionKey,
java.lang.String memkey,
java.lang.String value)
throws APIException
sessionKey - the temporarily valid key of a player's sessionmemkey - the memory keyvalue - the value to filter with.
APIException
Event[] getEventsAt(java.lang.String cellname)
throws APIException
Events at a given Cell.
cellname - the name of a Cell.
Events
APIException - if the given cell is unknownDEFAULT_EVENTS_AT_N
Event[] getEventsAt(java.lang.String cellname,
int n)
throws APIException
Events at a given Cell.
cellname - the name of a Cell.n - the number of Events to be returned
Events
APIException - if the given cell is unknownDEFAULT_EVENTS_AT_N,
MAX_EVENTS_AT_NStory[] getFeaturedStories()
Story objects.getFeaturedStories(int),
DEFAULT_FEATURED_STORIES_N
Story[] getFeaturedStories(int n)
throws APIException
n - the number of Story objects to be returned.
Story objects.
APIException - if the indicated number was too high or less than 1MAX_FEATURED_STORIES_N,
DEFAULT_FEATURED_STORIES_N
Player[] getFriends(java.lang.String sessionKey)
throws APIException
Players of a given authenticated Player.
sessionKey - the session key of the authenticated user
Players
APIException - if the given session key is invalid
Player[] getFriendsInDetail(java.lang.String sessionKey)
throws APIException
Players containing the location if allowed
of a given authenticated Player.
sessionKey - the session key of the authenticated user
Players
APIException - if the given session key is invalid
Gbangoo getGbangoo(java.lang.String gbangooName,
java.lang.String ownerName)
throws APIException
gbangooName - the name of the GbangooownerName - the owning player
APIException - thrown if one or both names do not exist
Gbangoo getGbangooById(long gbangooId)
throws APIException
gbangooId - the ID the Gbangoo
APIException - thrown if there is no Gbangoo with the given ID
Gbangoo getGbangooById(java.lang.String sessionKey,
long gbangooId,
java.lang.String lang)
throws APIException
sessionKey - the session key of the authenticated usergbangooId - the ID the Gbangoolang - if this is set, will override player's settings
APIException - thrown if there is no Gbangoo with the given IDEvent[] getGlobalEvents()
Storys, Challenges, Conversations, Trades and VisitsDEFAULT_GLOBAL_EVENTS_N
Event[] getGlobalEvents(int n)
throws APIException
n - the number of events to return
Storys, Challenges, Conversations, Trades and Visits
APIException - if the number of events argument was out of bounds (less than 1 or greater than the maximum)DEFAULT_GLOBAL_EVENTS_N,
MAX_GLOBAL_EVENTS_N
Player[] getHighscore(int first,
int n,
byte type)
throws APIException
Rank Entry
--------------------------------
[first] Player details
[first + 1] Player details
[first + 2] Player details
... ...
[first + n - 1] Player details
first - the rank of the first entryn - number of entries to returntype - the type of highscore (daily, weekly, monthly, annual or all times)
APIException - if the rank and/or the number of entries is out of bounds (eg. too high or less than zero)
if the type is unknownHIGHSCORE_TYPE_EVER,
HIGHSCORE_TYPE_OFDAY,
HIGHSCORE_TYPE_OFWEEK,
HIGHSCORE_TYPE_OFMONTH,
HIGHSCORE_TYPE_OFYEAR
Infrastructure getInfrastructure(long infrastructureId)
throws APIException
infrastructureId - the ID of the Infrastructure
APIException - thrown if there is no Infrastructure with the given ID
Infrastructure getInfrastructure(java.lang.String sessionKey,
long infrastructureId,
java.lang.String lang)
throws APIException
sessionKey - the session key of the authenticated userinfrastructureId - the ID of the Infrastructurelang - if this is set, will override player's settings
APIException - thrown if there is no Infrastructure with the given ID
int getLoginType(java.lang.String playerName)
throws APIException
playerName - the username of the player
APIException - thrown if player name is taken, the password is not verified or the cellPhone or email are invalid
FeatureCollection getMapTile(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
throws APIException
Returns a list of placemarks that are within the specified area.
This map is dynamically created and projected to the given size of the plane.
topLatitude - top latitudeleftLongitude - left longitudebottomLatitude - bottom latituderightLongitude - right longitude
APIException - if projection size is invalid (eg. negative or too big) or coordinates are invalid.
java.lang.String getMemory(java.lang.String sessionKey,
java.lang.String entityId,
java.lang.String key)
throws APIException
Entity's memory.
sessionKey - the session key of the authenticated PlayerentityId - the id/name of the Entity which memory should be queriedkey - the key to get the value from
APIException - if the session key is invalid, orEntity id is unknown, orTag[] getMostPopular()
Tags.
TagsDEFAULT_MOST_POPULAR_N
Tag[] getMostPopular(int n)
throws APIException
Tags.
n - the number of Tags to be returned
Tags
APIException - if the indicated number was out of boundsMAX_MOST_POPULAR_N,
DEFAULT_MOST_POPULAR_NPlayer[] getNewcomers()
Players that have recently signed up.
The data is potentially anonymized.
DEFAULT_NEWCOMERS_N,
getNewcomers(int)
Player[] getNewcomers(int n)
throws APIException
Players that have recently signed up.
The data is potentially anonymized.
n - the number of Players to be returned.
Players that have recently signed up Gbanga.
APIException - if the indicated number of Players was too high or less than 1MAX_NEWCOMERS_N,
DEFAULT_NEWCOMERS_N
int getNumCells(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
throws APIException
topLatitude - the north-west point's latitudeleftLongitude - the north-west point's longitudebottomLatitude - the south-east point's latituderightLongitude - the south-east point's longitude
APIException - if the specified area is invalid
Player getPlayer(java.lang.String playerName)
throws APIException
playerName - the name of the player
APIException - thrown if player name does not exist
Player getPlayer(java.lang.String sessionKey,
java.lang.String playerName)
throws APIException
sessionKey - the session key of the callerplayerName - the name of the player
APIException - thrown if player name does not exist or invalid session key
FeatureCollection getPlayersIn(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
throws APIException
Returns a list of players that are present within the specified area.
topLatitude - top latitudeleftLongitude - left longitudebottomLatitude - bottom latituderightLongitude - right longitude
APIException - if projection size is invalid (eg. negative or too big) or coordinates are invalid.
FeatureCollection getPlayersIn(java.lang.String sessionKey,
float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
throws APIException
Returns a list of players that are present within the specified area. This also includes the friends that reveal their position only to their friends.
sessionKey - the session key of the authenticated usertopLatitude - top latitudeleftLongitude - left longitudebottomLatitude - bottom latituderightLongitude - right longitude
APIException - if projection size is invalid (eg. negative or too big) or coordinates are invalid.getPlayersIn(float, float, float, float)
Pocket getPocket(java.lang.String sessionKey)
throws APIException
sessionKey - the session key of the authenticated user
APIException - if the session key does not exist
Pocket getPocketOf(java.lang.String sessionKey,
java.lang.String playerName)
throws APIException
sessionKey - the session key of the authenticated userplayerName - the name of the player whose pocket to get
APIException - if the session key does not exist, or
java.lang.String getPromotion()
Cell getRandomCell(float topLatitude,
float leftLongitude,
float bottomLatitude,
float rightLongitude)
throws APIException
topLatitude - the north-west point's latitudeleftLongitude - the north-west point's longitudebottomLatitude - the south-east point's latituderightLongitude - the south-east point's longitude
APIException - if the specified area is invalid
java.lang.String[] getRanking(java.lang.String memkey,
int from,
int count)
throws APIException
The ranking should only be used on memory entries where the values are comparable against each other, and an order can be established.
memkey - the memoryfrom - the rank to start withcount - the number of players to return starting from the specified rank
APIException
Resource getResource(long id)
throws APIException
id - the id of the resource
APIException - thrown if id does not exist
Resource getResource(java.lang.String sessionKey,
long id,
java.lang.String lang)
throws APIException
sessionKey - the session key of the authenticated userid - the id of the resourcelang - if this is set, will override player's settings
APIException - thrown if id does not exist
Message[] getShouts(java.lang.String sessionKey)
throws APIException
sessionKey - the session key of the Player
APIException - if the session key is invalid
Message[] getStatusFeed(java.lang.String sessionKey)
throws APIException
sessionKey - the session key of the Player
APIException - if the session key is invalid
Tag getTag(long id)
throws APIException
id - the id of the tag
APIException - thrown if id does not exist
Message[] getUnreadMessages(java.lang.String sessionKey)
throws APIException
Messages that have not been read by the recieving Player yet.
sessionKey - the session key of the authenticated user
Messages
APIException - if the given session key is invalidjava.lang.String getVersion()
WebHookSubscription[] getWebHookSubscriptions(java.lang.String sessionKey)
throws APIException
sessionKey - the key of the session for which to get the subscriptions
APIException - if the session key is invalid,
or the retrieval of subscriptions failed due to some other reason
Event[] getYourEvents(java.lang.String sessionKey)
throws APIException
sessionKey - the session key of the authenticated user
Storys, Challenges, Conversations, Trades and Visits
APIException - if the session key is invalid
Event[] getYourEvents(java.lang.String sessionKey,
int n)
throws APIException
sessionKey - the session key of the authenticated usern - the number of events to return
Storys, Challenges, Conversations, Trades and Visits
APIException - if the session key is invalid, or
Good give(java.lang.String sessionKey,
java.lang.String receivingPlayer,
long goodId)
throws APIException
Good from one Pocket to another Players Pocket.
sessionKey - the session key of the authenticated PlayerreceivingPlayer - the username of the receiving PlayergoodId - the id of the Good to trade
Good with new owner
APIException - if the session key is invalid, orPlayer is unknown, orGood with the given id
void interact(java.lang.String sessionKey,
long id)
throws APIException
sessionKey - the key of the session of the Player who created the product itemid - the id of the infrastructure to interact with
APIException - If the session key is invalid or the id doesn't correspond to an infrastructure
boolean invite(java.lang.String sessionKey,
java.lang.String name,
java.lang.String contactInfo)
throws APIException
sessionKey - the session key of the inviting playername - the name of the inviteecontactInfo - the contact info that is a phone number, or an email, or a postal address
true if the invitation could be delivered
(this is true for postal addresses, if one can geo-reference it.
It does not guarantee that it could be delivered or the recipient exists)
APIException - if the session key is unknown, orboolean isAvailable(java.lang.String name)
name - a suggested name
true if the name is not taken
boolean isEmailAvailable(java.lang.String email)
throws APIException
email - an email address
true if the email address is valid and not taken
APIException - if the given email address is invalid
java.lang.String isFBUidGbangaUsr(long fbuid,
java.lang.String fBsessionKey)
fbuid - Facebook UersIDfBsessionKey - Facebook Session that authentificates this user
GbangaUsername if the facebook user is registered in Gbanga
boolean isPhoneAvailable(java.lang.String phone)
throws APIException
phone - an (cell) phone number
true if the (cell) phone number is valid and not taken
APIException - if the given cell phone number is invalidboolean isTimedOut(java.lang.String sessionKey)
sessionKey - the key of the session to check
true, if the session is timed-out
boolean isTradable(long entityId)
throws APIException
entityId - the id of the entity to check if it is tradable
true if one can trade it
APIException - if the entity id is unknownjava.lang.String isUDIDGbangaUsr(java.lang.String udid)
udid - UDID of an iPhone the user currently plays on
GbangaUsername if the facebook user is registered in Gbanga
Gube jump(java.lang.String sessionKey,
long gbangooId)
throws APIException
sessionKey - the session key of the authenticated usergbangooId - the Gbangoo owned
APIException - fails if the session key is wrong,
Feature locate(java.lang.String sessionKey,
float latitude,
float longitude)
throws APIException
sessionKey - the session key of the authenticated userlatitude - the latitudelongitude - the longitude
APIException - fails if the session key is wrong,
WebSession login(java.lang.String playerName,
java.lang.String password)
throws APIException
playerName - the username of the playerpassword - the password for the indicated player
APIException - thrown if player does not exist or if password was wrong
void logout(java.lang.String sessionKey)
throws APIException
sessionKey - the 256-digit generated session key
APIException - if session does not exist
Message mail(java.lang.String sessionKey,
java.lang.String receivingPlayer,
java.lang.String message)
throws APIException
Message to a remote Player.
sessionKey - the session key of the authenticated PlayerreceivingPlayer - the name of the remote Player to chat withmessage - the content of the message
Player
APIException - if the given session key is invalid, orPlayer name is unknown, or
void makeProductItemAvailableTo(java.lang.String sessionKey,
long productItemId,
java.lang.String player,
boolean available)
throws APIException
sessionKey - the key of the session of the Player who is collecting the itemproductItemId - player - available -
APIException - if the session key is invalid, or
Gbangoo mine(java.lang.String sessionKey,
long gbangooId)
throws APIException
sessionKey - the session key of the authenticated usergbangooId - the id of the Gbangoo that should start mining
APIException - fails if the session key is wrong,
Event move(java.lang.String sessionKey,
long entityId,
long direction)
throws APIException
Entity towards a given direction
sessionKey - the session key of the authenticated PlayerentityId - the id to the placeable Entity to movedirection - the direction to move towards
Event
APIException - if the session key is invalid, orEntity id is unknown, orEntity is not placeable, or
void notify(java.lang.String sessionKey,
java.lang.String player,
java.lang.String title,
java.lang.String description,
long avatar,
boolean shareable)
throws APIException
sessionKey - the key of the session of the Player that owns the entityplayer - the name of the Player to be notifiedtitle - the title of the notificationdescription - the description of the notificationavatar - the avatar image that should be included with the notification (or 0 if no image
shall be included)shareable - a flag that indicates whether this notification is recommended
for being shared with others
APIException - if the session key is invalid, the player name is unknown,
or if no such title, description or avatar can be found
Player offerFriendship(java.lang.String sessionKey,
java.lang.String player,
java.lang.String introduction)
throws APIException
sessionKey - the session key of the authenticated userplayer - the possibly new friendintroduction - an initial phrase ("optional": if not indicated, use an empty string)
APIException - fails if the session key is wrong,
Pocket pick(java.lang.String sessionKey,
long tagId)
throws APIException
sessionKey - the session key of the authenticated usertagId - the id of the tag to take
APIException - if the session key does not exist, or
Tile piece(java.lang.String sessionKey,
long tagId,
long tileId)
throws APIException
sessionKey - the session key of the authenticated usertagId - the id of the tag to droptileId - the id of the tile to drop the tag onto
APIException - if the session key does not exist, or
Challenge playCard(java.lang.String sessionKey,
long challengeId,
long tagId)
throws APIException
sessionKey - the session key of the authenticated userchallengeId - the match to play the card intagId - the tag to play
APIException - fails if the session key is wrong,
void playSound(java.lang.String sessionKey,
java.lang.String name,
long melodyId)
throws APIException
Player if logged in and if settings allow.
sessionKey - the key of the session of the chummy Playername - the name of the Player that should experience the soundmelodyId - the id of the melody
APIException - if the session key is invalid, the player name is unknown or not a friend or the id of the melody is invalid
Trade postOffer(java.lang.String sessionKey,
long tradeId)
throws APIException
sessionKey - the session key of the authenticated usertradeId - the offer to be sent
APIException - fails if the session key is wrong,
Trade prepareOffer(java.lang.String sessionKey,
java.lang.String partnerName)
throws APIException
sessionKey - the session key of the authenticated userpartnerName - the requested trading partner
APIException - if the partner with the indicated name does not exist
Cell rateCell(java.lang.String sessionKey,
long cellId,
byte rating,
java.lang.String comment)
throws APIException
sessionKey - the session key of the authenticated usercellId - the id of the cell for the ratingrating - the personal rating valuecomment - an optional comment
APIException - fails if the session key is wrong,
Tag rateTag(java.lang.String sessionKey,
long tagId,
byte rating,
java.lang.String comment)
throws APIException
Cell.
sessionKey - the session key of the authenticated PlayertagId - the id of the Tag to raterating - the given ratingcomment - an optional semi-colon separated comment
Tag
APIException - if the given session key is invalid, orTag id is unknown, or
void register(java.lang.String playerName,
java.lang.String password,
java.lang.String cellPhone,
java.lang.String email,
java.lang.String model,
java.lang.String language,
java.lang.String method)
throws APIException
playerName - the username of the playerpassword - the passwordcellPhone - the cell phone number including international predial codeemail - a correct email address to submit the confirmation tomodel - the model of the cell phonelanguage - the language the person wants to receive texts inmethod - the sign up method, e.g. website, mobile, in-game
APIException - thrown if player name is taken, the password is not verified or the cellPhone or email are invalid
void registerFB(java.lang.String playerName,
java.lang.String fbuid,
java.lang.String fbsession,
java.lang.String model,
java.lang.String language,
java.lang.String method)
throws APIException
playerName - the username of the playerfbuid - the facebook user idfbsession - the facebook offline session keymodel - the model of the cell phonelanguage - the language the person wants to receive texts inmethod - the sign up method, e.g. website, mobile, in-game
APIException - thrown if player name is taken, the password is not verified or the cellPhone or email are invalid
void registerFQ(java.lang.String playerName,
java.lang.String fquid,
java.lang.String fbsession,
java.lang.String model,
java.lang.String language,
java.lang.String method)
throws APIException
playerName - the username of the playerfquid - the foursquare user idfbsession - the foursquare session keymodel - the model of the cell phonelanguage - the language the person wants to receive texts inmethod - the sign up method, e.g. website, mobile, in-game
APIException - thrown if player name is taken, the password is not verified or the cellPhone or email are invalid
void registerLess(java.lang.String playerName,
java.lang.String iphoneid,
java.lang.String model,
java.lang.String language,
java.lang.String method)
throws APIException
playerName - the username of the playeriphoneid - the iphone unique idmodel - the model of the cell phonelanguage - the language the person wants to receive texts inmethod - the sign up method, e.g. website, mobile, in-game
APIException - thrown if player name is taken, the password is not verified or the cellPhone or email are invalid
void registerTwitter(java.lang.String playerName,
java.lang.String tuid,
java.lang.String fbsession,
java.lang.String model,
java.lang.String language,
java.lang.String method)
throws APIException
playerName - the username of the playertuid - the twitter user idfbsession - the twitter session keymodel - the model of the cell phonelanguage - the language the person wants to receive texts inmethod - the sign up method, e.g. website, mobile, in-game
APIException - thrown if player name is taken, the password is not verified or the cellPhone or email are invalid
void remindPassword(java.lang.String phoneOrEmail)
throws APIException
Request a password reminder message to an email address or a cell phone.
Remark: There is no warning if the phone number or email address are unregistered Players.
phoneOrEmail - a valid phone number or an email.
APIException - if the format of the phone number or the email is incorrect.
void removeMemory(java.lang.String sessionKey,
java.lang.String entityId,
java.lang.String key)
throws APIException
Entity's memory.
sessionKey - the session key of the authenticated PlayerentityId - the id/name of the Entity which memory should be modifiedkey - the key to remove
APIException - if the session key is invalid, orEntity id is unknown, or
Cell renameCell(java.lang.String sessionKey,
long cellId,
java.lang.String name)
throws APIException
sessionKey - the session key of the authenticated usercellId - the id of the cell with a new namename - the new name
APIException - fails if the session key is wrong,
int reportBug(java.lang.String author,
java.lang.String content,
int severity)
throws APIException
author - a (registered) author (email, cellphone number or Gbanga username)content - a precise problem descriptionseverity - a severity level
APIException - if the author, the content or the severity level are invalidBUG_SEVERITY_CRITICAL,
BUG_SEVERITY_MAJOR,
BUG_SEVERITY_NORMAL,
BUG_SEVERITY_MINOR,
BUG_SEVERITY_TRIVIAL,
BUG_SEVERITY_ENHANCEMENT
Report reportPlayer(java.lang.String sessionKey,
java.lang.String player,
java.lang.String explanation)
throws APIException
Report an incident about a player that didn't comply with the regulations (rudeness in chat messages, privacy tricks, fraud, creating dangerous quests, etc.).
Remark: Anonymous reports without a valid session key are logged, but not read nor taken action upon
sessionKey - the session key of the authenticated userplayer - the player that was the reason for the incidentexplanation - an verbose description of the incident
APIException - if no player with the given id exists
DownloadRequest requestDownloadSMS(java.lang.String playerName,
java.lang.String password)
throws APIException
playerName - the username of the playerpassword - the password for the indicated player
DownloadRequest object
APIException - if the service is currently not available or the session key is invalid.
DownloadRequest requestDownloadSMSByHeader(java.lang.String playerName,
java.lang.String password,
java.lang.String header)
throws APIException
requestDownloadSMS(String, String) but also uses the given
http header to guess the user's device.
playerName - the username of the playerpassword - the password for the indicated playerheader - the http header
DownloadRequest object
APIException
DownloadRequest requestDownloadSMSBySessionKey(java.lang.String sessionKey)
throws APIException
sessionKey - the session key
DownloadRequest object
APIException - if the service is currently not available or the session key is invalid.
void requestPurchasedItem(java.lang.String sessionKey,
java.lang.String appleProductId,
java.lang.String transactionId,
java.lang.String receipt)
throws APIException
sessionKey - the temporarily valid key of a player's sessionappleProductId - the memory keytransactionId - the value to filter withreceipt - the receipt provided by apple
APIException
WebSession resume(java.lang.String playerName,
java.lang.String sessionKey)
throws APIException
playerName - the username of the playersessionKey - the temporarily valid session key of that player's session
APIException - thrown if player does not exist, the session was closed or not existing
void reward(java.lang.String sessionKey,
java.lang.String player,
int points)
throws APIException
Player with points.
sessionKey - the key of the session of the Player who requests a reward for
the give playerplayer - the Player to rewardpoints - the number of points to reward
APIException - if the session key is invalid or the player to reward is unknown
boolean setCode(java.lang.String key,
long id,
java.lang.String code)
throws APIException
key - the key of the session of the Player that owns the entityid - the id of the entity to apply a download code forcode - a code of your choice (or null to remove download code)
true, if it is already used it returns false
APIException - if the session key is invalid, the entity unknown or not owned by the requesting Player or the download code inappropriate, too long or invalid
void setMemory(java.lang.String sessionKey,
java.lang.String entityId,
java.lang.String key,
java.lang.String value)
throws APIException
Entity's memory.
sessionKey - the session key of the authenticated PlayerentityId - the id/name of the Entity which memory should be modifiedkey - the key name to addvalue - the value to the key
APIException - if the session key is invalid, orEntity id is unknown, or
void setMemoryForAll(java.lang.String sessionKey,
java.lang.String key,
java.lang.String value)
throws APIException
Entity's memory having the key.
sessionKey - the session key of the authenticated Playerkey - the key name to setvalue - the value to the key
APIException - if the session key is invalid, or
void setTradable(java.lang.String sessionKey,
long entityId,
boolean yes)
throws APIException
sessionKey - the key for the session of the owning PlayerentityId - the id of the entity to modify the tradable statusyes - true to make it tradable
APIException - if the session key is invalid, the entity id unknown or the entity not owned by the current player
Message shout(java.lang.String sessionKey,
java.lang.String receivingCell,
java.lang.String message)
throws APIException
Message to a Cell.
sessionKey - the session key of the authenticated PlayerreceivingCell - the name of the Cell to shout atmessage - the content of the message
APIException - if the given session key is invalid, orCell name is unknown, or
void showTicker(java.lang.String sessionKey,
java.lang.String name,
java.lang.String ticker)
throws APIException
Player if logged in and if settings allow.
sessionKey - the key of the session of the chummy Playername - the name of the Player that should receive the ticker messageticker - a message to be shown
APIException - if the session key is invalid, the player name is unknown or not a friend or the id of the message is inappropriate
Event speak(java.lang.String sessionKey,
long gbangooId,
java.lang.String message)
throws APIException
Gbangoo send the message to everyone in its current cell.
sessionKey - the session key of the authenticated PlayergbangooId - the id of the sending Gbangoomessage - the content of the message
Conversation Event
APIException - if the session key is invalid, orGbangoo id is unknown, or
Event speakTo(java.lang.String sessionKey,
long gbangooId,
java.lang.String player,
java.lang.String message)
throws APIException
Gbangoo send a message to the specified player.
sessionKey - the session key of the authenticated PlayergbangooId - the id of the receiving Gbangooplayer - the player to whom to send the messagemessage - the content of the message
Conversation Event
APIException - if the session key is invalid, orGbangoo id is unknown, or
Gbangoo stop(java.lang.String sessionKey,
long gbangooId)
throws APIException
sessionKey - the session key of the authenticated usergbangooId - the id of the Gbangoo that should stop
APIException - fails if the session key is wrong,
void submitStatistics(java.lang.String sessionKey,
java.lang.String data)
sessionKey - the key of the session to post statistics fordata - statistiscal data
java.lang.String subscribeToWebHook(java.lang.String sessionKey,
int event,
java.lang.String filter,
java.lang.String url)
throws APIException
sessionKey - the key of the session to register the listener forevent - the event type for which to subscribefilter - the filter that received events are required to matchurl - the location of the Web Hook listener
APIException - If an error occurred during subsription
int takeOverCell(java.lang.String sessionKey,
java.lang.String playerName,
java.lang.String cellName,
java.lang.String newOwner)
throws APIException
sessionKey - the session key of a logged in super userplayerName - the player that is taking overcellName - the cell namenewOwner - the name of the family that now is the owner of this cell
APIException - thrown if the sessionKey doesn't have the required privileges of the cellId is unknown
Trade trade(java.lang.String sessionKey,
java.lang.String partnerName,
java.lang.String offeredGoodIdString,
java.lang.String requestedGoodIdString)
throws APIException
sessionKey - the session key of the authenticated userpartnerName - the requested trading partnerofferedGoodIdString - an array of ids of a goods to offer (may be 0, if nothing to offer)requestedGoodIdString - an array of ids of a good that are being requested (may be 0, if nothing is requested)
APIException - fails if the session key is wrong,
int transferInfrastructuresAndCells(java.lang.String sessionKey,
java.lang.String playerName,
java.lang.String newFamily)
throws APIException
sessionKey - the session key of a logged in super userplayerName - the name of the playernewFamily - the name of the new family
APIException - thrown if the sessionKey doesn't have the required privileges
java.lang.String unsubscribeFromWebHook(java.lang.String sessionKey,
java.lang.String url)
throws APIException
sessionKey - the key of the session to register the listener forurl - the location of the Web Hook listener
APIException - If an error occurred during un-subscription
void updateAvatar(java.lang.String sessionKey,
long entityId,
java.io.InputStream is)
throws APIException
sessionKey - the key of the session requesting the updateentityId - the id of the entity that needs a new avataris - the stream with the avatar data
APIException - if session key is invalid, the entity is unknown or not owned nor created by the current Player or the input stream invalid
void updateAvatarByRef(java.lang.String sessionKey,
long entityId,
long avatarId)
throws APIException
Note that after updating the avatar using this method, updating the avatar image will change the entity's avatar, and, conversely, updating the entity's avatar by specifying an image will update the avatar of other entities referencing the same image.
sessionKey - the key of the session requesting the updateentityId - the id of the entity that needs a new avataravatarId - the id of the existing avatar image
APIException - if session key is invalid, the entity is unknown or not owned
nor created by the current Player or
the existing avatar may not be used by the requester
void updateDescription(java.lang.String sessionKey,
long entityId,
java.lang.String description)
throws APIException
sessionKey - the key of the session of the owning PlayerentityId - the id of the entity which needs a new descriptiondescription - the descriptive text (might have some formatting)
APIException - if the session key is invalid, the entity id unknown or not owned by the requesting Player or the descriptive text inappropriate
void updateEmail(java.lang.String sessionKey,
java.lang.String playerName,
java.lang.String email)
throws APIException
Player.
sessionKey - the session key of the authenticated PlayerplayerName - the name of the target player, empty to target self.email - a valid email address
APIException - if the session key is invalid, or
void updateGbangooType(java.lang.String sessionKey,
long type,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
throws APIException
Gbangoo type. Any of the type properties may be updated, whereby
a value of null for a property implies that that property will not be updated.
sessionKey - the session key of the authenticated Playertype - the numerical id uniquely identifying the type to updateavatar - the new avatar image displayed for Gbangoos of the specified typedescription - the new description displayed for Gbangoos of the specified typecomment - an optional comment describing the purpose of the specified type
APIException - if the session key is invalid, or
void updateInfrastructureType(java.lang.String sessionKey,
long type,
java.io.InputStream avatar,
java.lang.String description,
java.lang.String comment)
throws APIException
Infrastructure type. Any of the type properties may be updated, whereby
a value of null for a property implies that that property will not be updated.
sessionKey - the session key of the authenticated Playertype - the numerical id uniquely identifying the type to updateavatar - the new avatar image displayed for infrastructures of the specified typedescription - the new description displayed for infrastructures of the specified typecomment - an optional comment describing the purpose of the specified type
APIException - if the session key is invalid, or
Player updateProfile(java.lang.String sessionKey,
java.lang.String cellphone,
java.lang.String email)
throws APIException
Player.
sessionKey - the session key of the authenticated Playercellphone - the cell phone in a valid format (+12 3456 789) which includes the country codeemail - a valid email address
Player object
APIException - if the session key is invalid, or
void updateProfileImage(java.lang.String sessionKey,
java.io.InputStream image)
throws APIException
Player.
sessionKey - the session of the Player with the profile image that needs to be updatedimage - the image data as a binary
APIException - if the session is invalid or the image could not be parsed
void updateResourceType(java.lang.String sessionKey,
long type,
java.lang.String screenname,
java.io.InputStream avatar,
java.lang.String description)
throws APIException
Resource type. Any of the type properties may be updated, whereby
a value of null for a property implies that that property will not be updated.
sessionKey - the session key of the authenticated Playertype - the numerical id uniquely identifying the type to updatescreenname - the screen name displayed for resources of the specified typeavatar - the new avatar image displayed for resources of the specified typedescription - the new description displayed for resources of the specified type
APIException - if the session key is invalid, or
Player updateStatus(java.lang.String sessionKey,
java.lang.String status)
throws APIException
Player in a manner similar to a Twitter message, Facebook's status or a tagline in any instant messenger (eg, MSN and Skype).
sessionKey - the session of the Player with the profile image that needs to be updatedstatus - a valid status message
Player object
APIException - if the session key is invalid, orFeature whereAmI()
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||