Previous Topic

Next Topic

Locate topic in Contents

HSPC/API/Person

auth_person

The function authenticates a person.

Parameters:

email

Person e-mail. Together with password can be replaced with sid.

password

Person password. Together with email can be replaced with sid.

ip

Optional parameter. Customer IP. If specified, the anti-fraud Login Filter is activated.

sid

Client CP session ID (SID). Optional parameter. Can be passed instead of email and password and in this case a customer will be authenticated in Store by this session ID.

login_to_cp

Optional parameter. The value can be 1 (true) or 0 (false). If true, the function will include the client CP session ID (SID) into the response.

Returns: PERSON_INFO:

{

'sid' => 'e3b09cb237a41b6867bcbb62ac8899da',

'person' => {

'lang' => 'en',

'person_id' => '5',

'account_list' => [

{

'status' => '0',

'vendor_id' => '1',

'person_id' => '5',

'name' => 'Account Name',

'type' => '3',

'account_id' => '5'

}

],

'middle_name' => '',

'last_name' => 'Smith',

'email' => 'smith@mail.com',

'insertion' => '',

'comment' => '',

'suffix' => '',

'gender' => 'female',

'prefix' => '',

'first_name' => 'Jane'

}

};

SOAP Faults codes:

UserAuthen

User authentication error.

The returned hash presents person information:

Parameter

Means

sid

Client CP session ID. Returned in case the sid parameter is passed with the 'true' value.

person

Person information. Contains hash:

Parameter

Means

lang

Two-letter ISO 639 language codes abbreviation in lower case of the interface language set for a person.

person_id

Person numerical identifier assigned in the HSPComplete database.

account_list

Properties of the account a person is associated with. Contains hash:

status - Account status: 0 - 'active', 1 - 'on_hold', 2 - 'for_approval' (held by anti-fraud filter and waits for vendor manual approval), 255 - 'deleted'.
vendor_id -Numerical identifier of vendor account (provider or reseller). This is an account ID assigned automatically in Parallels Business Automation - Standard.
person_id - Person numerical identifier assigned in the Parallels Business Automation - Standard database.
name - Account name.
type - Account type: 1- Provider account, 2 -Reseller account, 3 - Customer account.
account_id - Account numerical identifier assigned automatically in Parallels Business Automation - Standard.

middle_name

Person middle name.

last_name

Person last name.

email

Person e-mail used as password.

insertion

Person last name insertion.

comment

Free-form comment that can be added to a person information.

suffix

Person name suffix.

gender

Person gender: Male or Female.

prefix

Person name prefix (Mr, Mrs, etc.).

first_name

Person first name.

 

get_person_info

The function returns a registered person details by a person numerical ID assigned on registration in the Parallels Business Automation - Standard database.

Parameters:

person_id

A registered person numerical identifier assigned in the Parallels Business Automation - Standard database

SOAP Faults codes:

MissingPerson

Person not found

PersonsDenied

You are not allowed to access persons

Returns:

$VAR1 = {
'lang' => 'en',
'person_id' => '2',
'account_list' => [
{
'status' => '0',
'vendor_id' => '1',
'person_id' => '2',
'name' => 'First Last',
'type' => '3',
'account_id' => '2'
}
],
'middle_name' => '',
'last_name' => 'Last',
'email' => 'mail@provider.com',
'insertion' => '',
'comment' => '',
'suffix' => '',
'gender' => 'M',
'prefix' => '',
'first_name' => 'First'
};

Please send us your feedback on this help page