For AI agents: a documentation index is available at the root level at /llms.txt and /llms-full.txt. Append /llms.txt to any URL for a page-level index, or .md for the markdown version of any page.
Sign inTry it free
DocsGuidesSDKsIntegrationsAPI docsTutorialsFlagship blog
DocsGuidesSDKsIntegrationsAPI docsTutorialsFlagship blog
  • REST API overview
    • Access Tokens
    • Account Members
    • Account Usage Beta
    • AI Configs
    • Announcements
    • Applications Beta
    • Approvals
    • Approvals Beta
    • Audit Log
    • Code References
    • Contexts
    • Context Settings
    • Custom Roles
    • Data Export Destinations
    • Environments
    • Experiments
    • Feature Flags
    • Feature Flags Beta
    • Flag Import Configurations Beta
    • Flag Links Beta
    • Flag Triggers
    • Follow Flags
    • Holdouts Beta
      • POSTCreate holdout
      • GETGet all holdouts
      • GETGet holdout
      • GETGet Holdout by Id
      • PATCHPatch holdout
    • Insights Charts Beta
    • Insights Deployments Beta
    • Insights Flag Events Beta
    • Insights Pull Requests Beta
    • Insights Repositories Beta
    • Insights Scores Beta
    • Integration Audit Log Subscriptions
    • Integration Delivery Configurations Beta
    • Integrations Beta
    • Layers
    • Metrics
    • Metrics Beta
    • OAuth2 Clients
    • Persistent Store Integrations Beta
    • Projects
    • Relay Proxy Configurations
    • Release Pipelines Beta
    • Releases Beta
    • Scheduled Changes
    • Segments
    • Tags
    • Teams
    • Teams Beta
    • Users
    • Users Beta
    • User Settings
    • Views Beta
    • Webhooks
    • Workflows
    • Workflow Templates
    • Other
Sign inTry it free
LogoLogo
REST API overviewHoldouts Beta

Get holdout

