Skip to content

EliecontService

EliecontService.asmx

This web service provides methods related to eContacts. It can add/change/delete a contact, add/delete relationship, view contacts or relationships, and provide login/logout methods.

To understand what a contact and relationship are, imagine this: We have a contact “Jim Smith” with customer “21st Century Enterprise.” If “Jim Smith” is also with customer “T-Shirts Unlimited,” then we will have one contact record “Jim Smith” and two relationship records which link “Jim Smith” to customers “21st Century Enterprise” and “T-Shirts Unlimited.” You may indicate which relationship is the “primary” relationship. It is important to know that some information is stored in contact and some information is stored in relationship. For example, the email address is stored in the contact table. The position is stored in the relationship table.

The two unique keys for a contact are Contact ID and Email Address. In methods that need to locate a contact record, such as ChangeContact, you can provide either one of the two key fields. If you provide both unique keys, the system will only use Contact ID to locate the record.

The following images show fields names in the eContact window:


 

AddContact

This method is used to add a contact. It will also add a relationship record. Please note that contact ID and Email are both unique keys. If contact ID or Email already exists, you will receive an error code 6.

Therefore, before you add an eContact, you should use the ViewContact method to determine if the eContact already exists under the email address. This can happen as soon as the user provides an email address to you. If contact already exists, you should ask the contact to login first. From there, you may optionally allow adding a relationship by using the AddRelationship method. There are also issues with determining if the newly added relationship should be primary or secondary.

For a contact record, the primary key is contact id; for a relationship record, the primary key is detail file + reference id + contact id.

Usage:

AddContactResult = A.AddContact(UserName, UserPassword, AddContactInput)

Parameters UserName and UserPassword are not used at this moment.

 

AddContactInput Structure

Property

Length

Type

Upper

Detail

SYCONTCT_ACCEPT_HTML

1

String

Y

“Y” or “N” (Default).

SYCONTCT_BLK_ACCESS

1

String

Y

“Y” or “N” (Default).

SYCONTCT_BLK_ACCS_DT

8

Date

 

Only pass a date value if you choose to block this contact from accessing the website by set SYCONTCT_BLK_ACCESS = “Y”

SYCONTCT_BLK_REASON

30

String

Y

See SYCONTCT_BLK_ACCS_DT

SYCONTCT_BLK_EMAIL

1

String

Y

“Y” or “N” (Default). If the contact does not wish to receive mass emails from you, you can set this flag to “Y”

SYCONTCT_BLK_EM_DT

8

Date

 

Only pass a date value if SYCONTCT_BLK_EMAIL is set to “Y”

SYCONTCT_ADDR_1

30

String

 

If the input SYCONTCT_LNK_ADR_FLG = “Y,” this field will be ignored, and this contact’s address information will be obtained from primary relationship’s address information, including address 1, address 2, city, state, zip code, country, company name.

On the other hand, if the input SYCONTCT_LNK_ADR_FLG = “N,” system will use the passed address information to update eContact.

SYCONTCT_ADDR_2

30

String

 

See SYCONTCT_ADDR_1.

SYCONTCT_CITY

15

String

 

See SYCONTCT_ADDR_1.

SYCONTCT_COUNTRY

20

String

 

See SYCONTCT_ADDR_1.

SYCONTCT_FAX

12

String

Y

If the SYCONTCT_LNK_FAX_FLG is “Y,” this field will be ignored, and the contact’s fax number will come from primary relationship. Keep in mind fax number only exists in customer file, and not in vendor or ship-to file.

SYCONTCT_ID

9

Integer

 

We suggest that you not assign any value to this field and let system sequentially assign a contact id.

SYCONTCT_NAME

30

String

 

Required.

SYCONTCT_PASSWD

12

String

 

Up to 12-digit case-  sensitive password. System will encrypt it before storing to the database and you can’t retrieve the un-encrypted password with ViewContact method. To authenticate a contact on your website, you should use Login method.

SYCONTCT_PASSWD_HINT

20

String

Y

This is optional and allows you to build stronger security to your website.

SYCONTCT_PASSWD_HT_V

20

String

Y

This is the hint value of SYCONTCT_PASSWD_HINT

SYCONTCT_PHONE

12

String

Y

If the SYCONTCT_LNK_TEL_FLG is “Y,” this field will be ignored, and the contact’s phone number will come from primary relationship. Keep in mind phone number exists in customer and vendor file and does not in ship-to file.

SYCONTCT_PHONE_EXT

5

String

Y

 

SYCONTCT_STATE

2

String

 

See SYCONTCT_ADDDR_1

SYCONTCT_ZIP

10

String

Y

See SYCONTCT_ADDDR_1

SYCONTCT_CREATE_DT

8

Date

 

This field is ignored since system will always use system date.

SYCONTCT_CREATE_TIME

6

Float

 

This field is ignored since system will always use system time.

SYCONTCT_EMAIL_ADDR

60

String

 

This field is required and must not duplicate. You should use ViewContact method to see if this email address already exists before using AddContact method.

SYCONTCT_HOME_PHONE

12

String

Y

 

SYCONTCT_LNK_ADR_FLG

1

String

Y

“Y” (Default): This contact’s address information will be linked to its primary relationship, and address information in input fields will be ignored. Address information includes address 1, address 2, city, state, zip code, country, and company name.

“N”: This contact’s address will not be linked to its primary relationship. You should provide address information in input fields of this method.

SYCONTCT_LNK_FAX_FLG

1

String

Y

“Y” (Default): This contact’s fax number will be linked to its primary relationship, and the value in SYCONTCT_FAX will be ignored.

“N”: This contact’s fax number will not be linked to its primary relationship. You should provide fax number in input field SYCONTCT_FAX if available.

