شعار Api Review

Api Review

المجتمع
robbyt
api-review

This skill should be used when reviewing API designs, auditing REST or gRPC endpoints, designing backend APIs, evaluating BFF architecture, or discussing API best practices. Also triggers on: "review this API", "API design review", "is this API correct", "REST API audit", "gRPC API review", "PATCH vs PUT", "etag", "idempotency", "pagination design", "API error handling", "backward compatibility", "BFF architecture", "resource-oriented design", "TOCTOU", "race condition", "optimistic concurrency", "field mask", "long-running operation", "custom method", "soft delete", "API naming conventions", "declarative-friendly"

نظرة عامة

الناشرrobbyt
المستودعclaude-skills
اسم المهارةapi-review
النجوم
42
التفريعات
2
الملفات المرفقة
37
الروابط
  • تعليمات بصيغة Markdown

    ملف SKILL.md يُحمّله النموذج عند الحاجة، فلا يستهلك توكنات إلا عندما يَرِد طلب ذو صلة فعلًا.

  • تعمل مع أي نموذج لغوي كبير

    مهارات الذكاء الاصطناعي مكتوبة بصيغة Markdown وليست شيفرة خاصة بمزوّد معيّن، لذا تعمل مع GPT أو Claude أو Gemini أو Grok أو نموذج محلي.

  • الملفات المرفقة: 37

    نصوص برمجية وقوالب ومراجع يمكن للنموذج قراءتها أثناء عمله. الملفات للقراءة فقط ولا تُنفّذ أبدًا.

  • مفتوحة المصدر

    نشرها robbyt على GitHub. اطّلع على المصدر قبل تثبيتها.

التثبيت

ثبّت مهارة الذكاء الاصطناعي Api Review في TypingMind لاستخدامها مع أي نموذج لغوي كبير، أو أضفها إلى وكيل ذكاء اصطناعي آخر يقرأ SKILL.md.

1

التثبيت في TypingMind

يُثبّت TypingMind المهارة مباشرةً من مجلدها على GitHub — فيقرأ SKILL.md، ويجمع ملفات الموارد في حزمة، ويحفظ النتيجة محليًا.

  1. افتح التطبيق وانتقل إلى الإضافات → المهارات.
  2. اختر «تثبيت من GitHub».
  3. الصق رابط مجلد المهارة الموضّح أدناه وأكّد التثبيت.
    https://github.com/robbyt/claude-skills/tree/main/plugins/api-design/skills/api-review
  4. فعّل المهارة في كل محادثة تريد إتاحتها فيها.
الإضافات → المهارات → إضافة مهارة → من رابط GitHub، ثم الصق رابط المجلد واضغط على «متابعة».
2

التثبيت في وكيل ذكاء اصطناعي آخر

يمكن لأي وكيل ذكاء اصطناعي يقرأ تنسيق Agent Skills استخدام هذه المهارة — انسخ المجلد إلى مجلد المهارات الخاص بذلك الوكيل.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/robbyt/claude-skills.git /tmp/claude-skills
mkdir -p .claude/skills
cp -r /tmp/claude-skills/plugins/api-design/skills/api-review .claude/skills/api-review
أعد تشغيل Claude Code بعد النسخ ليتعرّف على المهارة الجديدة.

استخدمها في TypingMind

فعّل Api Review في أي محادثة على TypingMind وسيتولى النموذج الباقي. تتضمن مطالبة النظام اسمها ووصفها، وبمجرد ورود طلب ذي صلة، يُحمّل النموذج التعليمات الكاملة تلقائيًا — فلا تحتاج إلى استدعائها يدويًا، ولا تستهلك أي توكنات حتى تُستخدم فعليًا.

يُحمّل النموذج Api Review تلقائيًا بمجرد ورود طلب ذي صلة بها.

تعمل مع أي نموذج ذكاء اصطناعي

