Customer Service

The customer web service allows the management of all the customer related information. The API allows you to create, delete, and update your customers. You can retrieve individual customers as well as a list of all your customers.


http://webservices.gr8pay.net/v2/customer.svc

GetCustomer Method

The service will return all of the user’s information – from addresses to private information, such as DOB and more.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
GetCustomerApplicationTokenYesstring“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


RegisterCustomer Method

This is the “Sign up” service – you will use this service to register a new Customer.

The service will enable you to register all of the user’s information along with a shipping address and payment method.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
dataNoCustomer.CustomerRegisterData“6224A847-4867-41EE-851D-36CC8BA1B”
ApplicationTokenNoString
PasswordNoString
PinCodeNoString
ShippingAddressNoArray
AddressLine1NoString
AddressLine2NoString
CityNoString
CountryIsoNoString
PostalCodeNoString
StateIsoNoString
CommentNoString
IDNoString
IsDefaultNoString
TitleNoString
StoredPaymentMethodsNoPaymentMethods.StoredPaymentMethod
AccountValue1NoString
AccountValue2NoString
BillingAddressNoServiceAddress
AddressLine1NoString
AddressLine2NoString
CityNoString
CountryIsoNoString
PostalCodeNoString
StateIsoNoString
DisplayNoString
ExpirationDateNodateTime
IDNoInt
IconNoString
IsDefaultNoBoolean
IssuerCountryIsoCodeNoString
Last4DigitsNoString
OwnerNameNoString
PaymentMethodGroupKeyNoString
TitleNoString
InfoNoCustomer.CustomerData
AddressLine1NoString
AddressLine2NoString
CityNoString
CountryIsoNoString
PostalCodeNoString
StateIsoNoString
CellNumberNoString
CustomerNumberNoString
DateOfBirthNoString
EmailAddressNoString
FirstNameNoString
LastNameNoString
PersonalNumberNoString
PhoneNumberNoString
ProfileImageNoBase64Binary
ProfileImageSizeNoLong
RegistrationDateNodateTime

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


SaveCustomer Method

After a Customer has been  successfully registered, any change to the customer’s personal information will be saved using this function.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
infoNoString“6224A847-4867-41EE-851D-36CC8BA1B”
ServiceAddressArray
AddressLine1NoString
AddressLine2NoString
CityNoString
CountryIsoNoString
PostalCodeNoString
StateIsoNoString
CellNumberNoString
CustomerNumberNoString
DateOfBirthNoString
EmailAddressNoString
FirstNameNoString
LastNameNoString
PersonalNumberNoString
PhoneNumberNoString
ProfileImageNobase64Binary
ProfileImageSizeNoLong
RegistrationDateNodateTime

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


FindFriend Method

The search function will allow you send certain terms, with a definition of the page size and the page number.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
destWalletIdApplicationTokenNostring“Bobby”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


FriendRequest Method

By sending the destination wallet ID the source user will send a request to the destination user.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
destWalletIdApplicationTokenNostring“Bobby”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


GetFriendRequests Method

The service will return all pending friend requests tothe user and will provide the necessary info to reply to the requests.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
GetCustomerApplicationTokenYesstring“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


GetFriends Method

The service will return a list of all of the user’s friends with their information.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
destWalletIdApplicationTokenNostring“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


ImportFriendsFromFacebook Method

<<Description to Follow>> – Import your Facebook Friends

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
InfoApplicationTokenYesstring“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#XMLJSON


RemoveFriend Method

Simple, enough this service will help you delete the friend you no longer wish to have.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
destWalletIdNostring“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


ReplyFriendRequest Method

The combo of “Friend request” / “GetFriendRequests” and “ReplyFriendRequest” give the full management of the friendship cycle.

After sending a friend request to a user the user can decide whether  or not to approve the request . This service allows you to send the appropriate response to the request.

Request Fields

FieldNameMandatory?Field TypeDescriptionSample
destWalletIdNostring“6224A847-4867-41EE-851D-36CC8BA1B”
ApproveNoboolean

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


SetFriendRelation Method

Relationships are important – we give every user the ability to save a relationship setting for each friend..

Relation types:

  • 10 – Immediate family – Spouse, parent, brother, sister, son, etc.
  • 20 – Extended family – Grandparent, aunt, uncle, cousin, etc.
  • 30 – Friend
  • 50 – Colleague        
  • 60 – Acquaintance
  • 70 – Other     

Request Fields

FieldNameMandatory?Field TypeDescriptionSample
destWalletIdNostring
relationTypeKeyNoint

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


GetPositions Method

This method allows to get full list of positions of the currently logged in user

Request Fields

ParameterMandatoryTypeDescription
This method has an empty body as it doesn't require any input parameters. It takes user's credentials token from the request's header automatically and this way detects data for which user has to be returned. Check Headers topic to get more info on how to add credentials token to request's headers.

Response Fields

ParameterTypeDescription
IDintThis will return the IDs of the positions available for the Customer

C#JavaScriptPHP

GetPosition

This method will return all info of a specific position

Request Fields

ParameterMandatoryTypeDescription
IDYesstringID of the position as it was returned from GetPositions service

Response Fields

