Flagr Client for Dart

Flagr is a feature flagging, A/B testing and dynamic configuration microservice. The base path for all the APIs is "/api/v1".

version license likes sdk-version

MIT codecov build check

Requirements

Dart 1.20.0 or later OR Flutter 0.0.20 or later

Installation & Usage

dependencies:
  flagr: ^1.1.8

Getting Started

Please follow the installation procedure and then run the following:

import 'package:flagr/api.dart';


var api_instance = new ConstraintApi();
var flagID = 789; // int | numeric ID of the flag
var segmentID = 789; // int | numeric ID of the segment
var body = new CreateConstraintRequest(); // CreateConstraintRequest | create a constraint

try {
    var result = api_instance.createConstraint(flagID, segmentID, body);
    print(result);
} catch (e) {
    print("Exception when calling ConstraintApi->createConstraint: $e\n");
}

Documentation for API Endpoints

All URIs are relative to http://localhost/api/v1

ClassMethodHTTP requestDescription
ConstraintApicreateConstraintpost /flags/{flagID}/segments/{segmentID}/constraints
ConstraintApideleteConstraintdelete /flags/{flagID}/segments/{segmentID}/constraints/{constraintID}
ConstraintApifindConstraintsget /flags/{flagID}/segments/{segmentID}/constraints
ConstraintApiputConstraintput /flags/{flagID}/segments/{segmentID}/constraints/{constraintID}
DistributionApifindDistributionsget /flags/{flagID}/segments/{segmentID}/distributions
DistributionApiputDistributionsput /flags/{flagID}/segments/{segmentID}/distributions
EvaluationApipostEvaluationpost /evaluation
EvaluationApipostEvaluationBatchpost /evaluation/batch
ExportApigetExportEvalCacheJSONget /export/eval_cache/json
ExportApigetExportSqliteget /export/sqlite
FlagApicreateFlagpost /flags
FlagApideleteFlagdelete /flags/{flagID}
FlagApifindFlagsget /flags
FlagApigetFlagget /flags/{flagID}
FlagApigetFlagEntityTypesget /flags/entity_types
FlagApigetFlagSnapshotsget /flags/{flagID}/snapshots
FlagApiputFlagput /flags/{flagID}
FlagApisetFlagEnabledput /flags/{flagID}/enabled
HealthApigetHealthget /health
SegmentApicreateSegmentpost /flags/{flagID}/segments
SegmentApideleteSegmentdelete /flags/{flagID}/segments/{segmentID}
SegmentApifindSegmentsget /flags/{flagID}/segments
SegmentApiputSegmentput /flags/{flagID}/segments/{segmentID}
SegmentApiputSegmentsReorderput /flags/{flagID}/segments/reorder
VariantApicreateVariantpost /flags/{flagID}/variants
VariantApideleteVariantdelete /flags/{flagID}/variants/{variantID}
VariantApifindVariantsget /flags/{flagID}/variants
VariantApiputVariantput /flags/{flagID}/variants/{variantID}

Documentation For Models

Documentation For Authorization

All endpoints do not require authorization.

Author

Minsu Lee ( amond@amond.net )

Libraries

api_key_auth
api_util
auth
basic_auth
constraint
constraint_api
create_constraint_request
create_flag_request
create_segment_request
create_variant_request
distribution
distribution_api
error
eval_context
eval_debug_log
eval_result
evaluation_api
evaluation_batch_request
evaluation_batch_response
evaluation_entity
export_api
flag
flag_api
flag_snapshot
flagr
flagr.api
health
health_api
local_date_serializer
oauth
put_distributions_request
put_flag_request
put_segment_reorder_request
put_segment_request
put_variant_request
segment
segment_api
segment_debug_log
serializers
set_flag_enabled_request
variant
variant_api