backend-developer
БесплатноБез исполняемых скриптовНе проверенUse this skill when working on backend microservices — implementing GraphQL APIs with HotChocolate, writing MassTransit consumers/publishers, building MongoDB…
от gabrielmoreira★ 23 звезды на GitHubОб этом скилле
Backend Developer
Guide for developing backend microservices. Covers domain-specific patterns, conventions, and internal libraries that the AI agent does not inherently know.
Scope: This skill covers project-specific patterns and conventions only. For general C# best practices, refer to the CSharpExpert agent. For testing conventions, follow
tests.instructions.md.
Architecture Quick Reference
Architecture, layer definitions, dependency rules, and coding standards are defined in general.instructions.md (always loaded). The following covers domain-specific patterns only.
Known domains:
API Stitching Layer
src/Api/ is the HotChocolate Stitching gateway. It stitches domain GraphQL schemas together and uses QueryDelegationRewriterBase to transform queries between schemas.
// Example: src/Api/src/Host/Addresses/AddressQueryRewriter.cs
public class AddressQueryRewriter : QueryDelegationRewriterBase
{
// Rewrites delegated queries for the stitched schema
}
Never add business logic to the Api layer — it only delegates and rewrites.
HotChocolate GraphQL Patterns
ObjectType Definitions
Use class-based type definitions extending ObjectType<T>:
public class MyEntityType : ObjectType<MyEntity>
{
protected override void Configure(IObjectTypeDescriptor<MyEntity> descriptor)
{
descriptor.Field(x => x.Id).Type<NonNullType<IdType>>();
}
}
TypeExtensions
Extend existing types without modifying their original definition. Use [ExtendObjectType]:
[ExtendObjectType(typeof(ParentEntity))]
public class ChildTypeExtensions
{
public async Task<ChildResult> GetChildData(
[Parent] ParentEntity parent,
[Service] IChildService service,
CancellationToken cancellationToken)
{
return await service.GetByParentIdAsync(parent.Id, cancellationToken);
}
}
Field Middleware
Chain middleware on fields using FieldDelegate and IMiddlewareContext:
public static class ComputeMiddleware
{
public static FieldDelegate Create(FieldDelegate next)
{
return async context =>
{
await next(context);
object? result = context.Result;
// Transform result
context.Result = transformed;
};
}
}
Pass data between middleware/resolvers via ScopedContextData with IImmutableStack<object>.
DataLoaders
Use GreenDonut BatchDataLoader<TKey, TValue> for batching and caching. Naming convention: {Entity}By{Key}DataLoader. Inject IMyRepository + IBatchScheduler in the constructor, call base(batchScheduler, options), and override LoadBatchAsync.
Translation & Localization
Consultation domain uses HotChocolate.Extensions.Translation with HeaderLocalization:
services.AddTranslation()
.AddHeaderLocalization(options => { /* configure */ });
Mutation Conventions
Use HotChocolate's built-in mutation conventions. Prefer implementation-first over schema-first. Use dedicated Input/Output types rather than separate parameters.
MassTransit Consumer Patterns
Standard Consumer
Mark consumers sealed. Use primary constructors for DI. Every consumer must include OpenTelemetry tracing and source-generated logging:
public sealed class ContractDeletedConsumer(
IConsultationUpdater updater) : IConsumer<ContractDeleted>
{
public async Task Consume(ConsumeContext<ContractDeleted> context)
{
using Activity? activity = App.ActivitySource.StartActivity();
App.Log.ConsumingContractDeleted(context.Message.ContractId);
await updater.DeleteByContractIdAsync(
context.Message.ContractId,
context.CancellationToken);
}
}
Abstract Base Consumer
For shared consumer logic across message types, use a generic abstract base:
public abstract class CustomerUpdateMessageConsumerBase<TMessage>
: IConsumer<TMessage> where TMessage : class
{
public async Task Consume(ConsumeContext<TMessage> context)
{
using Activity? activity = App.ActivitySource.StartActivity();
// Shared processing logic
await ProcessAsync(context.Message, context.CancellationToken);
}
protected abstract Task ProcessAsync(TMessage message, CancellationToken cancellationToken);
}
Consumer Organization
Organize consumers in Core/Messaging/Consumers/ by category:
E2E/CustomerUpdates/— End-to-end customer update eventsFuse/— Fuse-specific events (invites, codes)FusionIdentity/— Identity eventsIntegration/— External integration events
Request-Response Pattern
For consumers that need to respond:
await context.RespondAsync(new AdminResponse { /* ... */ });
Consumer Anti-Patterns
- Never catch and swallow exceptions in co
Установить backend-developer в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
Без ограничений — скилл может использовать любой инструмент.
FAQ
Что делает скилл backend-developer?
Use this skill when working on backend microservices — implementing GraphQL APIs with HotChocolate, writing MassTransit consumers/publishers, building MongoDB data access layers, configuring service startup, integrating data pipelines, or adding observability with OpenTelemetry. Triggers on: GraphQL resolvers, ObjectType, TypeExtensions, QueryRewriter, field middleware, DataLoaders, MassTransit IConsumer, Azure Service Bus, MongoDB repositories, data pipeline sender/receiver, service startup configuration, or any backend domain service work.
Как установить скилл backend-developer?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл backend-developer запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
skill-creator
Create new skills, modify and improve existing skills, and measure skill performance. Use when users want to create a skill from scratch, edit, or optimize an…
от Anthropicdiscernment-nudge
After you give a substantive answer or draft that the user may act on — advice or recommendations, drafted artifacts such as goals, plans, pitches, proposals…
от Anthropicdata-consolidate
Joins the plant's scheduled exports and connector data into one working dataset — ERP items (NetSuite or Infor M3), sales orders, production work orders…
от Anthropicinspection-to-capa
Runs the quality chain end to end: writes the nonconformance against the requirement it violates, searches history at the moment of writing to say whether…
от Anthropic