Index of every page on this site: llms.txt
All skills
jeremylongshore avatar

/vastai-webhooks-events

@0d57af8
Run it yourself

Analyze, verify, and operate Vast.ai notification webhooks with exact-body HMAC, replay protection, deduplication, durable enqueue, and failure-aware acknowledgment. Use when notification events must drive automation. Trigger with: "receive Vast.ai webhooks", "verify X-Vast-Signature-256", "handle duplicate Vast.ai events".

Use this Skill: https://skilld.dev/gh/jeremylongshore/tons-of-skills-marketplace/vastai-webhooks-events

Nothing lands on disk. Nothing to clean up.

Fork this Skill

Edit a local copy. It keeps the author and licence.

SKILL.md

≈87 tokens for metadata: the name and description. ≈930 when used: this file. ≈350 more on demand in 1 file.

Description uses 4.4% of example budget

Before choosing a Skill, your Agent reads its name and description. All available Skills share that space.

  • A shorter description leaves more room for other Skills. This entry exceeds our 1% size suggestion.

In our Claude Code example, all Skill names and descriptions share 8,000 characters. This Skill uses ≈350 characters, or 4.4%.

The 1% threshold is a size suggestion. Longer descriptions can still fit.

Your model, settings, and other Skills decide how much text your Agent can read.

Example settings and source

The example uses a 200k-token context and default Claude Code settings. The count includes the name, description, separators, and when_to_use when present. Codex also counts local file paths.

Skit's source and limits: Codex 0.160.1, Claude Code 2.1.292.

Signed Vast.ai Notification Receiver

Overview

Vast.ai notifications are signed, at-least-once deliveries. Verify the exact raw body before JSON parsing, reject stale timestamps, deduplicate by stable event ID, enqueue durably, and return success only after acceptance.

Prerequisites

  • Full subscription keys such as client:low_credit or client:outbid
  • Public HTTPS endpoint without redirects or private-address resolution
  • Webhook secret store, five-minute replay window, durable queue, and event ledger

Instructions

Step 1: Create a bounded subscription

Discover valid notification types and subscribe only the required full client or host keys. Respect the four-webhook-per-user limit and retain context-specific webhooks when short slugs overlap.

Step 2: Store the one-time secret

Capture the signing secret at create or rotate time because list and update responses do not return it. Test retrieval and rotation ownership.

Step 3: Verify raw delivery

Require POST, read exact body bytes, combine integer X-Vast-Timestamp, a period, and raw body, then compare the HMAC-SHA256 against X-Vast-Signature-256 in constant time.

Step 4: Reject replay and duplicates

Reject missing or malformed headers and timestamps older than 300 seconds. Deduplicate retries using X-Vast-Event-Id or payload event_id.

Step 5: Acknowledge after durable enqueue

Persist the verified event and return 2xx quickly. Process side effects asynchronously and idempotently; the delivery timeout is ten seconds.

Step 6: Test and operate failure paths

Use the provider test delivery, verify rotation, and monitor permanent 3xx/most-4xx failures versus retryable 408, 429, 5xx, timeout, or connection errors.

Authentication

Webhook configuration uses the scoped Vast.ai API key; delivery verification uses the distinct webhook secret. Never log either secret or parse/re-serialize JSON before signature verification.

Tool Discipline

Use Read and Grep to inspect manifests, configuration, provider output, and existing tests before proposing a mutation. Use Write or Edit only for the approved plan, implementation, test, or redacted receipt; do not create, update, destroy, or fund Vast.ai resources without explicit operator approval.

Output

  • Subscription keys, webhook ID, and secret-rotation ownership
  • Signature, replay, deduplication, enqueue, and idempotency tests
  • Delivery health and retry/permanent-failure receipt

Return webhook ID, context keys, test event ID, signature/replay/dedupe results, acknowledgment latency, queue record, and rotation date.

Examples

A client:low_credit delivery is verified from raw bytes, rejected if older than five minutes, deduplicated by event ID, enqueued, and acknowledged with 204 before the worker pages the billing owner.

Error Handling

Failure Response
Signature or timestamp is invalid Return a permanent client error and do not enqueue or disclose verification details.
Duplicate event arrives Return success after confirming the original durable record; do not repeat side effects.
Queue is unavailable Return a retryable failure such as 503 rather than acknowledging data loss.
Endpoint redirects Fix the configured final HTTPS URL because redirects are permanent delivery failures.

Resources

Source: SKILL.md on GitHub

No rule matched.

skilld matched fixed text patterns in SKILL.md and file names. Patterns miss obfuscated code.

skilld run checks every file with the same patterns. It asks for approval before it loads a Skill with a behavior marked Needs approval.

No alerts2mo3 checks · Risk SAFE
  • Gen Agent Trust Hub2mo

    The skill provides standard event-driven orchestration for Vast.ai GPU instances. It uses a Python-based polling mechanism to monitor instance status and trigger recovery actions. A low-severity surface for indirect prompt injection was identified because the skill processes data from a cloud API to drive automated actions without explicit sanitization of text-based metadata.

  • Socket2mo

    No alerts

  • Snyk2mo

    Risk: LOW · No issues

Signed by skilld at 0d57af8. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub yesterday.

Activeupdated 2 months ago
What it can do
Reads files Edits files
Modelinherit
version
2.0.0
argument-hint
[client-or-host-event-keys-and-public-https-endpoint]
model
inherit
All 4 allowed tools
ReadGrepWriteEdit
Other metadata
effort
high
author
Jeremy Longshore <jeremy@intentsolutions.io>
tags
[
  "saas",
  "vastai",
  "webhooks",
  "signatures",
  "event-processing"
]
compatibility
Requires a public HTTPS receiver, durable queue and deduplication store, secret manager, and notification webhook access.

README badge

README badge for jeremylongshore/tons-of-skills-marketplace/vastai-webhooks-events