Partner Marketplace & Webhook Delivery
ReformCode partner apps connect external developer tools to public score, trust, readiness, dependency, deploy, policy, and team command-center signals. The marketplace control plane now covers registration, signing-key rotation, HTTPS subscriptions, signed delivery queueing, retry tracking, dead-letter replay, and health reporting.
Register A Partner App
Admins can create a partner app with:
curl -X POST https://reformcode.com/api/admin/partners/marketplace \
-H "content-type: application/json" \
-d '{
"name": "Acme Dev Tools",
"websiteUrl": "https://acme.example",
"contactEmail": "partners@acme.example",
"requestedEvents": ["trust.updated", "score.updated"],
"allowedOrigins": ["https://docs.acme.example"]
}'
The response includes a one-time plaintextSecret. Store it immediately. Set PARTNER_SECRET_ENCRYPTION_KEY in production; ReformCode stores encrypted signing material for outbound delivery retries plus a hash and preview for audit checks.
Supported events:
score.updatedtrust.updatedreadiness.updatedteam.command_center.updateddependency.incident.createddeploy.certification.updatedpolicy.simulation.blocked
Configure Webhooks
Create a subscription for each partner endpoint:
curl -X POST https://reformcode.com/api/admin/partners/marketplace/{appId}/subscriptions \
-H "content-type: application/json" \
-d '{
"endpointUrl": "https://hooks.acme.example/reformcode",
"events": ["trust.updated", "score.updated"]
}'
Webhook requests include:
x-reformcode-eventx-reformcode-deliveryx-reformcode-timestampx-reformcode-signature
Verify the signature as HMAC_SHA256(secret, timestamp + "." + body) and reject requests older than five minutes.
Partner endpoint requirements:
- Use HTTPS.
- Return
2xxonly after the event is safely accepted. - Deduplicate by
x-reformcode-delivery. - Preserve the raw request body for signature verification.
- Ask ReformCode to rotate the key immediately if the secret is exposed.
Delivery Operations
Queued deliveries retry with backoff at 1, 5, 15, 30, and 60 minutes. After the retry budget is exhausted, the delivery moves to dead_lettered for manual replay or archive.
Operators can inspect marketplace health and delivery logs from GET /api/admin/partners/marketplace. The health report treats success below 95%, retrying deliveries, and dead-lettered events as launch risks.
Operational endpoints:
POST /api/admin/partners/marketplace/{appId}/deliveriesenqueues signed deliveries for matching active subscriptions.POST /api/admin/partners/marketplace/deliveries/dispatchsends due queued or retrying deliveries.POST /api/admin/partners/webhook-deliveries/{deliveryId}/attemptsrecords a response code or network error.POST /api/admin/partners/webhook-deliveries/{deliveryId}/retrymanually requeues a failed or dead-lettered delivery.
Key Rotation
Rotate keys regularly and whenever a partner suspects exposure:
curl -X POST https://reformcode.com/api/admin/partners/marketplace/{appId}/keys/rotate
Existing active keys move into rotating status with an expiry window. The new plaintext secret is returned once.