SYCONTCT_LNK_TEL_FLG

1

String

Y

“Y” (Default): This contact’s telephone number will be linked to its primary relationship, and the value in SYCONTCT_PHONE will be ignored.

“N”: This contact’s telephone number will not be linked to its primary relationship. You should provide phone number in input field SYCONTCT_PHONE if available.

SYCONTCT_MOBIL_PHONE

20

String

Y

 

SYCONTCT_BOUNCEBACKS

4

Float

 

You should leave this field as zeroes with AddContact method. You may use ChangeContact method to update this field.

This is the number of bounce back emails from this eContact. There are certain commercial email solutions that allow you to aggregate bounce back email activities. If you can export the email address and number of bounce backs to CSV, then you can use Elliott’s import utility to update this bounce back field.

SYCONREL_DETAIL_FILE

8

String

Y

Required. This indicates a related file name of this contact. The likely values are “ARCUSFIL” for customer or “CPSHPFIL” for ship-to. The following are other commonly used file names:

“APVENFIL”: Vendor file.

“ARSLMFIL”: Salesman file.

“EMPFILE”: Employee file.

“CPORDHDR”: Order header.

“POORDHDR”: Purchase order header.

SYCONREL_REF_ID

30

String

Y

If SYCONREL_DETAIL_FILE is “ARCUSFIL,” then we expect you to pass the 6 digits customer number to this field. It is “CPSHPFIL,” then we expect you to pass the 6-digit customer number + 4-digit ship-to number. This is a required field and you must pass the primary key value of the corresponding file.

SYCONREL_PRIMARY_REL

1

String

Y

“Y” (Default): This is the primary relationship, which means the when the corresponding master record is changed, then this eContact’s address, credit card address, phone and fax number will be updated too if the related linking flag is set to “Y.”

“N”: This is not the primary relationship.

SYCONREL_ROLE

15

String

Y

You can set a role and its permissions by pushing “Role” button on “Web” tab of a contact. The “Role” is intended for security control of website users. You can create a role and set its access permissions of primary, subordinate and transaction files, then assign this role to a relationship.

For example, with ARCUSFIL, primary file refers to customer, subordinate file refers to ship-to, transaction file refer to sales order. There’s no strict rule for these permissions and the implementation is up to your website.

SYCONREL_POSITION

15

String

Y

Position is the title like “President” or “CFO” of this contact with the organization (e.g., a particular customer)

SYCONREL_PRIMARY_CT

1

String

Y

“Y”: This is the primary contact. For example, if customer “000001” has three contacts, one of them will be the primary contact. If another contact is currently the primary, this will result in that the other contact being demoted to non-primary contact. This flag is mostly relates to which contact shall receive emails like when an order is shipped.

“N” (Default): This is not the primary contact.

SYCONTCT_COMPANY_NA

30

String

 

This is this contact’s company or organization name if applicable.

SYCONTCT_BIRTH_YEAR

4

Integer

 

It may be difficult to collect complete birthday information due to security concerns. Therefore, eContact allow you to update birthday year, month and day independently.

SYCONTCT_BIRTH_MON

2

Integer

 

See SYCONTCT_BIRTH_YEAR

SYCONTCT_BIRTH_DAY

2

Integer

 

See SYCONTCT_BIRTH_YEAR

SYCONTCT_CREATED_BY

10

String

Y

Default to “ELIECONT.” We suggest you to pass a valid Elliott user ID.

 

AddContactResult Structure

Property Name

Type

Detail

ReturnCode

Integer

Zero means OK; for other return codes, please see “EliecontService Return Code” section.

ReturnMsg

String

This is description of return code. For example, if return code is zero, you can expect “OK” in this field.

SYCONTCT_ID

Integer

This is the sequentially assigned contact ID for the newly added contact.

 

Code Example (VB)

The following sample code will add a contact “abc123@gmail.com” for customer “000001.” The address, phones, and faxes of the contact will link to customer “000001.”

 

Dim Service As New webServicesecont.EliecontService

Dim Result As New webServicesecont.AddContactResult

Dim Input As New webServicesecont.AddContactInput

Input.SYCONREL_DETAIL_FILE = “ARCUSFIL”

Input.SYCONREL_REF_ID = “000001”

Input.SYCONTCT_EMAIL_ADDR = “abc123@gmail.com”

Input.SYCONTCT_NAME = “John Smith”

Result = Service.AddContact(“”, “”, Input)

If Result.ReturnCode = 0 Then

  lblResult.Text = “Contact ” & Result.SYCONTCT_ID _

                  & “ Added.”

Else

  lblResult.Text = Result.ReturnMsg

  lblErrorCode.Text = Result.ReturnCode.ToString

End If

 

AddRelationship

This method is used to add one relationship for an existing contact. Using AddContact for an email address that already exists will result in an error. Therefore, use the ViewContact method to determine whether you should use AddConact, AddRelationship, or ask the user to login with the Login method.

A relationship record has a primary key of detail file + reference id + contact id. You must provide detail file and reference id. For contact id, you can either provide it, or pass an email address and let the system find the corresponding contact id. If you provide both contact id and email address, the system will ignore the email address you provided.

When you add a relationship to an existing contact, the system does not allow this relationship to be the primary contact. If you wish to make this relationship the primary contact, you will need to use the ChangeContact method.

Usage:

AddRelationshipResult = A.AddRelationship(UserName, UserPassword, SYCONREL_DETAIL_FILE, SYCONREL_REF_ID, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, SYCONREL_ROLE)

Parameters UserName and UserPassword are not used at this moment.

 

Input Parameters

Parameter

Length

Type

Upper

Detail

SYCONREL_DETAIL_FILE

8

String

Y

Required.

SYCONREL_REF_ID