GET
/api/v2/projects/:projectKey/environments/:environmentKey/holdouts/:holdoutKey
GET
/api/v2/projects/:projectKey/environments/:environmentKey/holdouts/:holdoutKey
$curl https://app.launchdarkly.com/api/v2/projects/projectKey/environments/environmentKey/holdouts/holdoutKey \
> -H "Authorization: <apiKey>"
1{
2 "_id": "string",
3 "status": "created",
4 "holdoutAmount": "string",
5 "createdAt": 1,
6 "updatedAt": 1,
7 "baseExperiment": {
8 "key": "experiment-key-123abc",
9 "name": "Example experiment",
10 "_maintainerId": "12ab3c45de678910fgh12345",
11 "_creationDate": 1654104600000,
12 "environmentKey": "string",
13 "_links": {
14 "parent": {
15 "href": "/api/v2/projects/my-project/environments/my-environment",
16 "type": "application/json"
17 },
18 "self": {
19 "href": "/api/v2/projects/my-project/environments/my-environment/experiments/my-experiment",
20 "type": "application/json"
21 }
22 },
23 "_id": "12ab3c45de678910fgh12345",
24 "description": "An example experiment, used in testing",
25 "methodology": "bayesian",
26 "dataSource": "snowflake",
27 "archivedDate": 1654104600000,
28 "tags": [
29 "experiment",
30 "feature"
31 ],
32 "holdoutId": "f3b74309-d581-44e1-8a2b-bb2933b4fe40",
33 "currentIteration": {
34 "hypothesis": "The new button placement will increase conversion",
35 "status": "running",
36 "createdAt": 1654104600000,
37 "_id": "12ab3c45de678910fgh12345",
38 "startedAt": 1655314200000,
39 "endedAt": 1656610200000,
40 "winningTreatmentId": "122c9f3e-da26-4321-ba68-e0fc02eced58",
41 "winningReason": "We ran this iteration for two weeks and the winning variation was clear",
42 "canReshuffleTraffic": true,
43 "flags": {},
44 "reallocationFrequencyMillis": 3600000,
45 "version": 0,
46 "primaryMetric": {
47 "key": "metric-key-123abc",
48 "_versionId": "string",
49 "name": "My metric",
50 "kind": "custom",
51 "_links": {
52 "self": {
53 "href": "/api/v2/metrics/my-project/my-metric",
54 "type": "application/json"
55 }
56 },
57 "isGroup": true,
58 "isNumeric": true,
59 "eventKey": "event-key-123abc",
60 "metrics": [
61 {
62 "key": "metric-key-123abc",
63 "name": "Example metric",
64 "kind": "custom",
65 "_links": {
66 "self": {
67 "href": "/api/v2/metrics/my-project/my-metric",
68 "type": "application/json"
69 }
70 },
71 "_versionId": "version-id-123abc",
72 "isNumeric": true,
73 "unitAggregationType": "sum",
74 "eventKey": "event-key-123abc",
75 "nameInGroup": "Step 1",
76 "analysisUnits": [
77 "user"
78 ],
79 "randomizationUnits": [
80 "user"
81 ]
82 }
83 ]
84 },
85 "primarySingleMetric": {
86 "key": "metric-key-123abc",
87 "name": "Example metric",
88 "kind": "custom",
89 "_links": {
90 "self": {
91 "href": "/api/v2/metrics/my-project/my-metric",
92 "type": "application/json"
93 }
94 },
95 "_versionId": "version-id-123abc",
96 "isNumeric": true,
97 "unitAggregationType": "sum",
98 "eventKey": "event-key-123abc"
99 },
100 "primaryFunnel": {
101 "key": "metric-group-key-123abc",
102 "name": "My metric group",
103 "kind": "funnel",
104 "_links": {
105 "parent": {
106 "href": "/api/v2/projects/my-project",
107 "type": "application/json"
108 },
109 "self": {
110 "href": "/api/v2/projects/my-project/metric-groups/my-metric-group",
111 "type": "application/json"
112 }
113 },
114 "metrics": [
115 {
116 "key": "metric-key-123abc",
117 "name": "Example metric",
118 "kind": "custom",
119 "_links": {
120 "self": {
121 "href": "/api/v2/metrics/my-project/my-metric",
122 "type": "application/json"
123 }
124 },
125 "_versionId": "version-id-123abc",
126 "isNumeric": true,
127 "unitAggregationType": "sum",
128 "eventKey": "event-key-123abc",
129 "nameInGroup": "Step 1",
130 "analysisUnits": [
131 "user"
132 ],
133 "randomizationUnits": [
134 "user"
135 ]
136 }
137 ]
138 },
139 "randomizationUnit": "user",
140 "attributes": [
141 "string"
142 ],
143 "treatments": [
144 {
145 "name": "Treatment 1",
146 "allocationPercent": "10",
147 "_id": "122c9f3e-da26-4321-ba68-e0fc02eced58",
148 "baseline": true,
149 "parameters": [
150 {
151 "variationId": "string",
152 "flagKey": "string"
153 }
154 ]
155 }
156 ],
157 "metrics": [
158 {
159 "key": "metric-key-123abc",
160 "_versionId": "string",
161 "name": "My metric",
162 "kind": "custom",
163 "_links": {
164 "self": {
165 "href": "/api/v2/metrics/my-project/my-metric",
166 "type": "application/json"
167 }
168 },
169 "isGroup": true,
170 "isNumeric": true,
171 "eventKey": "event-key-123abc",
172 "metrics": [
173 {
174 "key": "metric-key-123abc",
175 "name": "Example metric",
176 "kind": "custom",
177 "_links": {
178 "self": {
179 "href": "/api/v2/metrics/my-project/my-metric",
180 "type": "application/json"
181 }
182 },
183 "_versionId": "version-id-123abc",
184 "isNumeric": true,
185 "unitAggregationType": "sum",
186 "eventKey": "event-key-123abc",
187 "nameInGroup": "Step 1",
188 "analysisUnits": [
189 "user"
190 ],
191 "randomizationUnits": [
192 "user"
193 ]
194 }
195 ]
196 }
197 ],
198 "layerSnapshot": {
199 "key": "checkout-flow",
200 "name": "Checkout Flow",
201 "reservationPercent": 10,
202 "otherReservationPercent": 70
203 },
204 "covariateInfo": {
205 "id": "74a49a2b-4834-4246-917e-5d85231d8c2a",
206 "fileName": "covariate.csv",
207 "createdAt": 1654104600000
208 },
209 "secondaryMetrics": [
210 {
211 "key": "metric-key-123abc",
212 "name": "Example metric",
213 "kind": "custom",
214 "_links": {
215 "self": {
216 "href": "/api/v2/metrics/my-project/my-metric",
217 "type": "application/json"
218 }
219 },
220 "_versionId": "version-id-123abc",
221 "isNumeric": true,
222 "unitAggregationType": "sum",
223 "eventKey": "event-key-123abc"
224 }
225 ]
226 },
227 "type": "experiment",
228 "draftIteration": {
229 "hypothesis": "The new button placement will increase conversion",
230 "status": "running",
231 "createdAt": 1654104600000,
232 "_id": "12ab3c45de678910fgh12345",
233 "startedAt": 1655314200000,
234 "endedAt": 1656610200000,
235 "winningTreatmentId": "122c9f3e-da26-4321-ba68-e0fc02eced58",
236 "winningReason": "We ran this iteration for two weeks and the winning variation was clear",
237 "canReshuffleTraffic": true,
238 "flags": {},
239 "reallocationFrequencyMillis": 3600000,
240 "version": 0,
241 "primaryMetric": {
242 "key": "metric-key-123abc",
243 "_versionId": "string",
244 "name": "My metric",
245 "kind": "custom",
246 "_links": {
247 "self": {
248 "href": "/api/v2/metrics/my-project/my-metric",
249 "type": "application/json"
250 }
251 },
252 "isGroup": true,
253 "isNumeric": true,
254 "eventKey": "event-key-123abc",
255 "metrics": [
256 {
257 "key": "metric-key-123abc",
258 "name": "Example metric",
259 "kind": "custom",
260 "_links": {
261 "self": {
262 "href": "/api/v2/metrics/my-project/my-metric",
263 "type": "application/json"
264 }
265 },
266 "_versionId": "version-id-123abc",
267 "isNumeric": true,
268 "unitAggregationType": "sum",
269 "eventKey": "event-key-123abc",
270 "nameInGroup": "Step 1",
271 "analysisUnits": [
272 "user"
273 ],
274 "randomizationUnits": [
275 "user"
276 ]
277 }
278 ]
279 },
280 "primarySingleMetric": {
281 "key": "metric-key-123abc",
282 "name": "Example metric",
283 "kind": "custom",
284 "_links": {
285 "self": {
286 "href": "/api/v2/metrics/my-project/my-metric",
287 "type": "application/json"
288 }
289 },
290 "_versionId": "version-id-123abc",
291 "isNumeric": true,
292 "unitAggregationType": "sum",
293 "eventKey": "event-key-123abc"
294 },
295 "primaryFunnel": {
296 "key": "metric-group-key-123abc",
297 "name": "My metric group",
298 "kind": "funnel",
299 "_links": {
300 "parent": {
301 "href": "/api/v2/projects/my-project",
302 "type": "application/json"
303 },
304 "self": {
305 "href": "/api/v2/projects/my-project/metric-groups/my-metric-group",
306 "type": "application/json"
307 }
308 },
309 "metrics": [
310 {
311 "key": "metric-key-123abc",
312 "name": "Example metric",
313 "kind": "custom",
314 "_links": {
315 "self": {
316 "href": "/api/v2/metrics/my-project/my-metric",
317 "type": "application/json"
318 }
319 },
320 "_versionId": "version-id-123abc",
321 "isNumeric": true,
322 "unitAggregationType": "sum",
323 "eventKey": "event-key-123abc",
324 "nameInGroup": "Step 1",
325 "analysisUnits": [
326 "user"
327 ],
328 "randomizationUnits": [
329 "user"
330 ]
331 }
332 ]
333 },
334 "randomizationUnit": "user",
335 "attributes": [
336 "string"
337 ],
338 "treatments": [
339 {
340 "name": "Treatment 1",
341 "allocationPercent": "10",
342 "_id": "122c9f3e-da26-4321-ba68-e0fc02eced58",
343 "baseline": true,
344 "parameters": [
345 {
346 "variationId": "string",
347 "flagKey": "string"
348 }
349 ]
350 }
351 ],
352 "metrics": [
353 {
354 "key": "metric-key-123abc",
355 "_versionId": "string",
356 "name": "My metric",
357 "kind": "custom",
358 "_links": {
359 "self": {
360 "href": "/api/v2/metrics/my-project/my-metric",
361 "type": "application/json"
362 }
363 },
364 "isGroup": true,
365 "isNumeric": true,
366 "eventKey": "event-key-123abc",
367 "metrics": [
368 {
369 "key": "metric-key-123abc",
370 "name": "Example metric",
371 "kind": "custom",
372 "_links": {
373 "self": {
374 "href": "/api/v2/metrics/my-project/my-metric",
375 "type": "application/json"
376 }
377 },
378 "_versionId": "version-id-123abc",
379 "isNumeric": true,
380 "unitAggregationType": "sum",
381 "eventKey": "event-key-123abc",
382 "nameInGroup": "Step 1",
383 "analysisUnits": [
384 "user"
385 ],
386 "randomizationUnits": [
387 "user"
388 ]
389 }
390 ]
391 }
392 ],
393 "layerSnapshot": {
394 "key": "checkout-flow",
395 "name": "Checkout Flow",
396 "reservationPercent": 10,
397 "otherReservationPercent": 70
398 },
399 "covariateInfo": {
400 "id": "74a49a2b-4834-4246-917e-5d85231d8c2a",
401 "fileName": "covariate.csv",
402 "createdAt": 1654104600000
403 },
404 "secondaryMetrics": [
405 {
406 "key": "metric-key-123abc",
407 "name": "Example metric",
408 "kind": "custom",
409 "_links": {
410 "self": {
411 "href": "/api/v2/metrics/my-project/my-metric",
412 "type": "application/json"
413 }
414 },
415 "_versionId": "version-id-123abc",
416 "isNumeric": true,
417 "unitAggregationType": "sum",
418 "eventKey": "event-key-123abc"
419 }
420 ]
421 },
422 "previousIterations": [
423 {
424 "hypothesis": "The new button placement will increase conversion",
425 "status": "running",
426 "createdAt": 1654104600000,
427 "_id": "12ab3c45de678910fgh12345",
428 "startedAt": 1655314200000,
429 "endedAt": 1656610200000,
430 "winningTreatmentId": "122c9f3e-da26-4321-ba68-e0fc02eced58",
431 "winningReason": "We ran this iteration for two weeks and the winning variation was clear",
432 "canReshuffleTraffic": true,
433 "flags": {},
434 "reallocationFrequencyMillis": 3600000,
435 "version": 0,
436 "primaryMetric": {
437 "key": "metric-key-123abc",
438 "_versionId": "string",
439 "name": "My metric",
440 "kind": "custom",
441 "_links": {
442 "self": {
443 "href": "/api/v2/metrics/my-project/my-metric",
444 "type": "application/json"
445 }
446 },
447 "isGroup": true,
448 "isNumeric": true,
449 "eventKey": "event-key-123abc",
450 "metrics": [
451 {
452 "key": "metric-key-123abc",
453 "name": "Example metric",
454 "kind": "custom",
455 "_links": {
456 "self": {
457 "href": "/api/v2/metrics/my-project/my-metric",
458 "type": "application/json"
459 }
460 },
461 "_versionId": "version-id-123abc",
462 "isNumeric": true,
463 "unitAggregationType": "sum",
464 "eventKey": "event-key-123abc",
465 "nameInGroup": "Step 1",
466 "analysisUnits": [
467 "user"
468 ],
469 "randomizationUnits": [
470 "user"
471 ]
472 }
473 ]
474 },
475 "primarySingleMetric": {
476 "key": "metric-key-123abc",
477 "name": "Example metric",
478 "kind": "custom",
479 "_links": {
480 "self": {
481 "href": "/api/v2/metrics/my-project/my-metric",
482 "type": "application/json"
483 }
484 },
485 "_versionId": "version-id-123abc",
486 "isNumeric": true,
487 "unitAggregationType": "sum",
488 "eventKey": "event-key-123abc"
489 },
490 "primaryFunnel": {
491 "key": "metric-group-key-123abc",
492 "name": "My metric group",
493 "kind": "funnel",
494 "_links": {
495 "parent": {
496 "href": "/api/v2/projects/my-project",
497 "type": "application/json"
498 },
499 "self": {
500 "href": "/api/v2/projects/my-project/metric-groups/my-metric-group",
501 "type": "application/json"
502 }
503 },
504 "metrics": [
505 {
506 "key": "metric-key-123abc",
507 "name": "Example metric",
508 "kind": "custom",
509 "_links": {
510 "self": {
511 "href": "/api/v2/metrics/my-project/my-metric",
512 "type": "application/json"
513 }
514 },
515 "_versionId": "version-id-123abc",
516 "isNumeric": true,
517 "unitAggregationType": "sum",
518 "eventKey": "event-key-123abc",
519 "nameInGroup": "Step 1",
520 "analysisUnits": [
521 "user"
522 ],
523 "randomizationUnits": [
524 "user"
525 ]
526 }
527 ]
528 },
529 "randomizationUnit": "user",
530 "attributes": [
531 "string"
532 ],
533 "treatments": [
534 {
535 "name": "Treatment 1",
536 "allocationPercent": "10",
537 "_id": "122c9f3e-da26-4321-ba68-e0fc02eced58",
538 "baseline": true,
539 "parameters": [
540 {
541 "variationId": "string",
542 "flagKey": "string"
543 }
544 ]
545 }
546 ],
547 "metrics": [
548 {
549 "key": "metric-key-123abc",
550 "_versionId": "string",
551 "name": "My metric",
552 "kind": "custom",
553 "_links": {
554 "self": {
555 "href": "/api/v2/metrics/my-project/my-metric",
556 "type": "application/json"
557 }
558 },
559 "isGroup": true,
560 "isNumeric": true,
561 "eventKey": "event-key-123abc",
562 "metrics": [
563 {
564 "key": "metric-key-123abc",
565 "name": "Example metric",
566 "kind": "custom",
567 "_links": {
568 "self": {
569 "href": "/api/v2/metrics/my-project/my-metric",
570 "type": "application/json"
571 }
572 },
573 "_versionId": "version-id-123abc",
574 "isNumeric": true,
575 "unitAggregationType": "sum",
576 "eventKey": "event-key-123abc",
577 "nameInGroup": "Step 1",
578 "analysisUnits": [
579 "user"
580 ],
581 "randomizationUnits": [
582 "user"
583 ]
584 }
585 ]
586 }
587 ],
588 "layerSnapshot": {
589 "key": "checkout-flow",
590 "name": "Checkout Flow",
591 "reservationPercent": 10,
592 "otherReservationPercent": 70
593 },
594 "covariateInfo": {
595 "id": "74a49a2b-4834-4246-917e-5d85231d8c2a",
596 "fileName": "covariate.csv",
597 "createdAt": 1654104600000
598 },
599 "secondaryMetrics": [
600 {
601 "key": "metric-key-123abc",
602 "name": "Example metric",
603 "kind": "custom",
604 "_links": {
605 "self": {
606 "href": "/api/v2/metrics/my-project/my-metric",
607 "type": "application/json"
608 }
609 },
610 "_versionId": "version-id-123abc",
611 "isNumeric": true,
612 "unitAggregationType": "sum",
613 "eventKey": "event-key-123abc"
614 }
615 ]
616 }
617 ],
618 "analysisConfig": {
619 "bayesianThreshold": "string",
620 "significanceThreshold": "string",
621 "testDirection": "string",
622 "multipleComparisonCorrectionMethod": "bonferroni",
623 "multipleComparisonCorrectionScope": "variations",
624 "sequentialTestingEnabled": true
625 },
626 "mutableFieldsByStatus": {
627 "not_started": {},
628 "running": {},
629 "stopped": {}
630 }
631 },
632 "description": "string",
633 "isDirty": true,
634 "relatedExperiments": [
635 {
636 "key": "experiment-key-123abc",
637 "name": "Example experiment",
638 "_maintainerId": "12ab3c45de678910fgh12345",
639 "_creationDate": 1654104600000,
640 "environmentKey": "string",
641 "_links": {
642 "parent": {
643 "href": "/api/v2/projects/my-project/environments/my-environment",
644 "type": "application/json"
645 },
646 "self": {
647 "href": "/api/v2/projects/my-project/environments/my-environment/experiments/my-experiment",
648 "type": "application/json"
649 }
650 },
651 "_id": "12ab3c45de678910fgh12345",
652 "description": "An example experiment, used in testing",
653 "methodology": "bayesian",
654 "dataSource": "snowflake",
655 "archivedDate": 1654104600000,
656 "tags": [
657 "experiment",
658 "feature"
659 ],
660 "holdoutId": "f3b74309-d581-44e1-8a2b-bb2933b4fe40",
661 "currentIteration": {
662 "hypothesis": "The new button placement will increase conversion",
663 "status": "running",
664 "createdAt": 1654104600000,
665 "_id": "12ab3c45de678910fgh12345",
666 "startedAt": 1655314200000,
667 "endedAt": 1656610200000,
668 "winningTreatmentId": "122c9f3e-da26-4321-ba68-e0fc02eced58",
669 "winningReason": "We ran this iteration for two weeks and the winning variation was clear",
670 "canReshuffleTraffic": true,
671 "flags": {},
672 "reallocationFrequencyMillis": 3600000,
673 "version": 0,
674 "primaryMetric": {
675 "key": "metric-key-123abc",
676 "_versionId": "string",
677 "name": "My metric",
678 "kind": "custom",
679 "_links": {
680 "self": {
681 "href": "/api/v2/metrics/my-project/my-metric",
682 "type": "application/json"
683 }
684 },
685 "isGroup": true,
686 "isNumeric": true,
687 "eventKey": "event-key-123abc",
688 "metrics": [
689 {
690 "key": "metric-key-123abc",
691 "name": "Example metric",
692 "kind": "custom",
693 "_links": {
694 "self": {
695 "href": "/api/v2/metrics/my-project/my-metric",
696 "type": "application/json"
697 }
698 },
699 "_versionId": "version-id-123abc",
700 "isNumeric": true,
701 "unitAggregationType": "sum",
702 "eventKey": "event-key-123abc",
703 "nameInGroup": "Step 1",
704 "analysisUnits": [
705 "user"
706 ],
707 "randomizationUnits": [
708 "user"
709 ]
710 }
711 ]
712 },
713 "primarySingleMetric": {
714 "key": "metric-key-123abc",
715 "name": "Example metric",
716 "kind": "custom",
717 "_links": {
718 "self": {
719 "href": "/api/v2/metrics/my-project/my-metric",
720 "type": "application/json"
721 }
722 },
723 "_versionId": "version-id-123abc",
724 "isNumeric": true,
725 "unitAggregationType": "sum",
726 "eventKey": "event-key-123abc"
727 },
728 "primaryFunnel": {
729 "key": "metric-group-key-123abc",
730 "name": "My metric group",
731 "kind": "funnel",
732 "_links": {
733 "parent": {
734 "href": "/api/v2/projects/my-project",
735 "type": "application/json"
736 },
737 "self": {
738 "href": "/api/v2/projects/my-project/metric-groups/my-metric-group",
739 "type": "application/json"
740 }
741 },
742 "metrics": [
743 {
744 "key": "metric-key-123abc",
745 "name": "Example metric",
746 "kind": "custom",
747 "_links": {
748 "self": {
749 "href": "/api/v2/metrics/my-project/my-metric",
750 "type": "application/json"
751 }
752 },
753 "_versionId": "version-id-123abc",
754 "isNumeric": true,
755 "unitAggregationType": "sum",
756 "eventKey": "event-key-123abc",
757 "nameInGroup": "Step 1",
758 "analysisUnits": [
759 "user"
760 ],
761 "randomizationUnits": [
762 "user"
763 ]
764 }
765 ]
766 },
767 "randomizationUnit": "user",
768 "attributes": [
769 "string"
770 ],
771 "treatments": [
772 {
773 "name": "Treatment 1",
774 "allocationPercent": "10",
775 "_id": "122c9f3e-da26-4321-ba68-e0fc02eced58",
776 "baseline": true,
777 "parameters": [
778 {
779 "variationId": "string",
780 "flagKey": "string"
781 }
782 ]
783 }
784 ],
785 "metrics": [
786 {
787 "key": "metric-key-123abc",
788 "_versionId": "string",
789 "name": "My metric",
790 "kind": "custom",
791 "_links": {
792 "self": {
793 "href": "/api/v2/metrics/my-project/my-metric",
794 "type": "application/json"
795 }
796 },
797 "isGroup": true,
798 "isNumeric": true,
799 "eventKey": "event-key-123abc",
800 "metrics": [
801 {
802 "key": "metric-key-123abc",
803 "name": "Example metric",
804 "kind": "custom",
805 "_links": {
806 "self": {
807 "href": "/api/v2/metrics/my-project/my-metric",
808 "type": "application/json"
809 }
810 },
811 "_versionId": "version-id-123abc",
812 "isNumeric": true,
813 "unitAggregationType": "sum",
814 "eventKey": "event-key-123abc",
815 "nameInGroup": "Step 1",
816 "analysisUnits": [
817 "user"
818 ],
819 "randomizationUnits": [
820 "user"
821 ]
822 }
823 ]
824 }
825 ],
826 "layerSnapshot": {
827 "key": "checkout-flow",
828 "name": "Checkout Flow",
829 "reservationPercent": 10,
830 "otherReservationPercent": 70
831 },
832 "covariateInfo": {
833 "id": "74a49a2b-4834-4246-917e-5d85231d8c2a",
834 "fileName": "covariate.csv",
835 "createdAt": 1654104600000
836 },
837 "secondaryMetrics": [
838 {
839 "key": "metric-key-123abc",
840 "name": "Example metric",
841 "kind": "custom",
842 "_links": {
843 "self": {
844 "href": "/api/v2/metrics/my-project/my-metric",
845 "type": "application/json"
846 }
847 },
848 "_versionId": "version-id-123abc",
849 "isNumeric": true,
850 "unitAggregationType": "sum",
851 "eventKey": "event-key-123abc"
852 }
853 ]
854 },
855 "type": "experiment",
856 "draftIteration": {
857 "hypothesis": "The new button placement will increase conversion",
858 "status": "running",
859 "createdAt": 1654104600000,
860 "_id": "12ab3c45de678910fgh12345",
861 "startedAt": 1655314200000,
862 "endedAt": 1656610200000,
863 "winningTreatmentId": "122c9f3e-da26-4321-ba68-e0fc02eced58",
864 "winningReason": "We ran this iteration for two weeks and the winning variation was clear",
865 "canReshuffleTraffic": true,
866 "flags": {},
867 "reallocationFrequencyMillis": 3600000,
868 "version": 0,
869 "primaryMetric": {
870 "key": "metric-key-123abc",
871 "_versionId": "string",
872 "name": "My metric",
873 "kind": "custom",
874 "_links": {
875 "self": {
876 "href": "/api/v2/metrics/my-project/my-metric",
877 "type": "application/json"
878 }
879 },
880 "isGroup": true,
881 "isNumeric": true,
882 "eventKey": "event-key-123abc",
883 "metrics": [
884 {
885 "key": "metric-key-123abc",
886 "name": "Example metric",
887 "kind": "custom",
888 "_links": {
889 "self": {
890 "href": "/api/v2/metrics/my-project/my-metric",
891 "type": "application/json"
892 }
893 },
894 "_versionId": "version-id-123abc",
895 "isNumeric": true,
896 "unitAggregationType": "sum",
897 "eventKey": "event-key-123abc",
898 "nameInGroup": "Step 1",
899 "analysisUnits": [
900 "user"
901 ],
902 "randomizationUnits": [
903 "user"
904 ]
905 }
906 ]
907 },
908 "primarySingleMetric": {
909 "key": "metric-key-123abc",
910 "name": "Example metric",
911 "kind": "custom",
912 "_links": {
913 "self": {
914 "href": "/api/v2/metrics/my-project/my-metric",
915 "type": "application/json"
916 }
917 },
918 "_versionId": "version-id-123abc",
919 "isNumeric": true,
920 "unitAggregationType": "sum",
921 "eventKey": "event-key-123abc"
922 },
923 "primaryFunnel": {
924 "key": "metric-group-key-123abc",
925 "name": "My metric group",
926 "kind": "funnel",
927 "_links": {
928 "parent": {
929 "href": "/api/v2/projects/my-project",
930 "type": "application/json"
931 },
932 "self": {
933 "href": "/api/v2/projects/my-project/metric-groups/my-metric-group",
934 "type": "application/json"
935 }
936 },
937 "metrics": [
938 {
939 "key": "metric-key-123abc",
940 "name": "Example metric",
941 "kind": "custom",
942 "_links": {
943 "self": {
944 "href": "/api/v2/metrics/my-project/my-metric",
945 "type": "application/json"
946 }
947 },
948 "_versionId": "version-id-123abc",
949 "isNumeric": true,
950 "unitAggregationType": "sum",
951 "eventKey": "event-key-123abc",
952 "nameInGroup": "Step 1",
953 "analysisUnits": [
954 "user"
955 ],
956 "randomizationUnits": [
957 "user"
958 ]
959 }
960 ]
961 },
962 "randomizationUnit": "user",
963 "attributes": [
964 "string"
965 ],
966 "treatments": [
967 {
968 "name": "Treatment 1",
969 "allocationPercent": "10",
970 "_id": "122c9f3e-da26-4321-ba68-e0fc02eced58",
971 "baseline": true,
972 "parameters": [
973 {
974 "variationId": "string",
975 "flagKey": "string"
976 }
977 ]
978 }
979 ],
980 "metrics": [
981 {
982 "key": "metric-key-123abc",
983 "_versionId": "string",
984 "name": "My metric",
985 "kind": "custom",
986 "_links": {
987 "self": {
988 "href": "/api/v2/metrics/my-project/my-metric",
989 "type": "application/json"
990 }
991 },
992 "isGroup": true,
993 "isNumeric": true,
994 "eventKey": "event-key-123abc",
995 "metrics": [
996 {
997 "key": "metric-key-123abc",
998 "name": "Example metric",
999 "kind": "custom",
1000 "_links": {
1001 "self": {
1002 "href": "/api/v2/metrics/my-project/my-metric",
1003 "type": "application/json"
1004 }
1005 },
1006 "_versionId": "version-id-123abc",
1007 "isNumeric": true,
1008 "unitAggregationType": "sum",
1009 "eventKey": "event-key-123abc",
1010 "nameInGroup": "Step 1",
1011 "analysisUnits": [
1012 "user"
1013 ],
1014 "randomizationUnits": [
1015 "user"
1016 ]
1017 }
1018 ]
1019 }
1020 ],
1021 "layerSnapshot": {
1022 "key": "checkout-flow",
1023 "name": "Checkout Flow",
1024 "reservationPercent": 10,
1025 "otherReservationPercent": 70
1026 },
1027 "covariateInfo": {
1028 "id": "74a49a2b-4834-4246-917e-5d85231d8c2a",
1029 "fileName": "covariate.csv",
1030 "createdAt": 1654104600000
1031 },
1032 "secondaryMetrics": [
1033 {
1034 "key": "metric-key-123abc",
1035 "name": "Example metric",
1036 "kind": "custom",
1037 "_links": {
1038 "self": {
1039 "href": "/api/v2/metrics/my-project/my-metric",
1040 "type": "application/json"
1041 }
1042 },
1043 "_versionId": "version-id-123abc",
1044 "isNumeric": true,
1045 "unitAggregationType": "sum",
1046 "eventKey": "event-key-123abc"
1047 }
1048 ]
1049 },
1050 "previousIterations": [
1051 {
1052 "hypothesis": "The new button placement will increase conversion",
1053 "status": "running",
1054 "createdAt": 1654104600000,
1055 "_id": "12ab3c45de678910fgh12345",
1056 "startedAt": 1655314200000,
1057 "endedAt": 1656610200000,
1058 "winningTreatmentId": "122c9f3e-da26-4321-ba68-e0fc02eced58",
1059 "winningReason": "We ran this iteration for two weeks and the winning variation was clear",
1060 "canReshuffleTraffic": true,
1061 "flags": {},
1062 "reallocationFrequencyMillis": 3600000,
1063 "version": 0,
1064 "primaryMetric": {
1065 "key": "metric-key-123abc",
1066 "_versionId": "string",
1067 "name": "My metric",
1068 "kind": "custom",
1069 "_links": {
1070 "self": {
1071 "href": "/api/v2/metrics/my-project/my-metric",
1072 "type": "application/json"
1073 }
1074 },
1075 "isGroup": true,
1076 "isNumeric": true,
1077 "eventKey": "event-key-123abc",
1078 "metrics": [
1079 {
1080 "key": "metric-key-123abc",
1081 "name": "Example metric",
1082 "kind": "custom",
1083 "_links": {
1084 "self": {
1085 "href": "/api/v2/metrics/my-project/my-metric",
1086 "type": "application/json"
1087 }
1088 },
1089 "_versionId": "version-id-123abc",
1090 "isNumeric": true,
1091 "unitAggregationType": "sum",
1092 "eventKey": "event-key-123abc",
1093 "nameInGroup": "Step 1",
1094 "analysisUnits": [
1095 "user"
1096 ],
1097 "randomizationUnits": [
1098 "user"
1099 ]
1100 }
1101 ]
1102 },
1103 "primarySingleMetric": {
1104 "key": "metric-key-123abc",
1105 "name": "Example metric",
1106 "kind": "custom",
1107 "_links": {
1108 "self": {
1109 "href": "/api/v2/metrics/my-project/my-metric",
1110 "type": "application/json"
1111 }
1112 },
1113 "_versionId": "version-id-123abc",
1114 "isNumeric": true,
1115 "unitAggregationType": "sum",
1116 "eventKey": "event-key-123abc"
1117 },
1118 "primaryFunnel": {
1119 "key": "metric-group-key-123abc",
1120 "name": "My metric group",
1121 "kind": "funnel",
1122 "_links": {
1123 "parent": {
1124 "href": "/api/v2/projects/my-project",
1125 "type": "application/json"
1126 },
1127 "self": {
1128 "href": "/api/v2/projects/my-project/metric-groups/my-metric-group",
1129 "type": "application/json"
1130 }
1131 },
1132 "metrics": [
1133 {
1134 "key": "metric-key-123abc",
1135 "name": "Example metric",
1136 "kind": "custom",
1137 "_links": {
1138 "self": {
1139 "href": "/api/v2/metrics/my-project/my-metric",
1140 "type": "application/json"
1141 }
1142 },
1143 "_versionId": "version-id-123abc",
1144 "isNumeric": true,
1145 "unitAggregationType": "sum",
1146 "eventKey": "event-key-123abc",
1147 "nameInGroup": "Step 1",
1148 "analysisUnits": [
1149 "user"
1150 ],
1151 "randomizationUnits": [
1152 "user"
1153 ]
1154 }
1155 ]
1156 },
1157 "randomizationUnit": "user",
1158 "attributes": [
1159 "string"
1160 ],
1161 "treatments": [
1162 {
1163 "name": "Treatment 1",
1164 "allocationPercent": "10",
1165 "_id": "122c9f3e-da26-4321-ba68-e0fc02eced58",
1166 "baseline": true,
1167 "parameters": [
1168 {
1169 "variationId": "string",
1170 "flagKey": "string"
1171 }
1172 ]
1173 }
1174 ],
1175 "metrics": [
1176 {
1177 "key": "metric-key-123abc",
1178 "_versionId": "string",
1179 "name": "My metric",
1180 "kind": "custom",
1181 "_links": {
1182 "self": {
1183 "href": "/api/v2/metrics/my-project/my-metric",
1184 "type": "application/json"
1185 }
1186 },
1187 "isGroup": true,
1188 "isNumeric": true,
1189 "eventKey": "event-key-123abc",
1190 "metrics": [
1191 {
1192 "key": "metric-key-123abc",
1193 "name": "Example metric",
1194 "kind": "custom",
1195 "_links": {
1196 "self": {
1197 "href": "/api/v2/metrics/my-project/my-metric",
1198 "type": "application/json"
1199 }
1200 },
1201 "_versionId": "version-id-123abc",
1202 "isNumeric": true,
1203 "unitAggregationType": "sum",
1204 "eventKey": "event-key-123abc",
1205 "nameInGroup": "Step 1",
1206 "analysisUnits": [
1207 "user"
1208 ],
1209 "randomizationUnits": [
1210 "user"
1211 ]
1212 }
1213 ]
1214 }
1215 ],
1216 "layerSnapshot": {
1217 "key": "checkout-flow",
1218 "name": "Checkout Flow",
1219 "reservationPercent": 10,
1220 "otherReservationPercent": 70
1221 },
1222 "covariateInfo": {
1223 "id": "74a49a2b-4834-4246-917e-5d85231d8c2a",
1224 "fileName": "covariate.csv",
1225 "createdAt": 1654104600000
1226 },
1227 "secondaryMetrics": [
1228 {
1229 "key": "metric-key-123abc",
1230 "name": "Example metric",
1231 "kind": "custom",
1232 "_links": {
1233 "self": {
1234 "href": "/api/v2/metrics/my-project/my-metric",
1235 "type": "application/json"
1236 }
1237 },
1238 "_versionId": "version-id-123abc",
1239 "isNumeric": true,
1240 "unitAggregationType": "sum",
1241 "eventKey": "event-key-123abc"
1242 }
1243 ]
1244 }
1245 ],
1246 "analysisConfig": {
1247 "bayesianThreshold": "string",
1248 "significanceThreshold": "string",
1249 "testDirection": "string",
1250 "multipleComparisonCorrectionMethod": "bonferroni",
1251 "multipleComparisonCorrectionScope": "variations",
1252 "sequentialTestingEnabled": true
1253 },
1254 "mutableFieldsByStatus": {
1255 "not_started": {},
1256 "running": {},
1257 "stopped": {}
1258 }
1259 }
1260 ]
1261}
Get details about a holdout. ### Expanding the holdout response LaunchDarkly supports the following fields for expanding the "Get holdout" response. By default, these fields are **not** included in the response. To expand the response, append the `expand` query parameter and add a comma-separated list with any of the following fields: - `draftIteration` includes the iteration which has not been started yet, if any, for this holdout. - `previousIterations` includes all iterations prior to the current iteration, for this holdout. By default only the current iteration is included in the response. - `rel-draftIteration` includes the iteration which has not been started yet, if any, for the experiments related to this holdout. - `rel-metrics` includes metrics for experiments related to this holdout. - `rel-previousIterations` includes all iterations prior to the current iteration, for the experiments related to this holdout. - `rel-secondaryMetrics` includes secondary metrics for experiments related to this holdout. - `rel-treatments` includes all treatment and parameter details for experiments related to this holdout. - `secondaryMetrics` includes secondary metrics for this holdout. By default only the primary metric is included in the response. - `treatments` includes all treatment and parameter details for this holdout. By default treatment data is not included in the response. For example, `expand=draftIteration,rel-draftIteration` includes the `draftIteration` and `rel-draftIteration` fields in the response. If fields that you request with the `expand` query parameter are empty, they are not included in the response.
Was this page helpful?
Previous

