bmob-database-flutter

bmob-database-flutter is a skill for Claude Code, Codex from bmob/agent-skills. It costs 185 tokens per session (2,528 once invoked), scanned A, original, MIT.

A Flutter and Dart guide for using Bmob, a hosted NoSQL database service, through its official Flutter plugin. Flutter is a toolkit for building apps from one Dart codebase for multiple platforms.

In plain words
What is it for?
Use it to add Bmob to a Flutter project, define models, query and save records, manage users, files, relations, locations, and access rules, and convert database errors into usable error details.
Why use it?
It explains how to initialize the plugin, represent tables as Dart classes, handle asynchronous results, and keep credentials and server-managed fields handled correctly. This avoids setup and data-conversion mistakes in Flutter apps.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/bmob/agent-skills/bmob-database-flutter
Any agent
npx skills add bmob/agent-skills --skill bmob-database-flutter
Clone the repo
git clone --depth 1 https://github.com/bmob/agent-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for bmob-database-flutter

README.md
[![agentmods](https://agentmods.dev/badge/skills/bmob/agent-skills/bmob-database-flutter.svg)](https://agentmods.dev/skills/bmob/agent-skills/bmob-database-flutter)
Your own site
<a href="https://agentmods.dev/skills/bmob/agent-skills/bmob-database-flutter"><img src="https://agentmods.dev/badge/skills/bmob/agent-skills/bmob-database-flutter.svg" alt="Measured on agentmods" height="20"></a>
Per session 185 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,528 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00185 $0.02528
Opus 5 $0.00093 $0.01264
Sonnet 5 $0.00037 $0.00506
Haiku 4.5 $0.00018 $0.00253

Measured 5d ago against content hash 0bbf159379ad, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

bmob-database-flutter scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (references/snippets/flutter-index--安装-01.sh), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/bmob-database-flutter/SKILL.md · 242 lines

How it starts

The opening of the file, as written. The whole thing — 242 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Bmob Database — Flutter / Dart SDK

官方 Flutter 插件 bmob_plugin(源码 bmob-flutter-sdk/data_plugin)。数据模型 继承 BmobObject + JSON 序列化(与 Android 类似),查询用泛型 BmobQuery<T>,异步返回 Future + .then / .catchError

完整 API 以 BmobDocs Flutter 文档 为准;agent 可直接 WebFetch metadata.docs_raw

核心原则

1. 安装与引用

flutter pub add bmob_plugin
import 'package:bmob_plugin/bmob_plugin.dart';

2. 初始化 — 控制台 → 设置 → 应用密钥 → Secret KeyAPI 安全码不要在客户端填 masterKey(第三个可选参数仅服务端场景)。

// main() 或 App 启动最早处
Bmob.initialize(secretKey, apiSafe);
// 不推荐:Bmob.initialize(secretKey, apiSafe, masterKey);

3. 上线换备案域名resetDomain 必须在 initialize 之前(开发期内置测试域名有请求次数限制):

Bmob.resetDomain("http://api.yourdomain.com");
Bmob.initialize(secretKey, apiSafe);

4. 自定义表模型 — 每张业务表一个 Dart 类 extends BmobObject,并实现 fromJson / toJson(见 references/model-and-init.md)。表名默认与类名一致(如 Blog → 表 Blog)。

5. 错误处理 — 统一用 BmobError.convert(e)code / error

}).catchError((e) {
  final err = BmobError.convert(e);
  print('${err.code}: ${err.error}');
});

6. 保留字段objectIdcreatedAtupdatedAtACL 由 SDK / 服务端维护;业务代码在更新 / 删除时必须设置 objectId

安全清单

  • 客户端不要传 Master KeyBmob.initialize 第三参数。
  • Secret Key / API 安全码--dart-define.env + flutter_dotenv 或 CI 注入,不要 commit 进 git。
  • release 前 resetDomain 为备案域名,且顺序在 initialize 之前。
  • 写入的表必须配 ACLblog.setAcl(bmobAcl)),否则任意用户可改任意行。
  • Android 文件上传 / 下载 需先适配存储权限(见官方文档「文件操作」)。
  • 实时监听 RealTimeDataManager 回调里 data.dataMap,不要直接当 Blog 用。

常见问题

跨平台 Q&A:shared/faq.md(含 Flutter 路由说明)。

反模式

shared/anti-patterns.md。本端重点:客户端勿传 masterKey;实时回调勿直接把 Map 当 model。

Read the full file on GitHub · 242 lines

Files

What ships with it

60 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 242 lines · 185 tokens per session scan A 0bbf159379ad

Subscribe to this mod's changes

bmob-database-flutter is a skill published in the GitHub repository bmob/agent-skills (3 stars, last pushed 2d ago), licensed MIT. It adds 185 tokens to every session and 2,528 once invoked, about $0.0009 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

sf-schema

Scaffold custom objects, fields, validation rules, permission sets, and other schema metadata as SFDX source XML. Use when asked to create objects, custom fields, permission sets, validation rules, or generate metadata XML. Activate on mentions of "custom object", "custom field", "permission set", "validation rule"…

Clientell-Ai/salesforce-skills · 86 tokens

sf-soql

Build and optimize SOQL queries including relationship queries, aggregate functions, polymorphic TYPEOF, and selective filters. Use when asked to write queries, debug slow queries, optimize existing SOQL, or enforce query security. Activate on mentions of "SOQL", "query", "SELECT", "WHERE", "aggregate", "relationship…

Clientell-Ai/salesforce-skills · 78 tokens

core-data

Build, review, or improve Core Data persistence in apps that have not adopted SwiftData. Use when working with NSManagedObject subclasses, NSFetchedResultsController for list-driven UI, NSBatchInsertRequest / NSBatchDeleteRequest / NSBatchUpdateRequest for bulk operations, NSPersistentHistoryChangeRequest for…

dpearson2699/swift-ios-skills · 130 tokens

sf-data

Handle Salesforce data operations including data migration, sandbox seeding, bulk data loading, data export, and data cleanup. Use when asked about data migration, sandbox seeding, bulk data loading, CSV import/export, or moving data between orgs. Activate on mentions of "data migration", "sandbox seed", "bulk load"…

Clientell-Ai/salesforce-skills · 87 tokens

swiftdata

Implement, review, or improve data persistence using SwiftData. Use when defining @Model classes with @Attribute, @Relationship, @Transient, #Unique, or #Index; when querying with @Query, #Predicate, FetchDescriptor, or SortDescriptor; when configuring ModelContainer and ModelContext for SwiftUI or background work…

dpearson2699/swift-ios-skills · 106 tokens

swiftdata-persistence

Design and review SwiftData schemas, queries, migrations, isolation, CloudKit assumptions, offline behavior, and deterministic persistence tests.

memi-design/design-skills · 30 tokens