{"id":30437,"date":"2021-08-24T12:03:39","date_gmt":"2021-08-24T11:03:39","guid":{"rendered":"https:\/\/multisite.korebots.com\/v9-0\/uncategorised-ja\/get-audit-logs-api\/"},"modified":"2021-08-24T12:10:13","modified_gmt":"2021-08-24T11:10:13","slug":"get-audit-logs-api","status":"publish","type":"post","link":"https:\/\/multisite.korebots.com\/v9-0\/uncategorised-ja\/get-audit-logs-api\/","title":{"rendered":"\u7ba1\u7406\u8005\u30b3\u30f3\u30bd\u30fc\u30eb\u306e\u76e3\u67fb\u30ed\u30b0API\u3092\u53d6\u5f97"},"content":{"rendered":"<section class=\"l-section wpb_row height_auto\"><div class=\"l-section-h i-cf\"><div class=\"g-cols vc_row via_grid cols_1 laptops-cols_inherit tablets-cols_inherit mobiles-cols_1 valign_top type_default stacking_default\"><div class=\"wpb_column vc_column_container\"><div class=\"vc_column-inner\"><div class=\"wpb_text_column\"><div class=\"wpb_wrapper\"><p>To get admin console audit logs.<\/p>\n<p class=\"note\">To use this API, app needs the Admin API Scope.<\/p>\n<p><b>GET <\/b><code>https:\/\/{{host}}\/<span style=\"font-weight: 400;\">api\/public\/auditlogs?size=50&amp;offset=0&amp;fromDate={{timestamp}}&amp;toDate={{timestamp}}&amp;fetchAfter={{AuditLogId}}<\/span><\/code><\/p>\n<p>NOTE: This feature was introduced in ver7.2 of the platform.<\/p>\n<\/div><\/div><div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div><div class=\"wpb_text_column\"><div class=\"wpb_wrapper\"><h3><span class=\"ez-toc-section\" id=\"Query_Parameters\"><\/span>Query Parameters<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>&nbsp;<\/p>\n<table>\n<tbody>\n<tr>\n<th>Parameter<\/th>\n<th>Description<\/th>\n<\/tr>\n<tr>\n<td>host<\/td>\n<td>Environment URL, for example, https:\/\/bots.kore.ai<\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">size<\/span><\/td>\n<td>Number of records to be fetched upto a maximum of 100<\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">offset<\/span><\/td>\n<td>Specify the page number from which to start fetching the logs. If unspecified, it starts from 0, which is the first page of the list of logs<\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">fromDate<\/span><\/td>\n<td>Takes the date format yyyy-mm-dd<br \/>\n(or) yyyy-mm-ddThh:mm:ss.msZ<br \/>\neg:2019-04-01 (or) 2019-04-01T13:25:58.515Z<\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">toDate<\/span><\/td>\n<td>Takes the date format yyyy-mm-dd<br \/>\n(or) yyyy-mm-ddThh:mm:ss.msZ<br \/>\neg:2019-04-01 (or) 2019-04-01 T13:26:05.598Z<\/td>\n<\/tr>\n<tr>\n<td><span style=\"font-weight: 400;\">fetchAfter<br \/>\n(optional)<\/span><\/td>\n<td>Audit Log Id from where you want to fetch the logs.<br \/>\nThis is an unique incremental ID for each record created under audit logs and you can obtain it from looking at the previous audit log file.<\/td>\n<\/tr>\n<\/tbody>\n<\/table>\n<\/div><\/div><div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div><div class=\"wpb_text_column\"><div class=\"wpb_wrapper\"><h3><span class=\"ez-toc-section\" id=\"%E8%AA%8D%E8%A8%BC\"><\/span>\u8a8d\u8a3c<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p>\u4ee5\u4e0b\u306e\u69cb\u6587\u3092\u4f7f\u7528\u3057\u3066\u3001JWT\u3092\u30d8\u30c3\u30c0\u30fc\u306b\u542b\u3080API\u3092\u547c\u3073\u51fa\u3057\u307e\u3059\u3002 <code>auth: {{JWT}}<\/code><\/p>\n<\/div><\/div><div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div><div class=\"wpb_text_column\"><div class=\"wpb_wrapper\"><h3><span class=\"ez-toc-section\" id=\"%E5%BF%9C%E7%AD%94%E3%81%AE%E3%82%B3%E3%83%B3%E3%83%86%E3%83%B3%E3%83%84%E3%82%BF%E3%82%A4%E3%83%97\"><\/span>\u5fdc\u7b54\u306e\u30b3\u30f3\u30c6\u30f3\u30c4\u30bf\u30a4\u30d7<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p><code>application\/json<\/code><\/p>\n<\/div><\/div><div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div><div class=\"wpb_text_column\"><div class=\"wpb_wrapper\"><h3><span class=\"ez-toc-section\" id=\"Sample_Request\"><\/span>Sample Request<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<pre>curl --location --request GET '  \r\n  https:\/\/{{host}}\/api\/public\/auditlogs?size=50&amp;offset=0&amp;fromDate=2021-07-07T11:11:18.464Z&amp;toDate=2021-06-30T11:11:18.469Z' \\\r\n--header 'auth: YOUR_JWT_ACCESS_TOKEN' \\\r\n--header 'Content-Type: application\/json'<\/pre>\n<\/div><\/div><div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div><div class=\"wpb_text_column\"><div class=\"wpb_wrapper\"><h3><span class=\"ez-toc-section\" id=\"Sample_Response\"><\/span>Sample Response<span class=\"ez-toc-section-end\"><\/span><\/h3>\n<p><a ref=\"magnificPopup\" href=\"https:\/\/s3-us-east-2.amazonaws.com\/kore-wordpress\/developer.kore.ai\/wp-content\/uploads\/sites\/22\/20210713131454\/img.png\"><img loading=\"lazy\" decoding=\"async\" class=\"alignnone size-full wp-image-28587\" src=\"https:\/\/s3-us-east-2.amazonaws.com\/kore-wordpress\/developer.kore.ai\/wp-content\/uploads\/sites\/22\/20210713131454\/img.png\" alt=\"\" width=\"812\" height=\"784\" \/><\/a><\/p>\n<\/div><\/div><div class=\"w-separator size_small with_line width_default thick_1 style_solid color_border align_center\"><div class=\"w-separator-h\"><\/div><\/div><\/div><\/div><\/div><\/div><\/section>\n","protected":false},"excerpt":{"rendered":"To get admin console audit logs. To use this API, app needs the Admin API Scope. GET https:\/\/{{host}}\/api\/public\/auditlogs?size=50&amp;offset=0&amp;fromDate={{timestamp}}&amp;toDate={{timestamp}}&amp;fetchAfter={{AuditLogId}} NOTE: This feature was introduced in ver7.2 of the platform. Query Parameters &nbsp; Parameter Description host Environment URL, for example, https:\/\/bots.kore.ai size Number of records to be fetched upto a maximum of 100 offset Specify the page...","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[79],"tags":[],"jetpack_featured_media_url":"","_links":{"self":[{"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/posts\/30437"}],"collection":[{"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/comments?post=30437"}],"version-history":[{"count":3,"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/posts\/30437\/revisions"}],"predecessor-version":[{"id":30643,"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/posts\/30437\/revisions\/30643"}],"wp:attachment":[{"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/media?parent=30437"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/categories?post=30437"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/multisite.korebots.com\/v9-0\/wp-json\/wp\/v2\/tags?post=30437"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}