30

String

Y

Required.

SYCONTCT_ID

9

Integer

 

Required if SYCONTCT_EMAIL_ADDR is not provided.

SYCONTCT_EMAIL_ADDR

60

String

 

Required if SYCONTCT_ID is not provided. If SYCONTCT_ID is provided, this field will be ignored.

SYCONREL_ROLE

15

String

Y

This will be validated with SYCONROL table. It is used for security control. If you are not sure, leave it blank.

 

Output Parameter

Parameter

Type

Detail

AddRelationshipResult

Integer

Contains return code.

Zero means OK; for other return codes, please see “EliecontService Return Code” section for detail.

 

Code Example (VB)

The following sample code assumes contact abc123@gmail.com already exists (probably through ViewContact or Login method). It will add a relationship for this contact to link to customer “000002.”

 

Dim Service As New webServicesecont.EliecontService

Dim AddRelationshipResult As Integer = 0

Dim SYCONREL_DETAIL_FILE As String = “ARCUSFIL”

Dim SYCONREL_REF_ID As String = “000002”

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

AddRelationshipResult = Service.AddRelationship(“”, “”,SYCONREL_DETAIL_FILE, SYCONREL_REF_ID, 0, SYCONTCT_EMAIL_ADDR, “”)

If AddRelationshipResult = 0 Then

  lblResult.Text = “Relationship Added.”

Else

  lblResult.Text = AddRelationshipResult.ToString

End If

 

ChangeContact

This method is used to change a contact or relationship. This method uses Contact ID as the key to get the contact, so that you can change contact email. If you change a contact’s email, the new email address must be unique since it is a unique key.

Please note that this method does not provide a way to clear a field. For example, if you passed blank value to a string field, the system assumes you did not pass a value, and therefore assumes you do not wish to change the field’s value. It is important to know that this method does not differentiate blank or zero from null value.

Usage:

ChangeContactResult = A.ChangeContact(UserName, UserPassword, ChangeContactInput)

Parameters UserName and UserPassword are not used at this moment.

 

ChangeContactInput Structure

Property

Length

Type

Upper

Detail

SYCONTCT_ACCEPT_HTML

1

String

Y

See “AddContactInput Structure”

SYCONTCT_BLK_ACCESS

1

String

Y

See “AddContactInput Structure”

SYCONTCT_BLK_ACCS_DT

8

Date

 

See “AddContactInput Structure”

SYCONTCT_BLK_REASON

30

String

Y

See “AddContactInput Structure”

SYCONTCT_BLK_EMAIL

1

String

Y

See “AddContactInput Structure”

SYCONTCT_BLK_EM_DT

8

Date

 

See “AddContactInput Structure”

SYCONTCT_ADDR_1

30

String

 

Address 1 and 2 work as a group. For more detail of this field, please refer to “AddContactInput Structure.”

SYCONTCT_ADDR_2

30

String

 

See SYCONTCT_ADDR_1.

SYCONTCT_CITY

15

String

 

See “AddContactInput Structure”

SYCONTCT_COUNTRY

20

String

 

See “AddContactInput Structure”

SYCONTCT_FAX

12

String

Y

See “AddContactInput Structure”

SYCONTCT_ID

9

Integer

 

Required. For more detail of this field, please refer to “AddContactInput Structure.”

SYCONTCT_NAME

30

String

 

See “AddContactInput Structure”

SYCONTCT_PASSWD

12

String

 

See “AddContactInput Structure”

SYCONTCT_PASSWD_HINT

20

String

Y

See “AddContactInput Structure”

SYCONTCT_PASSWD_HT_V

20

String

Y

See “AddContactInput Structure”

SYCONTCT_PHONE

12

String

Y

See “AddContactInput Structure”

SYCONTCT_PHONE_EXT

5

String

 

See “AddContactInput Structure”

SYCONTCT_STATE

2

String

 

See “AddContactInput Structure”

SYCONTCT_ZIP

10

String

Y

See “AddContactInput Structure”

SYCONTCT_CREATE_DT

8

Date

 

Not used. Create date is not changeable.

SYCONTCT_CREATE_TIME

6

Float

 

Not used. Create time is not changeable.

SYCONREL_DETAIL_FILE

8

String

Y

If you need to change fields in the relationship table, the value of SYCONREL_REF_ID and SYCONREL_DETAIL_FILE must be provided.

Only “role” and “position” fields of a relationship are changeable in this method.

SYCONTCT_EMAIL_ADDR

60

String

 

See “AddContactInput Structure”

SYCONTCT_HOME_PHONE

12

String

Y

See “AddContactInput Structure”

SYCONTCT_LNK_ADR_FLG

1

String

Y

See “AddContactInput Structure”

SYCONTCT_LNK_FAX_FLG

1

String

Y

See “AddContactInput Structure”

SYCONTCT_LNK_TEL_FLG

1

String

Y

See “AddContactInput Structure”

SYCONTCT_MOBIL_PHONE

20

String

Y

See “AddContactInput Structure”

SYCONTCT_BOUNCEBACKS

4

Float

 

See “AddContactInput Structure”

SYCONREL_PRIMARY_REL

1

String

Y

Not used. To change to primary relationship, you will need to use Elliott user interface.

SYCONREL_REF_ID

30

String

Y

See “SYCONREL_DETAIL_FILE”

SYCONREL_ROLE

15

String

Y

See “AddContactInput Structure”

SYCONREL_POSITION

15

String

Y

See “AddContactInput Structure”

SYCONREL_PRIMARY_CT

1

String

Y

Not used. To change to primary contact, you will need to use Elliott user interface.

SYCONTCT_COMPANY_NA

30

String

 

See “AddContactInput Structure”

SYCONTCT_BIRTH_YEAR

