0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

LINE WORKS の外部連携ユーザーの UUID の移行方法 (PowerShell)

Last updated at Posted at 2021-10-11

LINE WORKS の 2021 年 9 月 9 日のアップデートで、監査やアーカイブでの LINE ユーザーの表示形式が変更されました。

外部の顧客管理システムなどで LINE WORKS でやり取りしている LINE ユーザーの情報を管理するために、UUID を使っていた場合などに、resourceId へ変更が必要な場合があると思います。

こちらのページの API を使って、UUID を基に resourceId を確認することができます。
TITLE: (旧) 個人アドレス帳の外部ユーザー UUID (worksAtContactNo) の移行
URL: https://developers.worksmobile.com/jp/document/100600207?lang=ja

API の構文は以下のとおりです。

https://apis.worksmobile.com/r/{API_ID}/contact/v3/domains/{domainId}/migration/worksAt/{worksAtContactNo}

PowerShell で実行する例を以下に示します。

Invoke-RestMethod -Uri "https://apis.worksmobile.com/r/<API_ID>/contact/v3/domains/<domain_id>/migration/worksAt/<worksAtContactNo>" -Method Get -Headers @{Authorization = "Bearer <Server_Token>"; consumerKey = "<consumerKey>"} 

次のように、出力されます。

worksAtResourceId                    sharedContactResourceIds
-----------------                    ------------------------
7df82329-fc31-4feb-4392-04a2b7a55f2a {507b4042-6f1e-4855-507f-040a8e79ce55}

worksAtResourceId が外部ユーザーのリソース ID です。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?