本文へ移動
cccskills
無料GitHub で公開

appfolio-webhooks-events

Handle AppFolio webhook events for property management notifications. Trigger: "appfolio webhook".

インストール方法を見る

含まれるファイル(1)

  • SKILL.md5.9 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

AppFolio Webhooks & Events

Overview

AppFolio Stack delivers real-time webhook notifications for property management lifecycle events including tenant onboarding, lease execution, rent payments, and maintenance workflows. Use these webhooks to sync AppFolio data with your CRM, accounting system, or custom property management dashboards without polling the API.

Prerequisites

  • Written confirmation in the current AppFolio partner contract that the target portfolio supports the event types, registration process, delivery semantics, and signature scheme. Do not infer webhook support from another integration.
  • A bounded raw-body ingress route, managed webhook secret, durable event store, queue, idempotency table, and owner for downstream accounting/CRM effects.
  • A sandbox endpoint and synthetic events for valid, malformed, duplicate, and delayed-delivery tests before production registration.

Instructions

  1. Register events only through the provider-issued process and contract-bound client after verifying the target URL, allowlist, and secret delivery path.
  2. Verify bounded raw bytes and the signature before parsing; reject malformed or replayed events without logging tenant, payment, or lease content.
  3. Persist the event ID, type, received time, and encrypted/minimized payload transactionally before acknowledging delivery, then process it asynchronously.
  4. Enforce durable idempotency and reconcile unknown downstream outcomes before writing CRM, accounting, tenant, lease, or work-order state.

Webhook Registration

// Use this only if the signed provider contract explicitly supports this API.
const response = await createVerifiedAppFolioClient().post("/webhooks", {
    url: "https://yourapp.com/webhooks/appfolio",
    events: ["tenant.created", "work_order.updated", "payment.received", "lease.signed"],
    secret: process.env.APPFOLIO_WEBHOOK_SECRET,
});

Signature Verification

import crypto from "crypto";
import { Request, Response, NextFunction } from "express";

function verifyAppFolioSignature(req: Request, res: Response, next: NextFunction) {
  const signature = req.headers["x-appfolio-signature"] as string;
  const expected = Buffer.from(crypto
    .createHmac("sha256", process.env.APPFOLIO_WEBHOOK_SECRET!)
    .update(req.body)
    .digest("hex"));
  const received = signature ? Buffer.from(signature) : Buffer.alloc(0);
  if (received.length !== expected.length || !crypto.timingSafeEqual(received, expected)) {
    return res.status(401).json({ error: "Invalid signature" });
  }
  next();
}

Event Handler

import express from "express";
const app = express();

app.post("/webhooks/appfolio", express.raw({ type: "application/json" }), verifyAppFolioSignature, (req, res) => {
  const event = JSON.parse(req.body.toString());
  // persistIncomingEvent performs a durable idempotency insert and queue write
  // in one transaction. A failed persist must receive a retryable response.
  persistIncomingEvent(event).then(() => {
    res.status(202).json({ received: true });
  }).catch(() => {
    res.status(503).json({ error: "Event persistence unavailable" });
  });
});

Event Types

EventPayload FieldsUse Case
tenant.createdtenant_id, property_id, emailSync new tenant to CRM
work_order.updatedwork_order_id, status, assigned_vendorDispatch or escalate maintenance
payment.receivedlease_id, amount_cents, payment_methodUpdate accounting ledger
lease.signedlease_id, move_in_date, term_monthsActivate unit and send welcome
lease.expiredlease_id, unit_id, vacate_dateTrigger renewal or re-listing

Retry & Idempotency

async function handleIdempotent(event: { id: string; type: string; data: any }) {
  if (await durableEventStore.hasSucceeded(event.id)) return;
  await routeEvent(event);
  await durableEventStore.markSucceeded(event.id);
}

Error Handling

IssueCauseFix
Signature mismatchWrong secret or parsed bodyUse express.raw() for verification
Duplicate eventsAppFolio retry on timeoutTrack event IDs for idempotency
Missing property_idEvent from archived propertyCheck property status before processing
Durable store/queue unavailableCannot guarantee acknowledged event survivesReturn retryable 503; do not acknowledge before persistence

Output

  • A contract-gated webhook registration decision and a fail-closed raw-body signature verification result
  • A durable receipt for each accepted event before acknowledgement, with minimized/encrypted content and durable idempotency state
  • A controlled asynchronous processing outcome that can be retried or reconciled without duplicate tenant, lease, payment, or work-order effects

Examples

For a synthetic work-order update, deliver a valid signed event, a malformed signature, a duplicate ID, and a downstream timeout. Prove the valid event is persisted before 202, the malformed request is rejected without parsing, the duplicate does not produce a second side effect, and the timeout remains queued for reconciliation. If provider support, raw-body capture, signature secret, durable store, or queue is unavailable, keep the endpoint disabled and use the provider-approved polling/reconciliation path instead.

Resources

Next Steps

See appfolio-security-basics.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Build a synthetic-data CI gate for customer-controlled Abridge integration code without calling undocumented vendor interfaces. Use when adding regression checks to an Abridge deployment repository. Trigger with "test the Abridge integration".

日本語の概要は準備中です。原文の説明を表示しています。

jeremylongshore/tons-of-skills-marketplace2,8322026年10月13日 更新

Triage Abridge recording, note-review, Epic handoff, and access failures from observed evidence without inventing vendor error codes. Use when an Abridge clinical workflow is degraded. Trigger with "diagnose this Abridge issue".

日本語の概要は準備中です。原文の説明を表示しています。

jeremylongshore/tons-of-skills-marketplace2,8322026年10月13日 更新

Design and verify the clinician workflow from consent through recording, draft review, Linked Evidence, and final note disposition. Use when implementing or auditing an Abridge clinical documentation pathway. Trigger with "map the Abridge note workflow".

日本語の概要は準備中です。原文の説明を表示しています。

jeremylongshore/tons-of-skills-marketplace2,8322026年10月13日 更新

Verify the approved handoff of clinician-reviewed Abridge note sections into Epic templates and downstream workflows. Use when configuring or auditing Abridge-to-Epic documentation flow. Trigger with "verify the Abridge Epic handoff".

日本語の概要は準備中です。原文の説明を表示しています。

jeremylongshore/tons-of-skills-marketplace2,8322026年10月13日 更新

Evaluate Abridge adoption, workflow value, and avoidable operational friction without inventing prices or vendor billing meters. Use when reviewing an Abridge rollout or renewal. Trigger with "analyze Abridge value".

日本語の概要は準備中です。原文の説明を表示しています。

jeremylongshore/tons-of-skills-marketplace2,8322026年10月13日 更新

Produce a PHI-minimized Abridge support bundle with provenance, redaction, and protected escalation boundaries. Use when support needs reproducible evidence for an Abridge issue. Trigger with "build an Abridge debug bundle".

日本語の概要は準備中です。原文の説明を表示しています。

jeremylongshore/tons-of-skills-marketplace2,8322026年10月13日 更新

jeremylongshore のスキルをすべて見る

このスキルの問題を報告する