keyraft_client 0.1.0
keyraft_client: ^0.1.0 copied to clipboard
Dart SDK for Keyraft — lightweight configuration and secrets management (server v0.3.0).
Keyraft Dart SDK #
Dart client for Keyraft — compatible with server v0.3.0.
Install #
dart pub add keyraft_client
Or in pubspec.yaml:
dependencies:
keyraft_client: ^0.1.0
Package: pub.dev/packages/keyraft_client
Quick start #
import 'package:keyraft_client/keyraft_client.dart';
final client = KeyraftClient(
baseUrl: 'http://localhost:7200',
token: Platform.environment['KEYRAFT_TOKEN'],
);
await client.set('myapp/prod', 'DATABASE_URL', 'postgres://...', type: 'secret');
final entry = await client.get('myapp/prod', 'DATABASE_URL');
API coverage #
| Area | Methods |
|---|---|
| Health | health(), metrics() |
| KV | set(), get(), delete(), list(), listVersions() |
| Watch | watch(), watchStream() |
| Namespaces | listNamespaces(), getNamespace(), deleteNamespace() |
| Auth | me(), createToken(), listTokens(), revokeToken() |
| Roles | listRoles(), getRole() |
| Audit | audit() |
Uses dart:io HttpClient only — no third-party HTTP deps.