Get Holdout by Id

Next
Built with

Get details about a holdout.

Expanding the holdout response

LaunchDarkly supports the following fields for expanding the “Get holdout” response. By default, these fields are not included in the response.

To expand the response, append the expand query parameter and add a comma-separated list with any of the following fields:

  • draftIteration includes the iteration which has not been started yet, if any, for this holdout.
  • previousIterations includes all iterations prior to the current iteration, for this holdout. By default only the current iteration is included in the response.
  • rel-draftIteration includes the iteration which has not been started yet, if any, for the experiments related to this holdout.
  • rel-metrics includes metrics for experiments related to this holdout.
  • rel-previousIterations includes all iterations prior to the current iteration, for the experiments related to this holdout.
  • rel-secondaryMetrics includes secondary metrics for experiments related to this holdout.
  • rel-treatments includes all treatment and parameter details for experiments related to this holdout.
  • secondaryMetrics includes secondary metrics for this holdout. By default only the primary metric is included in the response.
  • treatments includes all treatment and parameter details for this holdout. By default treatment data is not included in the response.

For example, expand=draftIteration,rel-draftIteration includes the draftIteration and rel-draftIteration fields in the response. If fields that you request with the expand query parameter are empty, they are not included in the response.

Authentication

Authorizationstring
API Key authentication via header

Path parameters

projectKeystringRequiredformat: "string"
The project key
environmentKeystringRequiredformat: "string"
The environment key
holdoutKeystringRequiredformat: "string"
The holdout experiment key

Query parameters

expandstringOptionalformat: "string"

A comma-separated list of properties that can reveal additional information in the response. Supported fields are explained above. Holdout experiment expansion fields have no prefix. Related experiment expansion fields have rel- as a prefix.

Response

HoldoutDetail response with full experiments
_idstring
statusenum
Allowed values:
holdoutAmountstring
The percentage of traffic allocated to this holdout.
createdAtlong
updatedAtlong
baseExperimentobject
descriptionstring
isDirtyboolean
Indicates if the holdout experiment is running and if any related experiments are running.
relatedExperimentslist of objects

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
429
Too Many Requests Error