مهارات الذكاء الاصطناعي هي تعليمات بصيغة Markdown وليست شيفرة خاصة بمزوّد معيّن، لذا لا ترتبط Api Review بالنموذج الذي كُتبت له. ثبّتها مرة واحدة في TypingMind واستخدمها مع GPT-5 أو Claude أو Gemini أو Grok أو DeepSeek أو Mistral أو Llama أو نموذج محلي تشغّله بنفسك — كل ذلك باستخدام مفاتيح API الخاصة بك.

  • تُحمَّل عند الحاجة فقط

    تتضمن مطالبة النظام الاسم والوصف فقط. وتُجلب التعليمات عند أول طلب ذي صلة، لذا لا تترتب أي تكلفة على المهارة غير المستخدمة.

  • بدّل النماذج أثناء المحادثة

    لأن المهارة تعليمات وليست شيفرة، فإن تغيير النموذج لا يعطّلها — فالنموذج التالي يقرأ ملف SKILL.md نفسه.

تعليمات المهارة

هذا هو محتوى SKILL.md الذي يُحمّله النموذج. اقرأه قبل التثبيت — فالمهارة عبارة عن تعليمات سيتبعها نموذجك.

API Design Review

Expert guidance for API design based on Google's API Improvement Proposals (AIPs) — the same standards governing all public Google APIs. These principles are universal and apply to any organization building REST, gRPC, or BFF/backend APIs.

When to Use

Invoke this skill when:

  • Reviewing or auditing API endpoint designs (REST or gRPC)
  • Designing new backend service APIs
  • Evaluating BFF (Backend-for-Frontend) architecture boundaries
  • Resolving concurrency issues (TOCTOU, lost updates, race conditions)
  • Choosing between PATCH and PUT, or standard vs custom methods
  • Designing pagination, filtering, or error handling
  • Assessing backward compatibility of API changes

Always cite the AIP number (e.g., "Per AIP-154, ETags must use ABORTED on mismatch") when providing guidance. This gives teams an authoritative, linkable reference at https://google.aip.dev/{number}.

Query Routing

Match the user's concern to the right reference file:

User asks about...Primary referenceKey AIPs
PUT vs PATCH, partial update, field masksstandard-update.mdAIP-134
Race conditions, lost updates, concurrent edits, ETagsetags-and-freshness.mdAIP-154
Retry safety, duplicate requests, request IDsidempotency.mdAIP-155
Page tokens, cursor pagination, filtering, orderingpagination-and-filtering.mdAIP-158, 160
Breaking changes, backward compatibilitycompatibility.mdAIP-192
Alpha/beta/stable, API versioningversioning-and-stability.mdAIP-180, 181
Error codes, error responses, status detailserrors.mdAIP-193
Auth checks, permission denied vs not foundauthorization.mdAIP-211
BFF anti-patterns, layer boundaries, orchestrationbff-architecture.md--
Secrets, passwords, write-only fieldssensitive-fields.mdAIP-147
Soft delete, undelete, resource expiryresource-lifecycle.mdAIP-164, 216
Async tasks, long-running operationslong-running-operations.mdAIP-151
Recurring tasks, scheduled executionjobs.mdAIP-152
Bulk operations, batch requestsbatch-methods.mdAIP-235
Bulk data import/export, data portabilityimport-and-export.mdAIP-153
Dry run, preview, validate-onlychange-validation.mdAIP-163
Many-to-many, multi-parent resourcesresource-association.mdAIP-124
Field defaults, server-modified valuesserver-modified-values.mdAIP-129
Timestamps, durations, date fieldstime-and-duration.mdAIP-142
Unset vs zero, optional primitivesunset-field-values.mdAIP-149
Naming conventions, enums, standard fieldsnaming-and-fields.mdAIP-140, 148
Required/optional/immutable annotationsfield-behavior.mdAIP-203
Wildcard parent, cross-collection queriescross-collection-reads.mdAIP-159
Singleton resources, config objectssingletons.mdAIP-156
Management vs data planeplanes.mdAIP-111
Desired-state, reconciliation, declarativedeclarative-interfaces.mdAIP-128

Core Principles

These five principles form the foundation of well-designed APIs:

#PrincipleKey AIPsOne-liner
1Resource-oriented designAIP-121, 122, 123Model APIs as resource hierarchies with standard methods
2Business operations, not CRUDAIP-136Expose domain actions, not raw table access
3Idempotent, conflict-aware mutationsAIP-154, 155ETags prevent lost updates; request IDs enable safe retries
4Declarative desired-stateAIP-128Clients send intended state; server reconciles
5Explicit contractsAIP-192, 203Field behavior is documented; breaking changes are caught

