checkUser

Vend posts the checkUser postback to verify that a username/password combination is valid and available in your platform.

Request parameters

Parameter

Data type

Description

callback

string

Specifies the action for this request, which in this case is "checkUser".

username

string

End user's username.
Example: bob123

password

string

End user's password.
Example: AbC112233

email

string

End user's email.
Example: [email protected]

subscription_id

numeric

Vendo's subscription identifier.
Example: 12312312

site_id

numeric

Vendo's site identifier.
Example: 87111

merchant_reference

string

The custom reference that you passed in the join link via the ref parameter.
Example: 60022*32d5fe4257adf1ba36*1*0*2b

is_test

boolean

Whether or not this request is related to a test transaction or subscription.
0 for no (real transaction)
1 for yes (test transaction)

Your server must reply with one of these response formats:

OK (Response code 1)

Reply with this if the username is available in your system and the transaction may continue.

Example:

<?xml version="1.0" encoding="UTF-8"?>
<postbackResponse>  
 <checkUser>       
  <code>1</code> 
 </checkUser>
</postbackResponse>

ERROR (Response code 2)

Reply with this if you encountered an unexpected problem with the request.

Include a custom error message with your message for tracing/debugging. Make sure this error message is meaningful because it is stored to a logfile for later debugging.

Example:

<?xml version="1.0" encoding="UTF-8"?>
<postbackResponse> 
 <checkUser>  
  <code>2</code>  
  <errorMessage>Custom error message</errorMessage> 
 </checkUser>
</postbackResponse>

NOT AVAILABLE (Response code 3)

Reply with this if the username is not available in your system, f.ex. if it's already in use by a different user.
Vendo will autogenerate a new username and attempt a new checkUser postback.

Example:

<?xml version="1.0" encoding="UTF-8"?>
<postbackResponse> 
 <checkUser> 
  <code>3</code> 
 </checkUser>
</postbackResponse>

OK MODIFIED (Response code 4)

Reply with this if the user was granted access but with different credentials than the one we sent.
To overwrite the user details in our system the new username or password should be passed in the response.
Otherwise the old ones will be maintained.

Example:

<?xml version="1.0" encoding="UTF-8"?>
<postbackResponse>
  <checkUser>    
   <code>4</code>    
   <username>new-username</username>    
   <password>new-password</password> 
 </checkUser>
</postbackResponse>

Did this page help you?