The screens of the programs are currently provided in Korean.

IruHelp manual · v1.0

8. Adding it to your website

This is how customers can choose a support agent and request remote support directly on your company website. Only companies that published the company help page can use it (chapter 4, Management Center settings).

The website only requests a connection. As with a request from the company help page, it connects when the support agent accepts and the customer consents.

Register your website address first

In the Management Center, under 원격 지원 > 기업 지원 페이지 (IruHelp > Company help page), enter your website addresses in 다른 사이트에서 사용 (Use on other sites), one per line, and save. You can register up to 10 addresses. They must start with https and have no path (example: https://www.example.com). During development you can also register addresses such as http://localhost:3000.

The widget (method 1) and the support agent list (method 2) are shown only on registered sites. The public API can also be called from a browser only on registered sites. When you save, code with the page address of your company appears right below; copy and use it.

Method 1. Widget

This is the simplest method. Put the one line below in your website and a "원격 지원" (Remote support) button appears at the bottom right of the screen. When the customer clicks it and chooses a support agent, the connection number, the link to get the remote support program and whether the support agent accepted are shown right there.

<script src="https://iruremote.co.kr/help/widget/v1.js" data-page="page address" async></script>

To show it at a place of your choice in the page instead of the floating button, put the element below at that place. For a website with a dark background, add data-theme="dark" to the script tag. To show the widget in another language, add one of data-lang="en" (English), data-lang="ja" (Japanese) or data-lang="vi" (Vietnamese) to the script tag. Without it, the widget is shown in Korean.

<div data-officeview-help></div>

Method 2. Embedding the support agent list

Instead of the widget, embed the support agent list as an iframe. The list is shown only inside registered sites.

<iframe src="https://iruremote.co.kr/help/page address/embed" title="Remote support" width="480" height="560" style="border:0;max-width:100%"></iframe>

For a website with a dark background, add ?theme=dark to the end of the address. To show the list in another language, put one of /en (English), /ja (Japanese) or /vi (Vietnamese) before /help in the address.

Method 3. Building it yourself with the public API

You build the screen yourself, and the public API handles the support agent list, connection requests, status and cancellation.

  • Base address: https://iruremote.co.kr/api/help/v1/pages/{page address}
  • From a browser it can be called only on registered sites (CORS). Cookies are not used.
  • It must be called from the customer browser. The number of calls and waiting requests is limited per visitor IP address, so if you call through your company server, all customers share one limit.
  • Send the request body as JSON (Content-Type: application/json). Do not add other request headers; they are blocked in the preflight request of the browser.
  • In v1, fields may be added to responses, but existing fields do not change or disappear. Ignore fields you do not know.

Support agent list

GET /api/help/v1/pages/{page address}
FieldMeaning
slugPage address
companyCompany name
logoUrlAddress of the logo image. null if there is no logo
agents[].idIdentifier of the support agent. Send it as it is as the agent value of the connection request
agents[].namePublic name of the support agent set by the company

Of the support agents the company chose to show on the page, the list contains only those who are logged in to the support agent program now and can take more customers.

Connection request

POST /api/help/v1/pages/{page address}/requests
{"agent": "id of the support agent"}
FieldMeaning
tokenToken of this request. Used to check the status and to cancel
codeConnection number (6 digits)
stateStatus of the request (table below)
expiresAtDeadline for the support agent to answer, 3 minutes after the request (ISO 8601, UTC)
company, agentCompany name and public name of the chosen support agent
downloadUrlDownload address of the remote support program. The file name contains the connection number. Show it as a link the customer can click. It can be downloaded only while the status is pending or accepted, and returns 410 after that
pageUrlAddress of the request screen provided by IruREMOTE. Use it to open a new window

Status and cancellation

POST /api/help/v1/pages/{page address}/requests/state   {"token": "..."}
POST /api/help/v1/pages/{page address}/requests/cancel  {"token": "..."}

The response fields are the same as those of the connection request. Check the status every 3 seconds; after connecting, every 10 seconds is enough. Stop when an end status is reached. Cancellation applies only to a request the support agent has not answered yet.

stateMeaning
pendingWaiting for the support agent to accept
acceptedThe support agent accepted. When the customer runs the downloaded program, the consent screen appears
joinedThe remote support program of the customer has connected to the support agent and waits for the customer to consent
connectedConnected
endedThe connection has ended (end status)
declinedThe support agent declined (end status)
expiredThe support agent did not answer by the deadline (end status)
cancelledThe customer cancelled (end status)

Errors

An error response has the form {"code": "...", "message": "..."}. Only 415 does not follow this form.

StatuscodeMeaning
400invalid_body, invalid_agentThe request body is not JSON, or the support agent identifier is wrong
403origin_not_allowedCalled from a site that is not registered (seen as a CORS error in a browser)
404page_not_found, request_not_foundThe page does not exist or is not published, or the token is wrong
409agent_unavailableThe support agent cannot take requests now
409request_openA request from the same IP address is still waiting
415-The Content-Type of the request is not application/json
429too_many_requestsThe call limit was exceeded or the company has too many waiting requests. Try again after the time (in seconds) in the Retry-After header
503unavailableTemporarily unavailable

The call limits per visitor IP address for 15 minutes are 10 connection requests, 600 status checks and 300 list requests. Connection requests and status checks are counted together with those made on the company help page. For the whole company, up to 120 connection requests in 15 minutes and 50 waiting requests at the same time.

Example

const api = 'https://iruremote.co.kr/api/help/v1/pages/page address';
async function call(url, body) {
  const init = body === undefined ? {'} : {
    method: 'POST', headers: {'Content-Type': 'application/json'}, body: JSON.stringify(body)
  };
  const r = await fetch(url, init);
  const json = await r.json();
  if (!r.ok) throw new Error(json.code);   // a code value of the error table
  return json;
}

const page = await call(api);   // show page.agents on the screen
const request = await call(api + '/requests', {agent: page.agents[0].id});
// show request.code, and use request.downloadUrl as the link to get the remote support program
const timer = setInterval(async function () {
  const now = await call(api + '/requests/state', {token: request.token});
  if (['ended', 'declined', 'expired', 'cancelled'].includes(now.state)) clearInterval(timer);
}, 3000);

If your website has a CSP

Add https://iruremote.co.kr to the content security policy (CSP) of your website. For the widget, add it to script-src, style-src, img-src and connect-src; for the support agent list in an iframe, to frame-src. If you use only the public API, add it to connect-src, and to img-src as well if you show the logo.

Notes

  • The token is known only to the customer who made the request. Do not expose it to others or keep it on a server for long.
  • If there is no remote support license, or the company help page is not published, the public API and the support agent list return 404, and the widget shows "지금은 원격 지원 페이지를 열 수 없습니다." (The remote support page cannot be opened now.)
  • If the widget is opened on a site that is not registered, a warning to register the site is printed to the browser console.
  • When you remove a registered address from the list, it stops working on that site immediately (within 10 seconds at the latest).
KakaoTalk inquiry (new window)