ParameterMandatoryTypeDescription
TitleintThe title of the position such as CEO/COO/CMO etc
SummaryintA short description of the position
IsCurrentintIs the customer still working at that position
CompanyintThe name of the company the customer works at.
CompanySiteintThe website of the company the customer works at
StartDateintThe date the customer started working at the position.
EndDateintThe date the customer stopped working at the position.
IndustryintThe industry in which the company belongs to.


C#JavaScriptPHPJSON


SetPosition Method

This method allows to get full info about the currently logged in user

Request Fields

ParameterMandatoryTypeDescription
TitleintThe title of the position such as CEO/COO/CMO etc
SummaryintA short description of the position
IsCurrentintIs the customer still working at that position
CompanyintThe name of the company the customer works at.
CompanySiteintThe website of the company the customer works at
StartDateintThe date the customer started working at the position.
EndDateintThe date the customer stopped working at the position.
IndustryintThe industry in which the company belongs to.

Response Fields

ParameterTypeDescription
IDintThis will return the IDs of the positions available for the Customer


C#JavaScriptPHP


GetImage Method

The service will return the image for the wallet ID

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
walletIdApplicationTokenNostring“6224A847-4867-41EE-851D-36CC8BA1B”
asRawNoboolean

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


DeleteShippingAddress Method

Delete a user’s specific shipping address by using the AddressID.

Request Fields

FieldNameMandatory?Field TypeDescriptionSample
searchTermNostring“Bob”
sortAndPageNoSortAndPage
PageNumberNoint
PageSizeNoint

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


GetShippingAddress Method

The service will return the  specific shipping address details through  the shipping address ID.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
addressIdApplicationTokenNoInt“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


GetShippingAddresses Method

The service will return all of the user’s shipping addresses.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
InfoApplicationTokenYesstring“6224A847-4867-41EE-851D-36CC8BA1B”

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


SaveShippingAddresses Method

Managing shipping addresses can have its complexities – when saving a new “Default shipping address” the rest of the addresses are also affected – this service will allow changes to be made  to all addresses at the same time.

Request Fields

FieldName Mandatory?Field TypeDescriptionSample
datanoarray
AddressLine1NoString
AddressLine2NoString
CityNoString
CountryIsoNoString
PostalCodeNoString
StateIsoNoString
CommentNoString
IDNoInt
IsDefaultNoBoolean
TitleNoString

Response Fields

Field NameField TypeDescription
CodeInteger
IsSuccessBoolean
KeyString
MessageStringSee Return Codes Table*
NumberString


C#JavaScriptPHP


RegisterCustomerAsSubAccount

This method allows to register a new user in the system which will be defined as a subuser for the already registered user. The subuser will be as any other user in the system but will connected to the main account with a relation type. The subaccount registration process is shorter but the ability to add additional info to the subaccount is available using the “SaveCustomer” service.It also automatically checks whether provided email was registered earlier to avoid creating accounts with similar emails.

Request Fields

ParameterMandatoryTypeDescription
DataNoThis block contains registration data
ApplicationTokenNostringSet your application token here
PasswordNostringUser's password
PinCodeNostringUser's PIN code
CellNumberNostringUser's cell phone number
EmailAddressNostringUser's email
FirstNameNostringUser's first name
LastNameNostringUser's last name
PersonalNumberNostringUser's personal number
PhoneNumberNostringUser's phone number

Response Fields

ParameterTypeDescription
CodeintResult code
IsSuccessbooleanDefines whether service call was processed successfully or not
KeystringResult key ("Success", "Error", etc.)
MessagestringResult message


C#JavaScriptPHP


GetChildCredentials

This method allows already existing users to log into the system.

Request Fields

ParameterMandatoryTypeDescription
childCustomerNumberYesstringCustomer ID of the sub account you wish to login on his behalf

Response Fields

ParameterTypeDescription
CodeintResult code
IsSuccessbooleanDefines whether service call was processed successfully or not
KeystringResult key ("Success", "Error", etc.)
MessagestringResult message
CredentialsHeaderNamestringName of the header which should hold credentials token. Check headers' topic to get more info
CredentialsTokenstringUser's credentials token, which should be also added to headers. Check headers' topic to get more info
EncodedCookiestring*TBD*
IsDeviceActivatedbooleanDefines whether devices was activated using DeviceActivate method
IsDeviceBlockedbooleanDefines whether device was blocked by the system
IsDeviceRegisteredbooleanDefines whether devices was registered using RegisterDevice method
IsDeviceRegistrationRequiredbooleanDefines whether registering device with RegisterDevice method is required
IsFirstLoginbooleanDefines whether this is first login for the account
LastLogindateTimeDate of the previous login with this account
VersionUpdateRequiredbooleanDefines whether application has to be updated


C#JavaScriptPHP


GetManagedAccounts Method

This method allows to get the list of all sub accounts for the currently logged in user

Request Fields

ParameterMandatoryTypeDescription
This method has an empty body as it doesn't require any input parameters. It takes user's credentials token from the request's header automatically and this way detects data for which user has to be returned. Check Headers topic to get more info on how to add credentials token to request's headers.

Response Fields

ParameterMandatoryTypeDescription
CustomerNumberNostringID of the user
CustomerNameNostringUser's full name


C#JavaScriptPHP