# Review Response SLA Ledger (`theendfear/factory-review-response-sla-ledger`) Actor

Reconcile user-provided review timestamps against explicit elapsed-hour response policies; expose unknown and conflicting records.

- **URL**: https://apify.com/theendfear/factory-review-response-sla-ledger.md
- **Developed by:** [Marco S.](https://apify.com/theendfear) (community)
- **Categories:** Business
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$2.00 / 1,000 valid output record emitteds

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

## Review Response SLA Ledger

### What it does

Evaluate user-provided reviews against explicit elapsed-hour response obligations. Emits a reproducible deadline ledger, not sentiment analysis or generated replies.

### Who it is for

Customer-experience agencies and account managers with response-time commitments who otherwise reconcile timestamps in spreadsheets.

### Input

Provide reviews (or records), slaPolicies and asOf. Reviews need locationId and reviewId. publishedAt/respondedAt/asOf require RFC3339 offsets; timezone-naive or invalid dates are not inferred. Policies are elapsedHours (0..8760). Limit 10,000 review rows and 10,000 policies per run. Unknown response presence is not treated as unanswered. Free-text customer review content is neither required nor copied to output.

### Output

locationId, reviewId, deadlineAt, firstResponseAt, slaStatus, overdueSeconds, sourceRowIndexes. Status is pending, overdue, met, late, response\_time\_unknown or invalid. Invalid dates/conflicting policies are explicit; rows without identities are skipped and not billed.

### How it works

Group exact trimmed location/review IDs, retaining indexes. Deduplicate logical obligations. Reject conflicting publication timestamps or policies. Use UTC elapsed-time arithmetic: deadline = publishedAt + elapsedHours \* 3600 seconds. The earliest valid response before asOf meets its SLA if response <= deadline. Explicitly unanswered reviews are overdue only if asOf > deadline. Unknown or invalid response timing never becomes a fabricated late response. DST is handled through explicit offsets, not business calendars. No probabilistic score is used.

### Example

```json
{
  "reviews": [
    {
      "locationId": "L",
      "reviewId": "R1",
      "publishedAt": "2026-09-01T00:00:00Z",
      "responsePresent": false
    },
    {
      "locationId": "L",
      "reviewId": "R2",
      "publishedAt": "2026-09-01T00:00:00Z",
      "responsePresent": true,
      "respondedAt": "2026-09-02T00:00:00Z"
    }
  ],
  "slaPolicies": [
    {
      "locationId": "L",
      "elapsedHours": 24
    }
  ],
  "asOf": "2026-09-02T01:00:00Z"
}
```

Expected: R1 overdue by 3600 seconds; R2 met exactly at the deadline. Duplicate rows do not create another billed obligation. Deterministic replay produces identical records; source indexes refer to the supplied input order.

### Pricing

One review\_sla\_record\_emitted event per emitted identified obligation, including useful invalid/unknown diagnoses. No charge for empty input, unidentified malformed records or duplicate obligations. Proposed rates and margins require private canary and remote pricing validation before publication; no revenue is claimed.

### Limitations

No autonomous scraping. This Actor does not acquire reviews, send messages, generate replies or infer sentiment. It does not support business-day contracts, holiday calendars or unbounded inputs. A customer-supplied policy may be wrong; source permissions and data retention remain the caller's responsibility. Missing timestamps and missing response flags remain unknown. This tool is not a legal determination of contract compliance.

### Integration

Use exports you are authorized to process from existing review collection tools, then consume the ledger in spreadsheets or downstream workflow software. Data acquisition costs are separate; no upstream Actor is run by this product.

### Differentiation

Unlike the portfolio social content snapshot monitor or dataset unifier, this product compares explicit response-time obligations, keeps provenance and exposes temporal uncertainty. It is not a renamed scraper or a generic change score.

# Changelog

This Actor's version history is a separate document: https://apify.com/theendfear/factory-review-response-sla-ledger/changelog.md

# Actor input Schema

## `reviews` (type: `array`):

locationId, reviewId, offset-bearing publishedAt, explicit responsePresent and optional respondedAt. No review text required.

## `records` (type: `array`):

Alternative to reviews.

## `slaPolicies` (type: `array`):

locationId and elapsedHours, 0..8760. No business-day policies.

## `asOf` (type: `string`):

Offset-bearing RFC3339 timestamp, required for nonempty valid identities.

## `maxRecords` (type: `integer`):

Maximum supplied review records; exceed the cap to fail before output and billing.

## Actor input object example

```json
{
  "maxRecords": 10000
}
```

# Actor output Schema

## `results` (type: `string`):

No description

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {};

// Run the Actor and wait for it to finish
const run = await client.actor("theendfear/factory-review-response-sla-ledger").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {}

# Run the Actor and wait for it to finish
run = client.actor("theendfear/factory-review-response-sla-ledger").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call theendfear/factory-review-response-sla-ledger --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,theendfear/factory-review-response-sla-ledger"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/AMaoIXI8rikMJmPhe/builds/rjWr417Re1eRNCgWw/openapi.json