4

Integer

 

See “AddContactInput Structure”

SYCONTCT_BIRTH_MON

2

Integer

 

See “AddContactInput Structure”

SYCONTCT_BIRTH_DAY

2

Integer

 

See “AddContactInput Structure”

SYCONTCT_CREATED_BY

10

String

Y

SYCONTCT_CREATED_BY serves as both created or modify by. You may pass a valid Elliott user ID to indicate the last user who changed this contact.

 

Output Parameter

Parameter

Type

Detail

ChangeContactResult

Integer

Contains return code.

Zero means OK; for other return codes, please see “EliecontService Return Code” section for detail.

 

Code Example (VB)

The following sample code will change a contact’s email address and password.

 

Dim Service As New webServicesecont.EliecontService

Dim ChangeContactResult As Integer = 0

Dim Input As New webServicesecont.ChangeContactInput

Input.SYCONTCT_ID = 10123

Input.SYCONTCT_EMAIL_ADDR = “123abc@gmail.com”

Input.SYCONTCT_PASSWD = “aBC1TWOthre”

ChangeContactResult = Service.ChangeContact(“”, “”, Input)

If ChangeContactResult = 0 Then

  lblResult.Text = “Contact Information Updated.”

Else

  lblResult.Text = “Error code ” & ChangeContactResult.ToString

End If

 

 

DeleteContact

This method is used to delete a contact and all associated relationships. If that is not what you want, you may want to look at DeleteRelationship method.

User must provide either email address or contact id. If both of them are provided, system will use contact id to find corresponding contact.

Usage:

DeleteContactResult = A.DeleteContact(UserName, UserPassword, SYCONTCT_ID, SYCONTCT_EMAIL)

Parameters UserName and UserPassword are not used at this moment.

 

DeleteContact Parameters

Parameter

Length

Type

Detail

SYCONTCT_ID

9

Integer

Required if SYCONTCT_EMAIL_ADDR is not provided.

SYCONTCT_EMAIL

60

String

Required if SYCONTCT_ID is not provided. If SYCONTCT_ID is provided, this field will be ignored.

 

Output Parameter

Parameter

Type

Detail

DeleteContactResult

Integer

Contains return code.

Zero means OK; for other return codes, please see “EliecontService Return Code” section for detail.

 

Code Example (VB)

The following sample code will delete the contact “abc123@gmail.com” and all associated relationships.

 

Dim Service As New webServicesecont.EliecontService

Dim ChangeContactResult As Integer = 0

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

ChangeContactResult = Service.ChangeContact(“”, “”, Input)

If ChangeContactResult = 0 Then

  lblResult.Text = “Contact Deleted.”

Else

  lblResult.Text = ChangeContactResult.ToString

End If

 

 

DeleteRelationship

This method is used to delete one relationship of the contact. When the last relationship of a contact is deleted, the contact will be deleted too. If you wish to delete the contact and all associated relationships, use DeleteContact method instead.

If you deleted a primary relationship, this method will automatically assign an existing relationship as primary.

Usage:

DeleteRelationshipResult = A.DeleteRelationship(UserName, UserPassword, SYCONREL_DETAIL_FILE, SYCONREL_REF_ID, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR)

Parameters UserName and UserPassword are not used at this moment.

 

DeleteRelationship Parameters

Parameter

Length

Type

Upper

Detail

SYCONREL_DETAIL_FILE

8

String

Y

Required.

SYCONREL_REF_ID

30

String

Y

Required.

SYCONTCT_ID

9

Integer

 

Required if SYCONTCT_EMAIL_ADDR is not provided.

SYCONTCT_EMAIL_ADDR

60

String

 

Required if SYCONTCT_ID is not provided. If SYCONTCT_ID is provided, this field will be ignored.

 

Output Parameter

Parameter

Type

Detail

DeleteRelationshipResult

Integer

Contains return code.

Zero means OK; for other return codes, please see “EliecontService Return Code” section for detail.

 

Code Example (VB)

The following sample code will delete the relationship for customer “000002” and email address “abc123@gmail.com”.

 

Dim Service As New webServicesecont.EliecontService

Dim DeleteRelationshipResult As Integer = 0

Dim SYCONREL_DETAIL_FILE As String = “ARCUSFIL”

Dim SYCONREL_REF_ID As String = “000002”

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

DeleteRelationshipResult = Service.DeleteRelationship ("", "", SYCONREL_DETAIL_FILE, SYCONREL_REF_ID, Nothing, SYCONTCT_EMAIL_ADDR)

If DeleteRelationshipResult = 0 Then

  lblResult.Text = “Relationship Deleted.”

Else

  lblResult.Text = DeleteRelationshipResult.ToString

End If

 

ViewContact

This method will return one contact’s information and related relationships. It is likely you will have multiple relationships for an eContact. It is common practice for Elliott or website to add the order contacts (relationship) to CPORDHDR table. You may not be interested in seeing contact relationship for the sales order or invoice history (CPINVHDR). Therefore, this method by default skips transactional files’ (e.g. CPORDHDR, CPINVHDR) relationship.

Usage:

ViewContactResult = A.ViewContact(UserName, UserPassword, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, IncludeDescFlag, FileView, ExcludeInclude)

Parameters UserName and UserPassword are not used at this moment.

ViewContact Parameters

If “FileView” and “ExcludeInclude” are both blank, this method will assign a default values to them. The default value of “ExcludeInclude” is “I” (include), and “FileView” is “ARCUSFILAPVENFILARSLMFILCPSHPFILEMPFILE”, which means to look for contact relationships in customer file, vendor file, salesman file, ship-to file, and employee file. By default, all contact relationships in the transactional files will be skipped.

 

Parameter

Length

