custom-plugin-flutter-skill-backend
1500+ lines of backend integration mastery - REST APIs, GraphQL, WebSockets, authentication, Firebase, error handling with production-ready code examples.
Best use case
custom-plugin-flutter-skill-backend is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
1500+ lines of backend integration mastery - REST APIs, GraphQL, WebSockets, authentication, Firebase, error handling with production-ready code examples.
Teams using custom-plugin-flutter-skill-backend should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/custom-plugin-flutter-skill-backend/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How custom-plugin-flutter-skill-backend Compares
| Feature / Agent | custom-plugin-flutter-skill-backend | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
1500+ lines of backend integration mastery - REST APIs, GraphQL, WebSockets, authentication, Firebase, error handling with production-ready code examples.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
SKILL.md Source
# custom-plugin-flutter: Backend Integration Skill
## Quick Start - Dio Client
```dart
final dio = Dio(BaseOptions(
baseUrl: 'https://api.example.com',
connectTimeout: Duration(seconds: 10),
receiveTimeout: Duration(seconds: 10),
));
// Add logging interceptor
dio.interceptors.add(LoggingInterceptor());
// Make request
Future<User> getUser(String id) async {
try {
final response = await dio.get('/users/$id');
return User.fromJson(response.data);
} on DioException catch (e) {
throw ApiException(e.message ?? 'Unknown error');
}
}
```
## 1. HTTP Clients
**HTTP Package (Lightweight):**
```dart
import 'package:http/http.dart' as http;
Future<User> getUser(String id) async {
final response = await http.get(
Uri.parse('https://api.example.com/users/$id'),
headers: {'Authorization': 'Bearer $token'},
);
if (response.statusCode == 200) {
return User.fromJson(jsonDecode(response.body));
} else {
throw Exception('Failed to load user');
}
}
```
**Dio Framework (Production):**
```dart
final dio = Dio(BaseOptions(
baseUrl: 'https://api.example.com',
connectTimeout: Duration(seconds: 10),
receiveTimeout: Duration(seconds: 10),
));
// Add interceptors
dio.interceptors.add(
InterceptorsWrapper(
onRequest: (options, handler) async {
options.headers['Authorization'] = 'Bearer $token';
return handler.next(options);
},
onError: (error, handler) async {
if (error.response?.statusCode == 401) {
await _refreshToken();
}
return handler.next(error);
},
),
);
// Use Dio
final response = await dio.get('/users/123');
```
## 2. REST API Patterns
**Repository Pattern:**
```dart
abstract class UserRepository {
Future<User> getUser(String id);
Future<List<User>> getAllUsers();
Future<void> createUser(User user);
}
class UserRepositoryImpl implements UserRepository {
final Dio _dio;
UserRepositoryImpl(this._dio);
@override
Future<User> getUser(String id) async {
try {
final response = await _dio.get('/users/$id');
return User.fromJson(response.data);
} on DioException catch (e) {
throw _handleError(e);
}
}
@override
Future<List<User>> getAllUsers() async {
try {
final response = await _dio.get('/users');
return (response.data as List)
.map((u) => User.fromJson(u))
.toList();
} on DioException catch (e) {
throw _handleError(e);
}
}
Exception _handleError(DioException e) {
if (e.type == DioExceptionType.connectionTimeout) {
return TimeoutException('Connection timeout');
} else if (e.response?.statusCode == 401) {
return UnauthorizedException('Unauthorized');
} else if (e.response?.statusCode == 500) {
return ServerException('Server error');
}
return ApiException('Unknown error');
}
}
```
## 3. GraphQL Integration
```dart
import 'package:graphql/client.dart';
final graphQLClient = GraphQLClient(
cache: GraphQLCache(),
link: HttpLink('https://api.example.com/graphql'),
);
// Query
Future<User> getUser(String id) async {
final result = await graphQLClient.query(
QueryOptions(
document: gql('''
query GetUser(\$id: ID!) {
user(id: \$id) {
id
name
email
}
}
'''),
variables: {'id': id},
),
);
if (result.hasException) {
throw Exception(result.exception);
}
return User.fromJson(result.data!['user']);
}
// Mutation
Future<void> updateUser(User user) async {
final result = await graphQLClient.mutate(
MutationOptions(
document: gql('''
mutation UpdateUser(\$id: ID!, \$name: String!) {
updateUser(id: \$id, name: \$name) {
id
name
}
}
'''),
variables: {'id': user.id, 'name': user.name},
),
);
if (result.hasException) {
throw Exception(result.exception);
}
}
```
## 4. Authentication
**JWT Token Management:**
```dart
class AuthService {
final Dio _dio;
String? _accessToken;
String? _refreshToken;
AuthService(this._dio);
Future<void> login(String email, String password) async {
try {
final response = await _dio.post('/auth/login', data: {
'email': email,
'password': password,
});
_accessToken = response.data['accessToken'];
_refreshToken = response.data['refreshToken'];
await _secureStorage.write(
key: 'accessToken',
value: _accessToken!,
);
await _secureStorage.write(
key: 'refreshToken',
value: _refreshToken!,
);
} on DioException catch (e) {
throw _handleError(e);
}
}
Future<String> getValidToken() async {
if (_isTokenExpired(_accessToken)) {
await _refreshAccessToken();
}
return _accessToken!;
}
Future<void> _refreshAccessToken() async {
try {
final response = await _dio.post(
'/auth/refresh',
data: {'refreshToken': _refreshToken},
);
_accessToken = response.data['accessToken'];
await _secureStorage.write(
key: 'accessToken',
value: _accessToken!,
);
} catch (e) {
await logout();
rethrow;
}
}
bool _isTokenExpired(String? token) {
if (token == null) return true;
final decoded = jwt.decode(token);
final expiration = DateTime.fromMillisecondsSinceEpoch(
decoded['exp'] * 1000,
);
return DateTime.now().isAfter(expiration);
}
Future<void> logout() async {
_accessToken = null;
_refreshToken = null;
await _secureStorage.deleteAll();
}
}
```
## 5. Error Handling
**Custom Exceptions:**
```dart
abstract class ApiException implements Exception {
final String message;
ApiException(this.message);
}
class NetworkException extends ApiException {
NetworkException(String message) : super('Network Error: $message');
}
class UnauthorizedException extends ApiException {
UnauthorizedException(String message) : super('Unauthorized: $message');
}
class ServerException extends ApiException {
ServerException(String message) : super('Server Error: $message');
}
class ValidationException extends ApiException {
final Map<String, String> errors;
ValidationException(this.errors) : super('Validation Error');
}
```
## 6. Firebase Integration
```dart
import 'package:cloud_firestore/cloud_firestore.dart';
class FirebaseUserRepository {
final firestore = FirebaseFirestore.instance;
Future<User?> getUser(String id) async {
try {
final doc = await firestore.collection('users').doc(id).get();
if (!doc.exists) return null;
return User.fromJson(doc.data()!);
} catch (e) {
throw Exception('Failed to get user: $e');
}
}
Stream<User?> watchUser(String id) {
return firestore
.collection('users')
.doc(id)
.snapshots()
.map((doc) => doc.exists ? User.fromJson(doc.data()!) : null);
}
Future<void> updateUser(User user) async {
await firestore.collection('users').doc(user.id).update(
user.toJson(),
);
}
Future<void> createUser(User user) async {
await firestore.collection('users').doc(user.id).set(
user.toJson(),
);
}
}
```
## 7. Retry Logic
```dart
Future<T> withRetry<T>(
Future<T> Function() operation, {
int maxRetries = 3,
Duration initialDelay = const Duration(milliseconds: 100),
}) async {
int retries = 0;
Duration delay = initialDelay;
while (true) {
try {
return await operation();
} catch (e) {
if (retries >= maxRetries || !_isRetryable(e)) {
rethrow;
}
await Future.delayed(delay);
delay = Duration(milliseconds: (delay.inMilliseconds * 2).toInt());
retries++;
}
}
}
bool _isRetryable(dynamic error) {
if (error is! DioException) return false;
return error.type == DioExceptionType.connectionTimeout ||
error.type == DioExceptionType.receiveTimeout ||
(error.response?.statusCode ?? 0) >= 500;
}
```
---
**Master backend integration for robust Flutter applications.**Related Skills
datasette-plugins
Writing Datasette plugins using Python and the pluggy plugin system. Use when Claude needs to: (1) Create a new Datasette plugin, (2) Implement plugin hooks like prepare_connection, register_routes, render_cell, etc., (3) Add custom SQL functions, (4) Create custom output renderers, (5) Add authentication or permissions logic, (6) Extend Datasette's UI with menus, actions, or templates, (7) Package a plugin for distribution on PyPI
data-engineering-backend-architect
Expert backend architect specializing in scalable API design, microservices architecture, and distributed systems. Masters REST/GraphQL/gRPC APIs, event-driven architectures, service mesh patterns, and modern backend frameworks. Handles service boundary definition, inter-service communication, resilience patterns, and observability. Use PROACTIVELY when creating new backend services or APIs. Use when: the task directly matches backend architect responsibilities within plugin data-engineering. Do not use when: a more specific framework or task-focused skill is clearly a better match.
customize
Add new capabilities or modify MicroClaw behavior. Use when user wants to add channels (Telegram, Slack, email input), change triggers, add integrations, modify the router, or make any other customizations. This is an interactive skill that asks questions to understand what the user wants.
customer-meeting-intelligence
Comprehensive meeting intelligence system for customer-facing calls. Provides proactive pre-call briefings with account context, post-meeting action item extraction with draft approval, and thread continuity. Use when you need: (1) automated morning briefings for customer meetings, (2) post-meeting action item extraction from Fellow.ai and Gmail Gemini notes, (3) draft approval workflow before posting meeting notes, (4) customer context gathering including billing, support tickets, and communication history, (5) meeting follow-up automation with account intelligence.
custom-project-standards
Hệ thống tiêu chuẩn dự án đa năng (Standard Platform). Hỗ trợ Frontend, Backend, DevOps với nhiều tùy chọn ngôn ngữ/framework.
claude-flow-hook-customizing
Use this skill when creating, optimizing, or maintaining claude hooks.
cermont.backend.prisma-v7
Expert guidance for Prisma ORM v7 (7.0+). Use when working with Prisma schema files, migrations, Prisma Client queries, database setup. Covers ESM modules, driver adapters, prisma.config.ts, Rust-free client.
building-streamlit-custom-components-v2
Builds bidirectional Streamlit Custom Components v2 (CCv2) using `st.components.v2.component`. Use when authoring inline HTML/CSS/JS components or packaged components (manifest `asset_dir`, js/css globs), wiring state/trigger callbacks, theming via `--st-*` CSS variables, or bundling with Vite / `component-template` v2.
backendless-automation
Automate Backendless tasks via Rube MCP (Composio). Always search tools first for current schemas.
backend-ultimate
Ultimate 25+ years expert-level backend skill covering FastAPI, Express, Node.js, Next.js with TypeScript. Includes ALL databases (PostgreSQL, MongoDB, Redis, Elasticsearch), ALL features (REST, GraphQL, WebSockets, gRPC, Message Queues), comprehensive security hardening (XSS, CSRF, SQL injection, authentication, authorization, rate limiting), complete performance optimization (caching, database tuning, load balancing), ALL deployment strategies (Docker, Kubernetes, CI/CD), advanced patterns (microservices, event-driven, saga, CQRS), ALL use cases (e-commerce, SaaS, real-time, high-traffic), complete testing (unit, integration, E2E, load, security). Route protection, middleware, authentication implementation in PERFECTION. Use for ANY backend system requiring enterprise-grade security, performance, scalability, and architectural excellence.
backend-testing
Write comprehensive backend tests including unit tests, integration tests, and API tests. Use when testing REST APIs, database operations, authentication flows, or business logic. Handles Jest, Pytest, Mocha, testing strategies, mocking, and test coverage.
backend-skills
Master Node.js, Express, PHP, Laravel, Java, Spring Boot, API design, and database integration. Build scalable APIs and server applications.