मुख्य सामग्री पर जाएँ

फ़्लैग: एक निर्णय

फ़ीचर फ़्लैग यूज़र स्टेट के विरुद्ध मूल्यांकित एक निर्णय है। टार्गेटिंग उस स्टेट पर शर्तों का समूह है, जिन्हें फ़्लैग पूछे जाने के क्षण जाँचा जाता है।

At a glance

Host
https://api.prodantix.com
Read
GET /v1/flags, GET /v1/flags/snapshot
Write
upsertFlag, archiveFlag over GraphQL
Live updates
flagChange on the project room
Auth
Project key to read, access token to write
  • लाइव यूज़र स्टेट पर रीयल-टाइम टार्गेटिंग
  • पूछते ही तय होता है, किसी संग्रहीत सूची से नहीं पढ़ा जाता
  • रोलआउट और एक्सपेरिमेंट उसी सत्य स्रोत पर मापे जाते हैं

यह कैसे काम करता है

A flag is evaluated against the user state currently on file for a distinct id. Rules are ordered; the first match wins, and a flag with no matching rule falls back to its default. Evaluation is server-side by default, so a rule change takes effect without a client release.

इसे कहाँ से एक्सेस करें

SurfaceOperation
RESTGET /v1/flags · GET /v1/flags/snapshot
GraphQLflags query · upsertFlag, archiveFlag mutations
RealtimeflagChange on a project room
MCPprodantix.flags.list · .upsert · .archive

उदाहरण

curl "https://api.prodantix.com/v1/flags?distinct_id=u_8f3a" \
  -H "Authorization: Bearer $PRODANTIX_KEY"

Evaluating locally

For latency-sensitive paths, fetch the whole ruleset once and evaluate in-process. Snapshot responses carry Cache-Control: public, max-age=30, stale-while-revalidate=300.

JSON
{
  "flags": [
    {
      "key": "new-checkout",
      "enabled": true,
      "rules": [
        { "property": "plan", "operator": "in", "values": ["pro", "scale"] }
      ]
    }
  ]
}