LogRequests resource (Data API 19.10)

Summary

Http Method Resource Description
POST /log_requests/ecdn Requests a LogFile-Fetching for the passed zone and time frame.
GET /log_requests/ecdn/{id} Retrieves the current execution status of the log file fetching.

Request Log File

Requests a LogFile-Fetching for the passed zone and time frame.

Url

POST https://hostname:port/dw/data/v19_10/log_requests/ecdn

Formats

json, xml

Authentication

Name Description
OAuth Authentication via OAuth token.

Request Document

EcdnLogFetchRequest

Response Document

EcdnLogFetchResponse

Sample

REQUEST:
POST /s/-/dw/data/v19_10/log_requests/ecdn HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Content-Type: application/json; charset=UTF-8
{
  "zone_name": "sitegenesis.com",
  "start_time": "2018-09-14T16:48:07Z",
  "end_time": "2018-09-14T16:53:07Z"
}

# in case of success:

RESPONSE:
HTTP/1.1 200 OK
Expires: Thu, 01-Jan-1970 00:00:00 GMT
{
  "_v": "19.10",
  "_type": "ecdn_log_fetch_response",
  "id": "9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0",
  "status": "pending"
}

# in case of finished log fetch operation:

RESPONSE:
HTTP/1.1 200 OK
Expires: Thu, 01-Jan-1970 00:00:00 GMT
{
  "_v": "19.10",
  "_type": "ecdn_log_fetch_response",
  "id": "9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0",
  "status": "finished",
  "link": "https://ecdn.commercecloud.salesforce.com/logs/sitegenesis_com_2018_09_14.gz?token=3d03ekddsflk3m4fl3ekmdes"
}

# in case of zone not found:

RESPONSE:
HTTP/1.1 404 NOT FOUND
Expires: Thu, 01-Jan-1970 00:00:00 GMT
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
  "_v": "19.10",
  "_type": "fault",
  "fault":
  {
    "arguments":
    {
      "id": "sitegenesis.com"
    }
    "type": "ZoneNotFoundException",
    "message": "No zone with name 'sitegenesis.com' was found."
  }
}

Read Logfetching Execution status

Retrieves the current execution status of the log file fetching.

Url

GET https://hostname:port/dw/data/v19_10/log_requests/ecdn/{id}

Formats

json, xml

Authentication

Name Description
OAuth Authentication via OAuth token.

Response Document

EcdnLogFetchResponse

Path Parameters

Parameter Type Description Constraints
id String ID of the log fetching execution mandatory=true, nullable=false

Sample

REQUEST:
GET /s/-/dw/data/v19_10/log_requests/ecdn/9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0 HTTP/1.1
Host: example.com
Authorization: Bearer a5b6eb0d-8312-41a3-88f3-2c53c4507367
Content-Type: application/json; charset=UTF-8
{
  "zone_name": "sitegenesis.com",
  "start_time": "2018-09-14T16:48:07Z",
  "end_time": "2018-09-14T16:53:07Z"
}

# in case of success:

RESPONSE:
HTTP/1.1 200 OK
Expires: Thu, 01-Jan-1970 00:00:00 GMT
{
  "_v": "19.10",
  "_type": "ecdn_log_fetch_response",
  "id": "9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0",
  "status": "pending"
}

# in case of finished log fetch operation:

RESPONSE:
HTTP/1.1 200 OK
Expires: Thu, 01-Jan-1970 00:00:00 GMT
{
  "_v": "19.10",
  "_type": "ecdn_log_fetch_response",
  "id": "9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0",
  "status": "finished",
  "link": "https://ecdn.commercecloud.salesforce.com/logs/sitegenesis_com_2018_09_14.gz?token=3d03ekddsflk3m4fl3ekmdes"
}

# in case of zone not found:

RESPONSE:
HTTP/1.1 404 NOT FOUND
Expires: Thu, 01-Jan-1970 00:00:00 GMT
Content-Type: application/json;charset=UTF-8
Cache-Control: max-age=0,no-cache,no-store,must-revalidate
{
  "_v": "19.10",
  "_type": "fault",
  "fault":
  {
    "arguments":
    {
      "id": "9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0"
    }
    "type": "EcdnLogFetchRequestNotFoundException",
    "message": "No log fetch operation request with ID '9f83cls0-d93d-llus-foo1-p8dsl3dkcpw0' was found."
  }
}
X Privacy Update: We use cookies to make interactions with our websites and services easy and meaningful, to better understand how they are used and to tailor advertising. By continuing to use this site you are giving us your consent to do this.