Langsung ke konten
Skillpedia
API & server (backend)48k Β· #3772

api-integration

Fungsinya

Skill ini membantu merancang bagaimana berbagai sistem komputer bisa saling terhubung. Skill ini membuat alur pengiriman data, seperti pada sistem pengiriman pesan atau saat menghubungkan beberapa tool sekaligus.

Kapan dipakai

  • βœ“Saat Anda perlu menghubungkan dua atau lebih sistem perangkat lunak.
  • βœ“Saat Anda ingin satu sistem memberi tahu sistem lain tentang sesuatu yang baru terjadi.
  • βœ“Saat Anda perlu memindahkan data dari satu tempat ke tempat lain secara otomatis.

Link skill

https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/api-integration/SKILL.md

Salin lalu tempelkan ke AI Anda (Claude, ChatGPT, atau Cursor) dan minta AI mengikuti instruksinya.

Cara pakai

Cara paling mudah: salin pesan ini dan tempelkan ke AI Anda. AI akan membaca skill dan mengikuti instruksinya.

Pesan siap tempel

Gunakan skill ini untuk membantu saya: https://github.com/sickn33/agentic-awesome-skills/blob/main/plugins/agentic-awesome-skills-claude/skills/api-integration/SKILL.md Baca file SKILL.md di link tersebut dan ikuti instruksinya untuk tugas saya.
Mau AI Anda menemukan skill seperti ini sendiri?Pasang MCP Skillpedia gratis: cukup satu baris, dan AI mencari di antara 15.000+ skill sebelum tiap tugas.Pasang dalam 1 menit β†’

Contoh permintaan ke AI

β€œBagaimana cara membuat website saya memberi tahu sistem inventaris saya ketika ada pesanan baru?”

5 skill baru setiap minggu. 1 menit baca.

Cara kerjanya

Skill ini menentukan 'jalur' yang dilalui data antar sistem. Ini bisa berupa pengiriman pesan (seperti webhook) atau pembuatan urutan aksi yang saling bergantung.

Konten teknis (SKILL.md asli)

Teks asli dari pembuat, dalam bahasa Inggris, langsung dari GitHub.

API Integration Skill

When to Use

Use this skill when you need designs event-driven architectures, webhook systems, API chaining flows, ETL pipelines, and integration patterns between services. Use whenever the user asks about webhooks, event streaming, API composition, connecting two or more APIs, building pipelines, Pub/Sub, Kafka topics, ETL...

Design integration patterns, webhook flows, event pipelines, and API composition strategies.


Webhook Design

Outbound Webhook Endpoint (from your system to 3rd party)

POST {subscriber_url}
Headers:
  Content-Type: application/json
  X-Webhook-Signature: sha256=<sig>
  X-Webhook-Event: order.created
  X-Webhook-Delivery: <uuid>
  X-Webhook-Timestamp: <unix-epoch>

Payload envelope

{
  "event": "order.created",
  "delivery_id": "uuid",
  "created_at": "ISO8601",
  "data": { ... }
}

Signature verification (receiver side):

import hmac, hashlib
expected = hmac.new(secret.encode(), payload_bytes, hashlib.sha256).hexdigest()
# webhook-signature-example: do not use assert for an authorization boundary
if not hmac.compare_digest(f"sha256={expected}", request.headers.get("X-Webhook-Signature", "")):
    raise ValueError("Invalid webhook signature")

Inbound Webhook Registration API

POST   /api/v1/webhooks           β€” register subscriber URL + events
GET    /api/v1/webhooks           β€” list subscriptions
DELETE /api/v1/webhooks/{id}      β€” unsubscribe
POST   /api/v1/webhooks/{id}/test β€” fire test event
GET    /api/v1/webhooks/{id}/deliveries β€” delivery history + status

API Chaining / Composition Pattern

Step 1: POST /auth/token           β†’ get access_token
Step 2: GET  /api/v1/user/profile  β†’ get user.id (use token from step 1)
Step 3: POST /api/v1/orders        β†’ create order (use user.id from step 2)
Step 4: POST /api/v1/payments      β†’ charge (use order.id from step 3)

Always: handle failures at each step independently, use idempotency keys, implement retry with exponential backoff.


Event-Driven Architecture

Event Schema (CloudEvents spec)

{
  "specversion": "1.0",
  "type": "com.example.order.created",
  "source": "/orders-service",
  "id": "uuid",
  "time": "2024-01-01T00:00:00Z",
  "datacontenttype": "application/json",
  "data": { "order_id": "...", "amount": 99.99 }
}

Topics / Queues design

Topic Producers Consumers Retention
orders.created orders-svc payments-svc, email-svc 7 days
payments.completed payments-svc orders-svc, ledger-svc 30 days
users.deleted users-svc all services 90 days

Saga Pattern (Distributed Transaction)

Choreography saga for order checkout:
1. orders-svc emits order.created
2. inventory-svc reserves stock β†’ emits inventory.reserved
3. payments-svc charges card β†’ emits payment.completed
4. orders-svc emits order.confirmed

On failure at step 3:
← payments-svc emits payment.failed
← inventory-svc releases stock (compensating transaction)
← orders-svc emits order.cancelled

Outbox Pattern (reliable event publishing)

-- Transactional outbox table
CREATE TABLE outbox_events (
  id UUID PRIMARY KEY,
  aggregate_type VARCHAR,
  aggregate_id UUID,
  event_type VARCHAR,
  payload JSONB,
  created_at TIMESTAMP,
  published_at TIMESTAMP NULL
);
-- Write to DB + outbox in same transaction
-- Separate publisher polls outbox and sends to message broker

Integration Checklist

  • Idempotency keys on all state-changing calls
  • Retry with exponential backoff (base 1s, max 60s, jitter)
  • Circuit breaker (open after 5 failures in 10s)
  • Dead-letter queue for unprocessable events
  • Webhook delivery logging + manual replay endpoint
  • Schema versioning on all events
  • Correlation IDs on all inter-service calls

Handoff

Report the event schemas, delivery/retry policy, idempotency and compensation boundaries, and the checks actually performed. Signature verification also needs the provider's current protocol, bounded input, timestamp/replay protection and an authorized test endpoint. A design is not evidence that an integration or payment ran.

Limitations

  • Use this skill only when the task clearly matches its upstream source and local project context.
  • Verify commands, generated code, dependencies, credentials, and external service behavior before applying changes.

…

Pertanyaan umum

Apa itu webhook?

Webhook seperti notifikasi otomatis yang dikirim satu sistem ke sistem lain ketika ada kejadian penting, misalnya pesanan baru.

Apa itu 'API Chaining'?

Ini adalah cara menghubungkan beberapa panggilan API secara berurutan, di mana hasil dari satu panggilan dipakai di panggilan berikutnya, seperti mengikuti resep langkah demi langkah.

Apa itu 'Event-Driven Architecture'?

Ini adalah gaya desain di mana sistem bereaksi terhadap 'event' (kejadian), alih-alih dikendalikan secara langsung. Bayangkan sebuah sistem yang hanya bekerja saat menerima notifikasi.

Detail

Deskripsi asli dari pembuat

Designs event-driven architectures, webhook systems, API chaining flows, ETL pipelines, and integration patterns between services.

repo: sickn33/agentic-awesome-skills

Popularitas

Bintang GitHub
48k
Peringkat
#3772
Lisensi
MIT
Diperbarui
15/10/2026

Apakah skill ini berguna?

0

Masuk untuk memberi suara.

Komentar

  • …

Skill lain dari repositori ini

Skill serupa