Standard Methods Quick Reference

Per AIP-121, every resource should expose standard methods where appropriate:

MethodHTTPAIPNotes
GetGET /v1/{name=...}AIP-131Return single resource
ListGET /v1/{parent=...}/resourcesAIP-132Paginated collection; see AIP-158
CreatePOST /v1/{parent=...}/resourcesAIP-133Include {resource}_id for client-assigned names
UpdatePATCH /v1/{resource.name=...}AIP-134Always PATCH, never PUT; use field masks
DeleteDELETE /v1/{name=...}AIP-135Support etag, force, allow_missing

Custom methods use POST /v1/{name=...}:verb (AIP-136) for operations that don't fit standard methods — e.g., :archive, :merge, :approve.

Decision Tables

PATCH vs PUT (AIP-134)

ScenarioRecommendationRationale
Updating specific fieldsPATCH + field maskAdding fields later won't break existing clients
Full resource replacementPATCH with * maskEquivalent to PUT without the compatibility risk
Legacy system requires PUTDiscouragedDocument risks; plan migration to PATCH

Standard vs Custom Method (AIP-136)

OperationMethodReason
Get a resource by nameStandard GetFits AIP-131 exactly
Search with complex filtersStandard List + filterAIP-132 + AIP-160
Archive a resourceCustom :archiveState change, not a data update (AIP-136)
Merge two resourcesCustom :mergeMulti-resource operation with side effects
Approve a workflow stepCustom :approveDomain action, not a field update

Concurrency Control (AIP-154, AIP-155)

ProblemSolutionAIP
TOCTOU race conditionETags — server returns etag; client sends it back on mutationAIP-154
Lost updates from parallel writesETags — ABORTED (409) on mismatchAIP-154
Network retry causes duplicate creationRequest IDs — UUID4 request_id fieldAIP-155
Client unsure if mutation succeededRequest ID + idempotency — same ID returns same resultAIP-155

BFF Architecture Boundaries

A well-designed architecture separates concerns:

LayerOwnsDoes NOT Own
Frontend + BFFUI rendering, session management, request routing, lightweight response shapingBusiness logic, DB connections, data joins, authorization decisions
Backend APIsBusiness operations, domain logic, data integrity, validation, audit loggingUI concerns, session state, frontend formatting
AuthZ serviceCentralized access control, policy enforcementBusiness logic; answers "is this allowed?" not "what should happen?"

Red flags in BFF code: direct database queries, business rule enforcement, data assembly across multiple sources, independent authorization logic.

Audit Checklist

When reviewing an API, check these categories in order. For full details with examples and fix guidance, consult references/audit-checklist.md.

CRITICAL — Concurrency & Safety

  • Mutable resources include etag field (AIP-154)
  • Mutating endpoints accept request_id for idempotency (AIP-155)
  • Update uses PATCH, not PUT (AIP-134)
  • Delete supports etag for protected delete (AIP-135)

HIGH — Resource Design

  • Resources follow hierarchical naming: {parent}/{collection}/{id} (AIP-122)
  • Standard methods used where applicable (AIP-131–135)
  • Custom methods use :verb suffix, not faux resources (AIP-136)
  • Field behavior annotated (required, optional, output_only, immutable) (AIP-203)

MEDIUM — Usability & Evolution

  • List endpoints paginated with page_size + page_token (AIP-158)
  • Errors use standard codes with structured details (AIP-193)
  • Changes assessed for backward compatibility (AIP-192)
  • Long-running operations return Operation object (AIP-151)

LOW — Polish

  • Filtering uses common expression language (AIP-160)
  • Partial responses supported via field masks (AIP-161)
  • Soft delete available where appropriate (AIP-164)

Reference Files

Consult these for detailed guidance, full AIP text, and code examples:

Resource Design

  • references/resource-oriented-design.md — Resource hierarchies, naming, types, standard methods overview (AIP-121, 122, 123)
  • references/resource-association.md — Many-to-many, multi-parent, canonical parent selection (AIP-124)
  • references/planes.md — Management vs data plane, declarative client requirements, consistency rules (AIP-111)
  • references/singletons.md — Single-instance resources, no Create/Delete, config objects (AIP-156)

