Skip to main content
GET
/
v1
/
flags
/
{flag}
/
rules
/
{rule}
Get Rule
curl --request GET \
  --url https://flags.eu.confidence.dev/v1/flags/{flag}/rules/{rule} \
  --header 'Authorization: Bearer <token>'
{
  "segment": "<string>",
  "assignmentSpec": {},
  "usageMetadata": {},
  "enabled": true,
  "createTime": {},
  "updateTime": {},
  "creator": "<string>",
  "updater": "<string>",
  "name": "<string>",
  "description": "<string>",
  "targetingKeySelector": "<string>",
  "environments": [
    "<string>"
  ],
  "labels": [
    {}
  ],
  "materializationSpec": {}
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Path Parameters

flag
string
required
rule
string
required

Response

200 - application/json

OK

A rule that decides how a subset of the flags variants are assigned.

segment
string
required

A reference to the segment that this rule uses to specify entities that are eligible.

assignmentSpec
object
required

Specification of how an entity should be randomly assigned to values.

usageMetadata
object
required

Metadata about how the flag has been resolved.

enabled
boolean
required

Decides if the rule should be enabled for resolve or not.

createTime
object
required

Time when the rule was first created.

updateTime
object
required

Time when the flag was last updated.

creator
string
required

Reference to the identity that created this rule.

updater
string
required

Reference to the identity that last updated this rule.

name
string

The resource name of the rule. For example: flags/my-flag/rules/1bhq4c2zqigdzqg6ufni

description
string

A description for the rule.

targetingKeySelector
string

Selector of what key to randomize on from the evaluation context. "targeting_key" is the default if not specified

environments
string[]

List of environments this rule is enabled for. If this list is empty, the rule is enabled for all environments.

labels
object[]

General set of labels for this resource.

materializationSpec
object

Specifies if materializations are written to/read from