GET/audits/logs/download

Downloads audit logs in CSV format. This API operation is available only to the Super Admin, sub-admins and service accounts of the domain.

Note

  • For how to download content using the API, see Upload or Download Files.
  • If the service parameter is set to “message”, a "message event" is returned. If you need to download "message content", use the Download message content API .

Caution:

  • DO NOT make parallel API requests. Complete downloading audit logs from the returned URL and then make another API request to download audit logs.
  • If an error occurs during download, an error message is displayed after "downloadLogs error" at the end of the file.
  • The returned URL expires after a specified period. Please get the latest download URL.
  • To use this API operation using authentication with a user account (OAuth), you must go to Service Management > Audit in the LINE WORKS Admin using the user account and agree to the use of Audit in advance.

Authorization

oauth2

OAuth 2.0 authentication.
For more information, see Authentication and Authorization.

Scope

audit.read

HTTP Request

GEThttps://www.worksapis.com/v1.0/audits/logs/download

Query Parameters

ParameterTypeDescription
service string 

Audit log service type

  • admin: Admin
  • board: Board
  • bot: Bot API
  • drive: Drive
  • calendar: Calendar
  • contact: Contacts
  • task: Task
  • form: Form
  • share: Share screen
  • note: Note
  • received-mail: Receive email messages
  • sent-mail: Send email messages
  • deleted-mail: Delete email messages
  • message: Message/Roger - Send/Receive
  • message-join-exit: Message/Roger - Join/Remove
  • call: Call
  • ainote: AiNote
  • template: Template
  • mobile-capture: Mobile screenshot
  • developer: Developer Console
  • delegated-api: Delegated API
  • auth: Login
  • file-download: File

required
Allowed values : admin, board, bot, drive, calendar, contact, task, form, share, note, received-mail, sent-mail, deleted-mail, message, message-join-exit, call, ainote, template, mobile-capture, developer, delegated-api, auth, file-download 
startTime string 

Start date from which you want to get audit data (YYYY-MM-DDThh:mm:ssTZD).
The period between the start date and the end date must be within 31 days.
+ must be URL-encoded to %2B.


required
example : 2021-11-01T00:00:00%2B09:00 
endTime string 

End date until which you want to get audit data (YYYY-MM-DDThh:mm:ssTZD).
The period between the start date and the end date must be within 31 days.
+ must be URL-encoded to %2B.


required
example : 2021-11-30T23:59:59%2B09:00 
language string 

Language in which the CSV file to download is written.


default : en_US
Allowed values : ja_JP, ko_KR, zh_CN, zh_TW, en_US 
botMessageFilterType string 

Bot message filter type

  • include: Include
  • exclude: Exclude
  • only: Bot messages only

default : include
Allowed values : include, exclude, only 
domainId integer 

Domain ID (For a corporate group, it is used to get the logs of another domain.)


example : 10000001
format : int32 
string 

default : include
Allowed values : include, exclude, only 

Header Parameters

HeadertypeDescription
Authorization string 

Bearer {token}


required 

Response

HTTP 302

Found - Redirects to the download URL specified in the Location header.