Standard Methods

  • references/standard-get-list.md — Get and List methods with pagination, filtering, ordering (AIP-131, 132, 158, 160)
  • references/standard-create.md — Create method, user-specified IDs, long-running create (AIP-133)
  • references/standard-update.md — Update/PATCH method, field masks, etags on update, why not PUT (AIP-134)
  • references/standard-delete.md — Delete method, soft delete, cascading delete, force/allow_missing (AIP-135, 164)

Design Patterns

  • references/etags-and-freshness.md — Optimistic concurrency, TOCTOU prevention, strong vs weak etags (AIP-154)
  • references/idempotency.md — Request IDs, safe retries, UUID4 format (AIP-155)
  • references/custom-methods.md — When and how to use custom methods for business operations (AIP-136)
  • references/declarative-interfaces.md — Desired-state pattern, reconciliation, declarative-friendly resources (AIP-128)
  • references/long-running-operations.md — LRO pattern, metadata, parallel operations, expiration (AIP-151)
  • references/jobs.md — Recurring tasks, Run method, Job vs LRO distinction (AIP-152)
  • references/import-and-export.md — Bulk data movement, inline sources, partial failures (AIP-153)
  • references/change-validation.md — Validate-only / dry-run pattern for previewing mutations (AIP-163)
  • references/cross-collection-reads.md — Wildcard parent reads, unique resource lookup, partial failures (AIP-159, 217)

Fields & Data Handling

  • references/naming-and-fields.md — Field naming conventions, standard fields, enums, standardized codes (AIP-140, 148, 126, 143)
  • references/field-behavior.md — Required, optional, output_only, input_only, immutable annotations (AIP-203)
  • references/server-modified-values.md — Field ownership, effective values, normalization rules (AIP-129)
  • references/time-and-duration.md — Timestamp/Duration/Date types, naming conventions (AIP-142)
  • references/unset-field-values.md — Optional primitives, unset vs default value distinction (AIP-149)
  • references/field-masks.md — Partial update and partial response with FieldMask (AIP-161)
  • references/sensitive-fields.md — Write-only secrets, INPUT_ONLY pattern, obfuscated fields (AIP-147)
  • references/repeated-fields.md — List fields, update strategies (read-modify-write vs Add/Remove), sub-resources (AIP-144)
  • references/partial-responses.md — View enums, field mask parameters, BASIC vs FULL views (AIP-157)
  • references/pagination-and-filtering.md — Page tokens, page size, filter expressions, ordering (AIP-158, 160)
  • references/batch-methods.md — Batch get, create, update, delete patterns (AIP-235)

Lifecycle & Errors

  • references/errors.md — Standard error codes, error details, PERMISSION_DENIED vs NOT_FOUND (AIP-193)
  • references/authorization.md — Auth-before-validation rule, information leakage prevention (AIP-211)
  • references/retry-strategy.md — Retryable vs non-retryable error codes, exponential backoff (AIP-194)
  • references/resource-lifecycle.md — State enums, soft delete/undelete, resource expiry/TTL (AIP-216, 164, 214)
  • references/compatibility.md — Backward compatibility rules, breaking vs non-breaking changes (AIP-192)
  • references/versioning-and-stability.md — Alpha/Beta/Stable levels, major versions, compatibility rules (AIP-180, 181, 185)

Architecture

  • references/bff-architecture.md — BFF layer boundaries, anti-patterns, migration guidance
  • references/http-transcoding.md — HTTP/JSON to gRPC mapping, URI conventions (AIP-127)
  • references/audit-checklist.md — Full audit checklist with severity, examples, and fix patterns

الملفات المرفقة

يقرأ النموذج هذه الملفات عند الحاجة أثناء تحميل المهارة. وهي متاحة للقراءة ولا تُنفّذ أبدًا.

الأسئلة الشائعة

ماذا تفعل مهارة الذكاء الاصطناعي Api Review؟