Type

Upper

Detail

SYCONTCT_ID

9

Integer

 

Required if SYCONTCT_EMAIL_ADDR is not provided.

SYCONTCT_EMAIL_ADDR

60

String

 

Required if SYCONTCT_ID is not provided. If SYCONTCT_ID is provided, this field will be ignored.

IncludeDescFlag

1

String

Y

“Y”: Return relationship description to RelationshipDescRecord like “Customer” or “Ship To”, also return RelationshipMiscInfoRecord. On your website, it may not be user friendly to display the relationship as “ARCUSFIL” or “CPSHPFIL”.

“N” (Default): Do not return relationship description.

FileView

80

String

Y

This is used with “ExcludeInclude” parameter to indicate files to be excluded or included.

This field will be parsed as ten 8-digit strings. For example, if you only want to include contacts from ship-to file and customer file, you should set FileView as “CPSHPFILARCUSFIL”, and ExcludeInclude as “I”. This is a typical eCommerce implementation since you are not interested in the Vendor (APVENFIL), sales order (CPORDHDR) or any other relationships in that scenario.

ExcludeInclude

1

String

Y

If this field and FileView are both blank, the value of this field will be “I”.

“E”: Exclude files in FileView.

“I”: Include files in FileView.

Blank: Include all files. The value in FileView will not be used.

 

ViewContactResult Structure

Property Name

Type

Detail

ReturnCode

Integer

Zero means OK; for other return codes, please see “EliecontService Return Code” section.

ReturnMsg

String

This is description of return code. For example, if return code is zero, you can expect “OK” in this field.

ContactRelationshipRecord()

ContactRelationshipRecord

Contains up to 50 relationship records.

RelationshipDescRecord()

RelationshipDescRecord

Contains up to 50 relationship descriptions.

RelationshipMiscInfoRecord()

RelationshipMiscInfoRecord

This contains contact relationship’s address, phone number, and fax number from the master file like ARCUSFIL. Contains up to 50 records.

SYCONTCT_ACCEPT_HTML

String

See “AddContactInput Structure”.

SYCONTCT_BLK_ACCESS

String

See “AddContactInput Structure”.

SYCONTCT_BLK_ACCS_DT

Date

See “AddContactInput Structure”.

SYCONTCT_BLK_REASON

String

See “AddContactInput Structure”.

SYCONTCT_BLK_EMAIL

String

See “AddContactInput Structure”.

SYCONTCT_BLK_EM_DT

Date

See “AddContactInput Structure”.

SYCONTCT_ADDR_1

String

See “AddContactInput Structure”.

SYCONTCT_ADDR_2

String

See “AddContactInput Structure”.

SYCONTCT_CITY

String

See “AddContactInput Structure”.

SYCONTCT_COUNTRY

String

See “AddContactInput Structure”.

SYCONTCT_FAX

String

See “AddContactInput Structure”.

SYCONTCT_ID

Integer

See “AddContactInput Structure”.

SYCONTCT_NAME

String

See “AddContactInput Structure”.

SYCONTCT_PASSWD

String

See “AddContactInput Structure”.

SYCONTCT_PASSWD_HINT

String

See “AddContactInput Structure”.

SYCONTCT_PASSWD_HT_V

String

See “AddContactInput Structure”.

SYCONTCT_PHONE

String

See “AddContactInput Structure”.

SYCONTCT_PHONE_EXT

String

See “AddContactInput Structure”.

SYCONTCT_STATE

String

See “AddContactInput Structure”.

SYCONTCT_ZIP

String

See “AddContactInput Structure”.

SYCONTCT_CREATE_DT

Date

See “AddContactInput Structure”.

SYCONTCT_CREATE_TIME

Float

See “AddContactInput Structure”.

SYCONTCT_EMAIL_ADDR

String

See “AddContactInput Structure”.

SYCONTCT_HOME_PHONE

String

See “AddContactInput Structure”.

SYCONTCT_LNK_ADR_FLG

String

See “AddContactInput Structure”.

SYCONTCT_LNK_FAX_FLG

String

See “AddContactInput Structure”.

SYCONTCT_LNK_TEL_FLG

String

See “AddContactInput Structure”.

SYCONTCT_MOBIL_PHONE

String

See “AddContactInput Structure”.

SYCONTCT_BOUNCEBACKS

Float

See “AddContactInput Structure”.

SYCONTCT_COMPANY_NA

String

See “AddContactInput Structure”.

SYCONTCT_BIRTH_YEAR

Integer

See “AddContactInput Structure”.

SYCONTCT_BIRTH_MON

Integer

See “AddContactInput Structure”.

SYCONTCT_BIRTH_DAY

Integer

See “AddContactInput Structure”.

SYCONTCT_CREATED_BY

String

See “AddContactInput Structure”.

 

ContactRelationshipRecord Structure

Property Name

Type

Detail

SYCONREL_DETAIL_FILE

String

See “AddContactInput Structure”.

SYCONREL_REF_ID

String

See “AddContactInput Structure”.

SYCONREL_ROLE

String

See “AddContactInput Structure”.

SYCONROL_PRIME_I_FLG

String

Access permission for primary files inquire.

SYCONROL_PRIME_C_FLG

String

Access permission for primary files change.

SYCONROL_SUB_I_FLG

String

Access permission for subordinate files inquire.

SYCONROL_SUB_A_FLG

String

Access permission for subordinate files add.

SYCONROL_SUB_C_FLG

String

Access permission for subordinate files change.

SYCONROL_SUB_D_FLG

String

Access permission for subordinate files delete.

SYCONROL_TRX_I_FLG

String

Access permission for transaction files inquire.

SYCONROL_TRX_A_FLG

String

Access permission for transaction files add.

