Public Hosting Request Logs

A PublicHostingRequestLog is an audit log for monitoring requests we received to access your publicly served folders.

Logs available through this endpoint are retained for 6 months, after which they are automatically discarded. For longer retention, use Files.com SIEM integrations to stream logs in real time to your preferred SIEM, or configure SIEM streaming to a file.

List Public Hosting Request Logs

Endpoint

GET/public_hosting_request_logs

Return Object

PublicHostingRequestLog[]

Authorization Requirement

Requires either a Site-Wide API key or User API key or session from a User with Site Admin permissions.

Additional Arguments

Example Request

curl https://app.files.com/api/rest/v1/public_hosting_request_logs.json \
  -H 'X-FilesAPI-Key: YOUR_API_KEY'

Example Response

[
  {
    "timestamp": "2000-01-01T01:00:00Z",
    "remote_ip": "example",
    "server_ip": "example",
    "hostname": "example",
    "path": "example",
    "responseCode": 1,
    "success": true,
    "duration_ms": 1,
    "created_at": "2000-01-01T01:00:00Z",
    "bytes_transferred": 1,
    "http_method": "GET"
  }
]

The PublicHostingRequestLog Object

Some of the endpoints above return a PublicHostingRequestLog object. The attributes of this object are listed below.

AttributeDescription
timestamp
date-time
Start Time of Action. Deprecrated: Use created_at.
remote_ip
string
IP Address of Public Hosting Client.
server_ip
string
IP Address of Public Hosting Server.
hostname
string
HTTP Request Hostname.
path
string
HTTP Request Path. This must be slash-delimited, but it must neither start nor end with a slash. Maximum of 5000 characters.
responseCode
int64
HTTP Response Code.
success
boolean
Whether SFTP Action was successful.
duration_ms
int64
Duration (in milliseconds).
created_at
date-time
Start Time of Action.
bytes_transferred
int64
The number of bytes transferred for file downloads.
http_method
string
Method of the HTTP call.

Example PublicHostingRequestLog Object

{
  "timestamp": "2000-01-01T01:00:00Z",
  "remote_ip": "example",
  "server_ip": "example",
  "hostname": "example",
  "path": "example",
  "responseCode": 1,
  "success": true,
  "duration_ms": 1,
  "created_at": "2000-01-01T01:00:00Z",
  "bytes_transferred": 1,
  "http_method": "GET"
}