This skill should be used when reviewing API designs, auditing REST or gRPC endpoints, designing backend APIs, evaluating BFF architecture, or discussing API best practices. Also triggers on: "review this API", "API design review", "is this API correct", "REST API audit", "gRPC API review", "PATCH vs PUT", "etag", "idempotency", "pagination design", "API error handling", "backward compatibility", "BFF architecture", "resource-oriented design", "TOCTOU", "race condition", "optimistic concurrency", "field mask", "long-running operation", "custom method", "soft delete", "API naming conventions...

لماذا تستخدم Api Review على TypingMind؟

لأنك تثبّتها مرة واحدة وتستخدمها مع أي نموذج. مهارة Api Review عبارة عن نص Markdown وليست شيفرة خاصة بمزود بعينه، لذا تعمل المهارة نفسها مع GPT-5 أو Claude أو Gemini أو Grok أو نموذج محلي، ويمكنك تبديل النموذج أثناء المحادثة دون تعطّل المهارة. يعمل TypingMind بمفاتيح API الخاصة بك، فتدفع للمزودين مباشرةً بدلًا من اشتراك لكل مقعد، وتبقى مهاراتك ومحادثاتك في مساحة التخزين الخاصة بك.

كيف أثبّت Api Review في TypingMind؟

افتح الإضافات → المهارات → التثبيت من GitHub في TypingMind والصق https://github.com/robbyt/claude-skills/tree/main/plugins/api-design/skills/api-review. يقرأ TypingMind ملف SKILL.md الخاص بها، ويجمع ملفاتها ويثبّتها كمهارة يمكنك تفعيلها لكل محادثة على حدة.

ما نماذج الذكاء الاصطناعي التي يمكنها استخدام Api Review؟

أي نموذج تربطه في TypingMind. مهارات الذكاء الاصطناعي عبارة عن تعليمات Markdown وليست شيفرة خاصة بمزود بعينه، لذا يمكن لكل من GPT وClaude وGemini وGrok والنماذج المحلية تحميل هذه المهارة عندما يتوافق الطلب معها.

كم نموذج ذكاء اصطناعي يمكنني استخدامه مع Api Review؟

أي عدد تريده. ما دام النموذج يدعم المهارات، يمكنك استخدام Api Review معه، سواء كان GPT أو Claude أو Gemini أو Grok أو DeepSeek أو Mistral أو Llama أو غيرها، وكل ذلك على TypingMind باستخدام مفاتيح API الخاصة بك.

هل مهارة الذكاء الاصطناعي Api Review مجانية؟

نشرها robbyt على GitHub. راجع المستودع للاطلاع على شروط الترخيص. لا تدفع إلا لمزود الذكاء الاصطناعي الخاص بك مقابل التوكنات التي تستخدمها.

ما هي مهارات الذكاء الاصطناعي؟

مهارة الذكاء الاصطناعي حزمة تعليمات قابلة لإعادة الاستخدام تعلّم نموذج الذكاء الاصطناعي كيفية تنفيذ مهمة محددة. وتتبع تنسيق Agent Skills المفتوح: ملف SKILL.md يتضمن اسمًا ووصفًا، إلى جانب أي نصوص برمجية أو قوالب أو ملفات مرجعية قد يحتاج إليها النموذج. لا يقرأ النموذج التعليمات إلا عندما يتوافق طلبك مع المهارة، لذا لا تترتب على المهارة المثبتة أي تكلفة حتى تُستخدم.

كيف تختلف مهارات الذكاء الاصطناعي عن الإضافات أو موصلات MCP؟

تمنح الإضافة أو موصل MCP النموذج أدوات جديدة يمكنه استدعاؤها، وهي شيفرة تُنفَّذ في مكان ما وتُرجع نتيجة. أما مهارة الذكاء الاصطناعي فتزوّد النموذج بالمعرفة ومنهجية العمل: كيفية التعامل مع مهمة، والخطوات التي ينبغي اتباعها، وما ينبغي أن تكون عليه المخرجات الجيدة. المهارات عبارة عن نصوص Markdown، لذا لا تحتاج إلى خادم أو مفتاح API أو بيئة تشغيل، وتعمل مع أي نموذج.

عرض الكل

أنشئ مساحة عملك للذكاء الاصطناعي الآن

اشترك في نشرتنا البريدية لتصلك أخبار الميزات الجديدة والهدايا القادمة 👇