SYCONROL_TRX_C_FLG

String

Access permission for transaction files change.

SYCONROL_TRX_D_FLG

String

Access permission for transaction files delete.

SYCONREL_PRIMARY_REL

String

See “AddContactInput Structure”.

SYCONREL_POSITION

String

See “AddContactInput Structure”.

SYCONREL_PRIMARY_CT

String

See “AddContactInput Structure”.

SYCONREL_TERMINATE_D

String

Date contact relationship was terminated.

SYCONREL_SHP_CONF_FL

String

Flag to specify if contact will receive shipping confirmation emails.

SYCONREL_CPINVPRT_EM

String

Flag to specify if contact will receive invoice emails through the PDF PostOffice.

SYCONREL_POINVPRT_EM

String

Flag to specify if contact will receive purchase order emails through the PDF PostOffice.

SYCONREL_ARSTMNTS_EM

String

Flag to determine if contact will receive A/R statement emails through the PDF PostOffice.

SYCONREL_CPORDPRT_EM

String

Flag to specify if contact will receive order acknowledgement emails through the PDF PostOffice.

SYCONREL_CPQUOPRT_EM

String

Flag to specify if contact will receive order quote emails through the PDF PostOffice.

SYCONREL_CPRMAPRT_EM

String

Flag to specify if contact will receive RMA acknowledgement emails through the PDF PostOffice.

SYCONREL_FAX_PDF_DOC

String

Flag to specify if contact can receive faxes of PDF PostOffice documents.

SYCONREL_ALL_PAY_ACH

String

Flag to specify if contact is allowed to pay using ACH.

 

RelationshipDescRecord Structure

Property Name

Type

Detail

RelationshipDesc

String

Description of the relationship.

 

RelationshipMiscInfoRecord Structure

Property Name

Type

Detail

CUS_STREET1

String

Street 1 of the relationship.

CUS_STREET2

String

Street 2 of the relationship.

CUS_CITY

String

City of the relationship.

CUS_ST

String

State of the relationship.

CUS_ZIP

String

Zip Code of the relationship.

CUS_COUNTRY

String

Country of the relationship.

CUS_PHONE_NO

String

Phone number of the relationship.

CUS_FAX_NUMBER

String

Fax number of the relationship.

CUS_CR_HOLD_FG

String

Credit hold of the relationship. You may use this flag to decide whether to let your customer contact login or not.

CUS_TP

String

Customer type of the relationship.

Reserved

String

Reserved filed of the relationship. Usually this is empty.

 

Code Example (VB)

The following sample code will return contact’s information and related relationships in Customer and Ship-To for contact “abc123@gmail.com”.

 

Dim Service As New webServicesecont.EliecontService

Dim Result As New webServicesecont.ViewContactResult

Dim SYCONTCT_ID As String

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

Dim IncludeDescFlag As String = “Y”

Dim FileView As String = “ARCUSFILCPSHPFIL”

Dim ExcludeInclude As String = “I”

Result = Service.ViewContact(“”, “”, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, IncludeDescFlag, FileView, ExcludeInclude)

If Result.ReturnCode = 0 Then

  lblResult.Text = “Contact Name is ” & Result.SYCONTCT_NAME _

                  & “ Phone No. ” & Result.SYCONTCT_PHONE

Else

  lblResult.Text = Result.ReturnMsg

  lblErrorCode.Text = Result.ReturnCode.ToString

End If

 

ViewRelationship

This method will return one relationship record. This method is obsolete and you can use ViewContact method to get the same kind of information.

Usage:

ViewRelationshipResult = A.ViewRelationship(UserName, UserPassword, SYCONREL_DETAIL_FILE, SYCONREL_REF_ID, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR)

Parameters UserName and UserPassword are not used at this moment.

 

ViewRelationship Parameters

Parameter

Length

Type

Upper

Detail

SYCONREL_DETAIL_FILE

8

String

Y

Required.

SYCONREL_REF_ID

30

String

Y

Required.

SYCONTCT_ID

9

Integer

 

Required if SYCONTCT_EMAIL_ADDR is not provided.

SYCONTCT_EMAIL_ADDR

60

String

 

Required if SYCONTCT_ID is not provided. If SYCONTCT_ID is provided, this field will be ignored.

 

ViewRelationshipResult Structure

Property Name

Type

Detail

ReturnCode

Integer

Zero means OK; for other return codes, please see “EliecontService Return Code” section.

ReturnMsg

String

This is description of return code. For example, if return code is zero, you can expect “OK” in this field.

ContactRelationshipRecord

ContactRelationshipRecord

Please see “ContactRelationshipRecord Structure” in ViewContact method for detail.

 

Code Example (VB)

The following sample code will return the relationship information of contact “abc123@gmail.com” for customer “000001”.

 

Dim Service As New webServicesecont.EliecontService

Dim Result As New webServicesecont.ViewRelationshipResult

Dim SYCONREL_DETAIL_FILE As String = “ARCUSFIL”

Dim SYCONREL_REF_ID As String = “000001”

Dim SYCONTCT_ID As String

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

Result = Service.ViewRelationship(“”, “”, SYCONREL_DETAIL_FILE, SYCONREL_REF_ID, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR)

If Result.ReturnCode = 0 Then

  lblResult.Text = “This Contact has the role of ” _

      & Result.ContactRelationshipRecord.SYCONREL_ROLE

Else

  lblResult.Text = Result.ReturnMsg

  lblErrorCode.Text = Result.ReturnCode.ToString

End If

 

ViewAllContact

This method returns all contacts related to a file and reference id. For example, you can get a list of all contacts for customer# 000001.

Usage:

ViewRelationshipResult = A.ViewAllContact(UserName, UserPassword, SYCONREL_DETAIL_FILE, SYCONREL_REF_ID)

