Technical interconnection solution v1.1
Last updated 2023/08/16  

I. Overview

1. Site access mode

You can add the "Help Center" link in the following location, click to enter the Help Center home page:

  1. Official website navigation

  2. In-product (web version, H5 version) navigation

2. Content and method of data access

Magic Voice Help Center does not manage the user information of your system, and the management work such as adding, deleting and changing users is completed in your own system, but Magic Voice provides data analysis function based on user ID and customer ID, you can query the user's access to the help center by user ID and customer ID:

  • The user ID, or visitorId, refers to the ID of the visitor himself

  • Customer ID (accountId) refers to the ID of the organization to which the visitor belongs. When the user visits the page of the Help Center, you need to tell us these two data, see the details in Part 2. Of course, you can choose not to access these two parameters, so that we cannot use our data analysis function

3. Data security guarantee

Magic Voice does not record, does not store other user information except ID, there is no need to worry about data leakage.

2. Technology docking plan

(1) Domain name interconnection

1. Use a custom domain name (recommended ☆☆☆)

For example, your official website domain name is www.xxx.com, then the help center can use doc.xxx.com, access method is:

  1. Magic Voice will assign you a domain name: xxx.dochelp.cn

  2. You add a cname resolution record to the xxx.com domain name administration, which is usually done by the domain administrator:

  • Record type: cname

  • Host record: doc.xxx.com

  • Record value: xxx.dochelp.cn

  1. System verification, after the verification can be used

Attention:

  • The use of cname requires the doc.xxx.com certificate to be hosted on the magic sound server, otherwise https access will be limited, and your domain name needs to be recorded on Alibaba Cloud (if not, The reference https://help.aliyun.com/knowledge_detail/36924.html

    )

  • If you do not use the cname method, an alternative is to use nginx to forward the request directly internally to xxx.dochelp.cn, with your operations staff operating the internal redirection directly

2. Use the domain name provided by the magic voice

1. You can use the magic voice name directly. For example, if your official website domain name is www.xxx.com, you can use xxx.dochelp.cn without any configuration

2. You can customize the domain name prefix.

3. Use your existing domain name + secondary directory

For example, if your existing domain name is xxx.com, you can use xxx.com/helpcenter (or xxx.com/doc) by:

  • To forward the request starting with xxx.com/helpcenter to xxx.dochelp.cn requires operation and maintenance personnel

  • The following is the reference configuration of Nginx:

location /helpcenter/ { proxy_pass http://xxx.dochelp.cn/; proxy_redirect off; proxy_set_header Host $host; proxy_set_header X-Real-IP $remote_addr; proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for; }
1
plaintext

(2) User connection

That is, how to pass the user ID and customer ID of your system into the help Center page, usually in the following three ways:

1. Pass by URL parameter (recommended ☆☆☆)

  • When a user clicks "Help Center" on the official website, you need to concatenate the visitorId and accountId parameters into the help center link.

For example, if the link to the Help Center is https://doc.xxx.com, you need to add two parameters to the link when the user accesses it: https://doc.xxx.com/?visitorId={visitorId}&accountId={acountId}, so that the visitor ID is passed to the Help center

  • You can set whether anonymous access is allowed or not. If anonymous access to the Help Center is not allowed, when the two parameters are not passed, we will redirect the page to the default login page. We need to tell us the URL of the default login page

  • The default login page can jump back to the original page after the login is complete, and the user experience is good

2. Implicit delivery through cookies

You must use a custom domain name, that is, your system domain name (xxx.com) and the help center domain name (doc.xxx.com) belong to the same level 1 domain name (xxx.com), as follows:

  • When you log in to the service system, add visitorId and accountId to the cookie. Cookie. Domain must be set to the level-1 domain name (xxx.com), and cookie.Path must be set to /.

  • If anonymous access to the help center is not allowed, we will redirect the page to the login page when the help center detects that there are no these two cookies or the cookie expires. We need to tell us the URL of the login page, and the login page needs to support the return to the original page after the login is complete

3. Delivery through SSO (Single Sign-on System)

If you have an SSO system, usually the oauth2 protocol, you are required to provide:

  • The SSO interconnection document must clearly describe the implementation principle, interface document, and page hopping process. The following information is usually required:

    1. User authentication URL, when not logged in to jump to this URL, carry the current URL, after the completion of the jump back and carry the code value

    2. An interface or method for exchanging user information with code

  • The SSO interconnection environment usually includes:

    • Assigned account ID and key

    • Test user account and password

    • Can debug the authentication URL

Failed to solve your problem? Please contact us.
Table of Contents

I. Overview

  1. Site access mode
  1. Content and method of data access
  1. Data security guarantee
  1. Technology docking plan

(1) Domain name interconnection

  1. Use a custom domain name (recommended ☆☆☆)
  1. Use the domain name provided by the magic voice
  1. Use your existing domain name + secondary directory

(2) User connection

  1. Pass by URL parameter (recommended ☆☆☆)
  1. Implicit delivery through cookies
  1. Delivery through SSO (Single Sign-on System)