The registration procedure involves sending some information about a new member to the igGameCenter API and receiving an XML response containing member's ID, name and hashed password.
For registration of a new member account an external application should send a POST request to the following API script:
http://www.iggamecenter.com/api_user_add.php
containing the following parameters:
| Field Name |
Field Content |
Field Format |
| app_id |
Application unique ID. |
mandatory, numeric |
| app_code |
Application secret passcode. |
mandatory, alpha-numeric |
| name |
Desired member's nickname. |
mandatory, alpha-numeric + some other symbols |
| password |
Desired member's password. |
mandatory, alpha-numeric + some other symbols |
| email |
Member's email. |
optional, alpha-numeric + some other symbols |
| realName |
Member's real name. |
optional, alpha-numeric + some other symbols |
| sex |
Member's sex. |
optional, 1 character (can be M, F or -) |
| birthDay |
Day of member's birth. |
optional, numeric (1-31) |
| birthMonth |
Month of member's birth. |
optional, numeric (1-12) |
| birthYear |
Year of member's birth. |
optional, numeric (4 digits) |
| country |
2-letters country code. |
optional, 2 characters |
| location |
More details about member's location. |
optional, alpha-numeric + some other symbols |
| about |
Any text information that the member wants to share. |
optional, alpha-numeric + some other symbols |
| subscribeNews |
Any non-zero value means that the member is willing to subscribe to igGameCenter's newsletter. |
optional, numeric |
| showEmail |
Any non-zero value means that the member is willing to show his email on his public profile. |
optional, numeric |
| showBirthday |
Any non-zero value means that the member is willing to show his birthday on his public profile. |
optional, numeric |
| networkuid |
A unique id associated with the physical device / site / social network. |
optional, alpha-numeric + dashes + underscores, max 64 symbols |
If the external application specifies a non-empty networkuid then igGameCenter will allow to create only a single account per specified ID. Any attempts to register a new account with the same networkuid will return the information about the previously registered account without registering a new one.
The returned response will be one of the following:
Success response:
<userAddResult>
<uid>333</uid>
<name>ChessMaster</name>
<password>xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx</password>
</userAddResult>
Failure response:
<errorMessage>--Some error message--</errorMessage>
where
| Field Name |
Field Content |
| uid |
Member's ID |
| name |
Member's Nickname |
| password |
MD5(Member's Password) |
| errorMessage |
Could be one of the following error messages:
| DATABASE_ERROR |
- some fatal error occured while accessing DB |
| INVALID_APP_ID |
- invalid application ID specified |
| INVALID_APP_CODE |
- invalid application passcode specified |
| INVALID_EMAIL |
- invalid email specified |
| INVALID_BIRTH_DATE |
- invalid birthday specified |
| INVALID_PASSWORD |
- invalid password specified |
| SPECIFY_COUNTRY |
- invalid country specified |
| NICK_TOO_LONG |
- nickname cannot be longer than 15 symbols |
| NICK_INVALID_SYMBOLS |
- nickname contains invalid symbols |
| NICK_NO_ENG_LETTERS |
- nickname should contain at least three consecutive letters |
| DUPLICATE_NICK |
- another account is found using the same nickname |
| DUPLICATE_EMAIL |
- another account is found using the same email |
|
|