Parameters UserName and UserPassword are not used at this moment.

 

ViewAllContact Parameters

Parameter

Length

Type

Upper

Detail

SYCONREL_DETAIL_FILE

8

String

Y

Required.

SYCONREL_REF_ID

30

String

Y

Required.

 

ViewAllContactResult Structure

Property Name

Type

Detail

ReturnCode

Integer

Zero means OK; for other return codes, please see “EliecontService Return Code” section.

ReturnMsg

String

This is description of return code. For example, if return code is zero, you can expect “OK” in this field.

AllContactRecord()

AllContactRecord

Contains up to 50 contact records. Please see “AllContactRecord Structure” for detail.

 

AllContactRecord Structure

Property Name

Type

Detail

SYCONTCT_ID

Integer

Contact ID.

SYCONTCT_NAME

String

Contact name.

SYCONREL_POSITION

String

Contact position.

SYCONTCT_EMAIL_ADDR

String

Contact email address.

 

Code Example (VB)

The following sample code will return all contacts related to customer “000001”.

 

Dim Service As New webServicesecont.EliecontService

Dim Result As New webServicesecont.ViewAllContactResult

Dim SYCONREL_DETAIL_FILE As String = “ARCUSFIL”

Dim SYCONREL_REF_ID As String = “000001”

Result = Service.ViewAllContact(“”, “”, SYCONREL_DETAIL_FILE, SYCONREL_REF_ID)

If Result.ReturnCode = 0 Then

  lblResult.Text = “First Conatact Name is ” _

      & Result.AllContactRecord(0).SYCONTCT_NAME _

      & “ Position ” & Result.AllContactRecord(0).SYCONREL_POSITION

Else

  lblResult.Text = Result.ReturnMsg

  lblErrorCode.Text = Result.ReturnCode.ToString

End If

 

Login

This method will authenticate a contact’s password. Upon successful authentication, it adds a record to the activity log SYACTLOG table to indicate this login activity. Then it returns the contact and relationships information.

Usage:

LoginResult = A.Login(UserName, UserPassword, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, IncludeDescFlag, FileView, ExcludeInclude, CheckPassword, LogType, Source, Client, Comment)

Parameters UserName and UserPassword are not used at this moment.

 

Login Parameters

Parameter

Length

Type

Upper

Detail

SYCONTCT_ID

9

Integer

 

Required if SYCONTCT_EMAIL_ADDR is not provided.

SYCONTCT_EMAIL_ADDR

60

String

 

Required if SYCONTCT_ID is not provided. If SYCONTCT_ID is provided, this field will be ignored.

IncludeDescFlag

1

String

Y

See “ViewContact Parameters” in ViewContact method.

FileView

80

String

Y

See “ViewContact Parameters” in ViewContact method.

ExcludeInclude

1

String

Y

See “ViewContact Parameters” in ViewContact method.

CheckPassword

12

String

 

Required. This is the password of the contact. If the value does not match, an error code is returned. If your intention is not “login”, then you should use ViewContact method.

LogType

30

String

 

This is a free form field to be written to Activity log SYACTLOG table.

Source

30

String

 

This is a free form field to be written to Activity log SYACTLOG table. We suggest you to pass the web application URL like www.elliott.com for auditing purpose.

Client

32

String

 

This is a free form field to be written to Activity log SYACTLOG table. We suggest you to pass the browser IP address for auditing purpose.

Comment

60

String

 

This is a free form field to be written to Activity log SYACTLOG table.

 

LoginResult Structure

This structure is the same as ViewContactResult structure in ViewContact method. Please refer to ViewContactResult structure for the structure’s property details.

Property Name

Type

Detail

ReturnCode

Integer

Zero means OK; for other return codes, please see “EliecontService Return Code” section.

ReturnMsg

String

This is description of return code. For example, if return code is zero, you can expect “OK” in this field.

ContactRelationshipRecord()

ContactRelationshipRecord

Contains up to 50 records. Please refer to "ContactRelationshipRecord Structure" in ViewContact method for its structure.

RelationshipDescRecord()

RelationshipDescRecord

Contains up to 50 records. Please refer to "RelationshipDescRecord Structure" in ViewContact method for its structure.

RelationshipMiscInfoRecord()

RelationshipMiscInfoRecord

Contains up to 50 records. Please refer to "RelationshipMiscInfoRecord Structure" in ViewContact method for its structure.

SYCONTCT_ACCEPT_HTML

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BLK_ACCESS

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BLK_ACCS_DT

Date

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BLK_REASON

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BLK_EMAIL

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BLK_EM_DT

Date

See “AddContactInput Structure” in AddContact method.

SYCONTCT_ADDR_1

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_ADDR_2

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_CITY

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_COUNTRY

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_FAX

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_ID

Integer

See “AddContactInput Structure” in AddContact method.

SYCONTCT_NAME

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_PASSWD

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_PASSWD_HINT

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_PASSWD_HT_V

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_PHONE

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_PHONE_EXT

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_STATE

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_ZIP

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_CREATE_DT

Date

See “AddContactInput Structure” in AddContact method.

SYCONTCT_CREATE_TIME

Float

See “AddContactInput Structure” in AddContact method.

SYCONTCT_EMAIL_ADDR

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_HOME_PHONE

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_LNK_ADR_FLG

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_LNK_FAX_FLG

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_LNK_TEL_FLG

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_MOBIL_PHONE

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BOUNCEBACKS

Float

See “AddContactInput Structure” in AddContact method.

SYCONTCT_COMPANY_NA

String

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BIRTH_YEAR

Integer

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BIRTH_MON

Integer

See “AddContactInput Structure” in AddContact method.

SYCONTCT_BIRTH_DAY

Integer

See “AddContactInput Structure” in AddContact method.

SYCONTCT_CREATED_BY

String

See “AddContactInput Structure” in AddContact method.

 

Code Example (VB)

The following sample code will authenticate and write a login activity log for contact “abc123@gmail.com”, then return that contact’s information and relationships in customer and ship-to file.

 

Dim Service As New webServicesecont.EliecontService

Dim Result As New webServicesecont.LoginResult

Dim SYCONTCT_ID As String = “”

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

Dim IncludeDescFlag As String = “Y”

Dim FileView As String = “ARCUSFILCPSHPFIL”

Dim ExcludeInclude As String = “I”

Dim CheckPassword As String = “aBcOne2Thre”

Dim LogType As String = “”

Dim Source As String = “estore.elliott.com”

Dim Client As String = “65.212.154.1”

Dim Comment As String = “”

Result = Service.Login(“”, “”, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, IncludeDescFlag, FileView, ExcludeInclude, CheckPassword, LogType, Source, Client, Comment)

If Result.ReturnCode = 0 T1hen

  lblResult.Text = “Log-in Successfully”

Else

  lblResult.Text = Result.ReturnMsg

  lblErrorCode.Text = Result.ReturnCode.ToString

End If

 

Logout

This method will create an activity log record for logout activity to database table SYACTLOG.

Usage:

LogoutResult = A.Logout(UserName, UserPassword, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, LogType, Source, Client, Comment)

Parameters UserName and UserPassword are not used at this moment.

 

Logout Parameters

Parameter

Length

Type

Detail

SYCONTCT_ID

9

Integer

User must provide either email address or contact id. If both of them are provided, system will use contact id to find corresponding contact.

SYCONTCT_EMAIL_ADDR

60

String

User must provide either email address or contact id. If both of them are provided, system will use contact id to find corresponding contact.

LogType

30

String

This is a free form field to be written to Activity log SYACTLOG table.

Source

30

String

This is a free form field to be written to Activity log SYACTLOG table. We suggest you to pass the web application URL like www.elliott.com for auditing purpose.

Client

32

String

This is a free form field to be written to Activity log SYACTLOG table. We suggest you to pass the browser IP address for auditing purpose.

Comment

60

String

This is a free form field to be written to Activity log SYACTLOG table.

 

Output Parameter

Parameter

Type

Detail

LogoutResult

Integer

Contains return code. Zero means OK; for other return codes, please see “EliecontService Return Code” section.

 

Code Example (VB)

The following sample code will write a logout activity log for contact “abc123@gmail.com”.

 

Dim Service As New webServicesecont.EliecontService

Dim Result As Integer

Dim SYCONTCT_ID As String = “”

Dim SYCONTCT_EMAIL_ADDR As String = “abc123@gmail.com”

Dim LogType As String = “”

Dim Source As String = “estore.elliott.com”

Dim Client As String = “65.212.154.1”

Dim Comment As String = “”

Result = Service.Logout(“”, “”, SYCONTCT_ID, SYCONTCT_EMAIL_ADDR, LogType, Source, Client, Comment)

If Result = 0 Then

  lblResult.Text = “Log-out Successfully”

Else

  lblResult.Text = Result.ToString

End If

 

EliecontService Return Code

 0 = OK

 1 = File Error

 2 = E-mail Address Missing (Add Contact)

 3 = Detail File & Ref No Missing (Add Contact/Relationship) (Delete Relationship) (View Relationship) (View All Contact)

 4 = E-mail Address or Contact ID Missing (Add Relationship) (Delete Contact/Relationship) (Delete Relationship)(View Contact) (View Relationship)

 5 = Contact Record Not Found (Add Relationship/Change Contact) (Delete Contact/Relationship) (Delete Relationship)(View Contact) (View Relationship)

 6 = Contact Record Already Existed (Add Contact)

 7 = Contact Role Not On File (Add Contact & Relationship)

 8 = NSI Control File Not Found (Add Contact)

 9 = Contact Name is Required (Add/Change Contact)

10 = Link Address Flag Invalid (Add/Change Contact)

11 = Link Phone Flag Invalid (Add/Change Contact)

12 = Link Fax Flag Invalid (Add/Change Contact)

13 = Block Access Flag Invalid (Add/Change Contact)

14 = Block E-mail Flag Invalid (Add/Change Contact)

15 = Credit Card Exp Year/Month Required (Add/Change Contact)

16 = Credit Card No/Exp Invalid (Add/Change Contact)

17 = Credit Card Name Required (Add/Change Contact)

18 = Credit Card Same Address Flag Invalid (Add/Change Contact)

19 = Accept HTML Flag Invalid (Add/Change Contact)

20 = Contact ID Not Provided (Change Contact)

21 = Use Primary Address Flag Turn On, But Address Info. Change (Change Contact)

22 = Use Primary Phone Flag Turn On, But Phone Change. (Change Contact)

23 = Use Primary Fax Flag Turn On, But Fax Change. (Change Contact)

24 = Use Same Credit Address, But Address Info Change (Change) (Change Contact)

25 = No Relationship Found (View Contact)

26 = More Than 50 Relationship Found (View Contact)

27 = Invalid Exclude/Include Value (Spaces,"E","I") (View Contact)

28 = No Contact Found (View All Contact)

29 = More Than 50 Contacts Found (View All Contact)

30 = Birth Year Must Greater Than 1900 or Leave Blank

31 = Birth Month Must Less or Equal Than 12

32 = Birth Day Must Less or Equal Than 31

33 = Password Failed

34 = Duplicate E-mail (Change Contact)

35 = Detail File / Ref No Not Found (Add/Update Contact) 

CLS

Feedback and Knowledge Base