---
title: Create or update a promotion
slug: amberflo-api/khhq-create-or-update-a-promotion
createdAt: 2024-11-07T15:10:16.972Z
---

{
  "id": "dVhCboaDGfynuJUcGlEwA",
  "type": "api-oas-v2",
  "data": {
    "method": "POST",
    "url": "https://app.amberflo.io/payments/pricing/amberflo/account-pricing/promotions/generic_product_promotion",
    "servers": [
      {
        "url": "https://app.amberflo.io/payments/pricing/amberflo/account-pricing/promotions/generic_product_promotion"
      }
    ],
    "name": "Create or update a promotion",
    "description": "",
    "contentType": "application/json",
    "request": {
      "pathParameters": [],
      "headerParameters": [],
      "queryParameters": [],
      "bodyDataParameters": [
        {
          "kind": "optional",
          "name": "body",
          "type": "object",
          "description": "",
          "customType": "payment.pricing.promotions.pre_created.GenericProductPromotion.in",
          "schema": [
            {
              "name": "id",
              "kind": "required",
              "type": "string",
              "description": "Unique id for the promotion.",
              "example": ""
            },
            {
              "name": "type",
              "kind": "optional",
              "type": "string",
              "description": "Promotion type.",
              "example": "",
              "default": "generic_product_promotion"
            },
            {
              "name": "promotionName",
              "kind": "required",
              "type": "string",
              "description": "Display name for the promotion.",
              "example": ""
            },
            {
              "name": "description",
              "kind": "optional",
              "type": "string",
              "example": ""
            },
            {
              "name": "lockingStatus",
              "kind": "optional",
              "type": "string",
              "description": "",
              "modelRef": "#/components/schemas/com.amberflo.service.common.LockingStatus.in",
              "customType": "com.amberflo.service.common.LockingStatus.in",
              "schema": []
            },
            {
              "name": "targetProductId",
              "kind": "optional",
              "type": "string",
              "example": ""
            },
            {
              "name": "promotionType",
              "kind": "optional",
              "type": "string",
              "description": "",
              "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.PromotionType.in",
              "customType": "payment.pricing.promotions.attributes.PromotionType.in",
              "schema": []
            },
            {
              "name": "condition",
              "kind": "optional",
              "type": "object",
              "description": "",
              "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.PromotionCondition.in",
              "customType": "payment.pricing.promotions.conditions.PromotionCondition.in",
              "schema": [],
              "complexType": "oneOf",
              "complexItems": [
                {
                  "name": "payment.pricing.promotions.conditions.AfterItemPriceThreshold.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterItemPriceThreshold.in",
                  "schema": [
                    {
                      "name": "requiredHistory",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "customType": "payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "schema": [
                        {
                          "name": "cycles",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        },
                        {
                          "name": "months",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        }
                      ]
                    },
                    {
                      "name": "minThreshold",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "after_item_price_threshold"
                    },
                    {
                      "name": "itemId",
                      "kind": "optional",
                      "type": "string",
                      "example": ""
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.AfterProductPriceThreshold.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterProductPriceThreshold.in",
                  "schema": [
                    {
                      "name": "requiredHistory",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "customType": "payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "schema": [
                        {
                          "name": "cycles",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        },
                        {
                          "name": "months",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        }
                      ]
                    },
                    {
                      "name": "minThreshold",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "after_product_price_threshold"
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.CompositeAndCondition.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CompositeAndCondition.in",
                  "schema": [
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "and_condition"
                    },
                    {
                      "name": "conditions",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.PromotionCondition.in",
                      "customType": "payment.pricing.promotions.conditions.PromotionCondition.in[]",
                      "schema": [],
                      "complexType": "oneOf",
                      "complexItems": [
                        {
                          "name": "payment.pricing.promotions.conditions.AfterItemPriceThreshold.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterItemPriceThreshold.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Circular-Reference"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.AfterProductPriceThreshold.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterProductPriceThreshold.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Circular-Reference"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.CompositeAndCondition.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CompositeAndCondition.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Circular-Reference"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.CustomerTagsCondition.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CustomerTagsCondition.in",
                          "schema": [
                            {
                              "name": "type",
                              "kind": "optional",
                              "type": "string",
                              "example": "",
                              "default": "customer_tag_condition"
                            },
                            {
                              "name": "customerTagsToFind",
                              "kind": "optional",
                              "type": "map",
                              "example": "",
                              "customType": "map<string, string>",
                              "schema": []
                            },
                            {
                              "name": "granularity",
                              "kind": "optional",
                              "type": "object",
                              "description": "",
                              "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.Granularity.in",
                              "customType": "payment.pricing.promotions.attributes.granularity.Granularity.in",
                              "schema": [],
                              "complexType": "oneOf",
                              "complexItems": [
                                {
                                  "name": "payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.in",
                                  "description": "",
                                  "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.in",
                                  "schema": [
                                    {
                                      "name": "",
                                      "description": "",
                                      "customType": "Max depth limit reached"
                                    }
                                  ]
                                },
                                {
                                  "name": "payment.pricing.promotions.attributes.granularity.ProductGranularity.in",
                                  "description": "",
                                  "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ProductGranularity.in",
                                  "schema": [
                                    {
                                      "name": "",
                                      "description": "",
                                      "customType": "Max depth limit reached"
                                    }
                                  ]
                                }
                              ]
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.NextBillingCycle.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NextBillingCycle.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.NoCondition.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NoCondition.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.SamePlan.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.SamePlan.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.conditions.TimeLimited.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.TimeLimited.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.CustomerTagsCondition.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CustomerTagsCondition.in",
                  "schema": [
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "customer_tag_condition"
                    },
                    {
                      "name": "customerTagsToFind",
                      "kind": "optional",
                      "type": "map",
                      "example": "",
                      "customType": "map<string, string>",
                      "schema": []
                    },
                    {
                      "name": "granularity",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.Granularity.in",
                      "customType": "payment.pricing.promotions.attributes.granularity.Granularity.in",
                      "schema": [],
                      "complexType": "oneOf",
                      "complexItems": [
                        {
                          "name": "payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.granularity.ProductGranularity.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ProductGranularity.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        }
                      ]
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.NextBillingCycle.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NextBillingCycle.in",
                  "schema": [
                    {
                      "name": "",
                      "description": "",
                      "customType": "Max depth limit reached"
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.NoCondition.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NoCondition.in",
                  "schema": [
                    {
                      "name": "",
                      "description": "",
                      "customType": "Max depth limit reached"
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.SamePlan.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.SamePlan.in",
                  "schema": [
                    {
                      "name": "",
                      "description": "",
                      "customType": "Max depth limit reached"
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.conditions.TimeLimited.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.TimeLimited.in",
                  "schema": [
                    {
                      "name": "",
                      "description": "",
                      "customType": "Max depth limit reached"
                    }
                  ]
                }
              ]
            },
            {
              "name": "promotionModel",
              "kind": "optional",
              "type": "object",
              "description": "",
              "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.PromotionModel.in",
              "customType": "payment.pricing.promotions.promotion_model.PromotionModel.in",
              "schema": [],
              "complexType": "oneOf",
              "complexItems": [
                {
                  "name": "payment.pricing.promotions.promotion_model.Absolute.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.Absolute.in",
                  "schema": [
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "absolute"
                    },
                    {
                      "name": "measure",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.Measure.in",
                      "customType": "payment.pricing.promotions.attributes.measure.Measure.in",
                      "schema": [],
                      "complexType": "oneOf",
                      "complexItems": [
                        {
                          "name": "payment.pricing.promotions.attributes.measure.PerUnitBatch.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnitBatch.in",
                          "schema": [
                            {
                              "name": "type",
                              "kind": "optional",
                              "type": "string",
                              "example": "",
                              "default": "per_batch"
                            },
                            {
                              "name": "batchSize",
                              "kind": "optional",
                              "type": "integer<int64>",
                              "example": 0
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.measure.PerUnit.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnit.in",
                          "schema": [
                            {
                              "name": "type",
                              "kind": "optional",
                              "type": "string",
                              "example": "",
                              "default": "per_unit"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.measure.TotalPrice.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.TotalPrice.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name": "requiredHistory",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "customType": "payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "schema": [
                        {
                          "name": "cycles",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        },
                        {
                          "name": "months",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        }
                      ]
                    },
                    {
                      "name": "totalMaxDiscount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "cycleMaxDiscount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "discount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.promotion_model.PriceTieredRelative.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.PriceTieredRelative.in",
                  "schema": [
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "price_tiered_relative"
                    },
                    {
                      "name": "measure",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.Measure.in",
                      "customType": "payment.pricing.promotions.attributes.measure.Measure.in",
                      "schema": [],
                      "complexType": "oneOf",
                      "complexItems": [
                        {
                          "name": "payment.pricing.promotions.attributes.measure.PerUnitBatch.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnitBatch.in",
                          "schema": [
                            {
                              "name": "type",
                              "kind": "optional",
                              "type": "string",
                              "example": "",
                              "default": "per_batch"
                            },
                            {
                              "name": "batchSize",
                              "kind": "optional",
                              "type": "integer<int64>",
                              "example": 0
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.measure.PerUnit.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnit.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.measure.TotalPrice.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.TotalPrice.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name": "requiredHistory",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "customType": "payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "schema": [
                        {
                          "name": "cycles",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        },
                        {
                          "name": "months",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        }
                      ]
                    },
                    {
                      "name": "totalMaxDiscount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "cycleMaxDiscount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "discountRatioMap",
                      "kind": "optional",
                      "type": "map",
                      "example": "",
                      "customType": "map<string, number>",
                      "schema": []
                    },
                    {
                      "name": "discountCalculationStrategy",
                      "kind": "optional",
                      "type": "string",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.PriceTieredRelative.DiscountCalculationStrategy.in",
                      "customType": "payment.pricing.promotions.promotion_model.PriceTieredRelative.DiscountCalculationStrategy.in",
                      "schema": []
                    },
                    {
                      "name": "acrossBillingPeriods",
                      "kind": "optional",
                      "type": "boolean",
                      "example": ""
                    }
                  ]
                },
                {
                  "name": "payment.pricing.promotions.promotion_model.Relative.in",
                  "description": "",
                  "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.Relative.in",
                  "schema": [
                    {
                      "name": "type",
                      "kind": "optional",
                      "type": "string",
                      "example": "",
                      "default": "relative"
                    },
                    {
                      "name": "measure",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.Measure.in",
                      "customType": "payment.pricing.promotions.attributes.measure.Measure.in",
                      "schema": [],
                      "complexType": "oneOf",
                      "complexItems": [
                        {
                          "name": "payment.pricing.promotions.attributes.measure.PerUnitBatch.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnitBatch.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.measure.PerUnit.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnit.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        },
                        {
                          "name": "payment.pricing.promotions.attributes.measure.TotalPrice.in",
                          "description": "",
                          "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.TotalPrice.in",
                          "schema": [
                            {
                              "name": "",
                              "description": "",
                              "customType": "Max depth limit reached"
                            }
                          ]
                        }
                      ]
                    },
                    {
                      "name": "requiredHistory",
                      "kind": "optional",
                      "type": "object",
                      "description": "",
                      "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "customType": "payment.pricing.promotions.attributes.HistoryRequirements.in",
                      "schema": [
                        {
                          "name": "cycles",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        },
                        {
                          "name": "months",
                          "kind": "optional",
                          "type": "integer<int32>",
                          "example": 0
                        }
                      ]
                    },
                    {
                      "name": "totalMaxDiscount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "cycleMaxDiscount",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    },
                    {
                      "name": "discountRatio",
                      "kind": "optional",
                      "type": "number",
                      "example": ""
                    }
                  ]
                }
              ]
            }
          ],
          "modelRef": "#/components/schemas/payment.pricing.promotions.pre_created.GenericProductPromotion.in",
          "isExpanded": true
        }
      ],
      "formDataParameters": [],
      "oAuthParameters": [
        {
          "id": "apiKey",
          "name": "X-API-KEY",
          "kind": "optional",
          "type": "apiKey",
          "in": "header"
        }
      ]
    },
    "responses": [
      {
        "statusCode": "200",
        "description": "Successful request",
        "jsonExample": "",
        "isExpanded": true,
        "schema": [
          {
            "kind": "optional",
            "type": "object",
            "description": "",
            "customType": "payment.pricing.promotions.pre_created.GenericProductPromotion.out",
            "schema": [
              {
                "name": "id",
                "kind": "required",
                "type": "string",
                "description": "Unique id for the promotion.",
                "example": ""
              },
              {
                "name": "type",
                "kind": "optional",
                "type": "string",
                "description": "Promotion type.",
                "example": "",
                "default": "generic_product_promotion"
              },
              {
                "name": "promotionName",
                "kind": "required",
                "type": "string",
                "description": "Display name for the promotion.",
                "example": ""
              },
              {
                "name": "description",
                "kind": "optional",
                "type": "string",
                "example": ""
              },
              {
                "name": "lockingStatus",
                "kind": "optional",
                "type": "string",
                "description": "",
                "modelRef": "#/components/schemas/com.amberflo.service.common.LockingStatus.out",
                "customType": "com.amberflo.service.common.LockingStatus.out",
                "schema": []
              },
              {
                "name": "lastUpdateTimeInMillis",
                "kind": "optional",
                "type": "integer<int64>",
                "description": "Last update time, in [Unix time](https://en.wikipedia.org/wiki/Unix_time) (milliseconds).",
                "example": 0
              },
              {
                "name": "targetProductId",
                "kind": "optional",
                "type": "string",
                "example": ""
              },
              {
                "name": "promotionType",
                "kind": "optional",
                "type": "string",
                "description": "",
                "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.PromotionType.out",
                "customType": "payment.pricing.promotions.attributes.PromotionType.out",
                "schema": []
              },
              {
                "name": "condition",
                "kind": "optional",
                "type": "object",
                "description": "",
                "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.PromotionCondition.out",
                "customType": "payment.pricing.promotions.conditions.PromotionCondition.out",
                "schema": [],
                "complexType": "oneOf",
                "complexItems": [
                  {
                    "name": "payment.pricing.promotions.conditions.AfterItemPriceThreshold.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterItemPriceThreshold.out",
                    "schema": [
                      {
                        "name": "requiredHistory",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "customType": "payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "schema": [
                          {
                            "name": "cycles",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          },
                          {
                            "name": "months",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          }
                        ]
                      },
                      {
                        "name": "minThreshold",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "after_item_price_threshold"
                      },
                      {
                        "name": "itemId",
                        "kind": "optional",
                        "type": "string",
                        "example": ""
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.AfterProductPriceThreshold.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterProductPriceThreshold.out",
                    "schema": [
                      {
                        "name": "requiredHistory",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "customType": "payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "schema": [
                          {
                            "name": "cycles",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          },
                          {
                            "name": "months",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          }
                        ]
                      },
                      {
                        "name": "minThreshold",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "after_product_price_threshold"
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.CompositeAndCondition.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CompositeAndCondition.out",
                    "schema": [
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "and_condition"
                      },
                      {
                        "name": "conditions",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.PromotionCondition.out",
                        "customType": "payment.pricing.promotions.conditions.PromotionCondition.out[]",
                        "schema": [],
                        "complexType": "oneOf",
                        "complexItems": [
                          {
                            "name": "payment.pricing.promotions.conditions.AfterItemPriceThreshold.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterItemPriceThreshold.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Circular-Reference"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.AfterProductPriceThreshold.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.AfterProductPriceThreshold.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Circular-Reference"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.CompositeAndCondition.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CompositeAndCondition.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Circular-Reference"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.CustomerTagsCondition.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CustomerTagsCondition.out",
                            "schema": [
                              {
                                "name": "type",
                                "kind": "optional",
                                "type": "string",
                                "example": "",
                                "default": "customer_tag_condition"
                              },
                              {
                                "name": "customerTagsToFind",
                                "kind": "optional",
                                "type": "map",
                                "example": "",
                                "customType": "map<string, string>",
                                "schema": []
                              },
                              {
                                "name": "granularity",
                                "kind": "optional",
                                "type": "object",
                                "description": "",
                                "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.Granularity.out",
                                "customType": "payment.pricing.promotions.attributes.granularity.Granularity.out",
                                "schema": [],
                                "complexType": "oneOf",
                                "complexItems": [
                                  {
                                    "name": "payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.out",
                                    "description": "",
                                    "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.out",
                                    "schema": [
                                      {
                                        "name": "",
                                        "description": "",
                                        "customType": "Max depth limit reached"
                                      }
                                    ]
                                  },
                                  {
                                    "name": "payment.pricing.promotions.attributes.granularity.ProductGranularity.out",
                                    "description": "",
                                    "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ProductGranularity.out",
                                    "schema": [
                                      {
                                        "name": "",
                                        "description": "",
                                        "customType": "Max depth limit reached"
                                      }
                                    ]
                                  }
                                ]
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.NextBillingCycle.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NextBillingCycle.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.NoCondition.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NoCondition.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.SamePlan.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.SamePlan.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.conditions.TimeLimited.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.TimeLimited.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.CustomerTagsCondition.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.CustomerTagsCondition.out",
                    "schema": [
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "customer_tag_condition"
                      },
                      {
                        "name": "customerTagsToFind",
                        "kind": "optional",
                        "type": "map",
                        "example": "",
                        "customType": "map<string, string>",
                        "schema": []
                      },
                      {
                        "name": "granularity",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.Granularity.out",
                        "customType": "payment.pricing.promotions.attributes.granularity.Granularity.out",
                        "schema": [],
                        "complexType": "oneOf",
                        "complexItems": [
                          {
                            "name": "payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ItemVariantGranularity.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.granularity.ProductGranularity.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.granularity.ProductGranularity.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          }
                        ]
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.NextBillingCycle.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NextBillingCycle.out",
                    "schema": [
                      {
                        "name": "",
                        "description": "",
                        "customType": "Max depth limit reached"
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.NoCondition.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.NoCondition.out",
                    "schema": [
                      {
                        "name": "",
                        "description": "",
                        "customType": "Max depth limit reached"
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.SamePlan.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.SamePlan.out",
                    "schema": [
                      {
                        "name": "",
                        "description": "",
                        "customType": "Max depth limit reached"
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.conditions.TimeLimited.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.conditions.TimeLimited.out",
                    "schema": [
                      {
                        "name": "",
                        "description": "",
                        "customType": "Max depth limit reached"
                      }
                    ]
                  }
                ]
              },
              {
                "name": "promotionModel",
                "kind": "optional",
                "type": "object",
                "description": "",
                "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.PromotionModel.out",
                "customType": "payment.pricing.promotions.promotion_model.PromotionModel.out",
                "schema": [],
                "complexType": "oneOf",
                "complexItems": [
                  {
                    "name": "payment.pricing.promotions.promotion_model.Absolute.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.Absolute.out",
                    "schema": [
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "absolute"
                      },
                      {
                        "name": "measure",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.Measure.out",
                        "customType": "payment.pricing.promotions.attributes.measure.Measure.out",
                        "schema": [],
                        "complexType": "oneOf",
                        "complexItems": [
                          {
                            "name": "payment.pricing.promotions.attributes.measure.PerUnitBatch.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnitBatch.out",
                            "schema": [
                              {
                                "name": "type",
                                "kind": "optional",
                                "type": "string",
                                "example": "",
                                "default": "per_batch"
                              },
                              {
                                "name": "batchSize",
                                "kind": "optional",
                                "type": "integer<int64>",
                                "example": 0
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.measure.PerUnit.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnit.out",
                            "schema": [
                              {
                                "name": "type",
                                "kind": "optional",
                                "type": "string",
                                "example": "",
                                "default": "per_unit"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.measure.TotalPrice.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.TotalPrice.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "name": "requiredHistory",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "customType": "payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "schema": [
                          {
                            "name": "cycles",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          },
                          {
                            "name": "months",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          }
                        ]
                      },
                      {
                        "name": "totalMaxDiscount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "cycleMaxDiscount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "discount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.promotion_model.PriceTieredRelative.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.PriceTieredRelative.out",
                    "schema": [
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "price_tiered_relative"
                      },
                      {
                        "name": "measure",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.Measure.out",
                        "customType": "payment.pricing.promotions.attributes.measure.Measure.out",
                        "schema": [],
                        "complexType": "oneOf",
                        "complexItems": [
                          {
                            "name": "payment.pricing.promotions.attributes.measure.PerUnitBatch.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnitBatch.out",
                            "schema": [
                              {
                                "name": "type",
                                "kind": "optional",
                                "type": "string",
                                "example": "",
                                "default": "per_batch"
                              },
                              {
                                "name": "batchSize",
                                "kind": "optional",
                                "type": "integer<int64>",
                                "example": 0
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.measure.PerUnit.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnit.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.measure.TotalPrice.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.TotalPrice.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "name": "requiredHistory",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "customType": "payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "schema": [
                          {
                            "name": "cycles",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          },
                          {
                            "name": "months",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          }
                        ]
                      },
                      {
                        "name": "totalMaxDiscount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "cycleMaxDiscount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "discountRatioMap",
                        "kind": "optional",
                        "type": "map",
                        "example": "",
                        "customType": "map<string, number>",
                        "schema": []
                      },
                      {
                        "name": "discountCalculationStrategy",
                        "kind": "optional",
                        "type": "string",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.PriceTieredRelative.DiscountCalculationStrategy.out",
                        "customType": "payment.pricing.promotions.promotion_model.PriceTieredRelative.DiscountCalculationStrategy.out",
                        "schema": []
                      },
                      {
                        "name": "acrossBillingPeriods",
                        "kind": "optional",
                        "type": "boolean",
                        "example": ""
                      }
                    ]
                  },
                  {
                    "name": "payment.pricing.promotions.promotion_model.Relative.out",
                    "description": "",
                    "modelRef": "#/components/schemas/payment.pricing.promotions.promotion_model.Relative.out",
                    "schema": [
                      {
                        "name": "type",
                        "kind": "optional",
                        "type": "string",
                        "example": "",
                        "default": "relative"
                      },
                      {
                        "name": "measure",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.Measure.out",
                        "customType": "payment.pricing.promotions.attributes.measure.Measure.out",
                        "schema": [],
                        "complexType": "oneOf",
                        "complexItems": [
                          {
                            "name": "payment.pricing.promotions.attributes.measure.PerUnitBatch.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnitBatch.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.measure.PerUnit.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.PerUnit.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          },
                          {
                            "name": "payment.pricing.promotions.attributes.measure.TotalPrice.out",
                            "description": "",
                            "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.measure.TotalPrice.out",
                            "schema": [
                              {
                                "name": "",
                                "description": "",
                                "customType": "Max depth limit reached"
                              }
                            ]
                          }
                        ]
                      },
                      {
                        "name": "requiredHistory",
                        "kind": "optional",
                        "type": "object",
                        "description": "",
                        "modelRef": "#/components/schemas/payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "customType": "payment.pricing.promotions.attributes.HistoryRequirements.out",
                        "schema": [
                          {
                            "name": "cycles",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          },
                          {
                            "name": "months",
                            "kind": "optional",
                            "type": "integer<int32>",
                            "example": 0
                          }
                        ]
                      },
                      {
                        "name": "totalMaxDiscount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "cycleMaxDiscount",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      },
                      {
                        "name": "discountRatio",
                        "kind": "optional",
                        "type": "number",
                        "example": ""
                      }
                    ]
                  }
                ]
              }
            ],
            "modelRef": "#/components/schemas/payment.pricing.promotions.pre_created.GenericProductPromotion.out",
            "isExpanded": true
          }
        ]
      }
    ],
    "examples": {
      "languages": [
        {
          "id": "oYvapd66wmdH4ALoxw_CP",
          "language": "curl",
          "label": "cURL",
          "code": "curl --request POST \\\n     --url https://app.amberflo.io/payments/pricing/amberflo/account-pricing/promotions/generic_product_promotion \\\n     --header 'accept: application/json' \\\n     --header 'content-type: application/json' \\\n     --data '{\n     \"id\": \"\",\n     \"type\": \"generic_product_promotion\",\n     \"promotionName\": \"\",\n     \"condition\": {\n     \"type\": \"after_item_price_threshold\"\n     },\n     \"promotionModel\": {\n     \"type\": \"absolute\",\n     \"measure\": {\n     \"type\": \"per_batch\"\n     }\n     }\n     }'"
        },
        {
          "id": "wTPFfxxvP2e6XIuBXznp3",
          "language": "javascript",
          "label": "javascript",
          "code": "var myHeaders = new Headers();\nmyHeaders.append(\"accept\", \"application/json\");\nmyHeaders.append(\"content-type\", \"application/json\");\n\nvar raw = JSON.stringify({\n   \"id\": \"\",\n   \"type\": \"generic_product_promotion\",\n   \"promotionName\": \"\",\n   \"condition\": {\n      \"type\": \"after_item_price_threshold\"\n   },\n   \"promotionModel\": {\n      \"type\": \"absolute\",\n      \"measure\": {\n         \"type\": \"per_batch\"\n      }\n   }\n});\n\nvar requestOptions = {\n   method: 'POST',\n   headers: myHeaders,\n   body: raw,\n   redirect: 'follow'\n};\n\nfetch(\"https://app.amberflo.io/payments/pricing/amberflo/account-pricing/promotions/generic_product_promotion\", requestOptions)\n   .then(response => response.text())\n   .then(result => console.log(result))\n   .catch(error => console.log('error', error));"
        },
        {
          "id": "PdfFdMrtqbk_evLpJ8ldG",
          "language": "ruby",
          "label": "Ruby",
          "code": "require \"uri\"\nrequire \"json\"\nrequire \"net/http\"\n\nurl = URI(\"https://app.amberflo.io/payments/pricing/amberflo/account-pricing/promotions/generic_product_promotion\")\n\nhttps = Net::HTTP.new(url.host, url.port)\nhttps.use_ssl = true\n\nrequest = Net::HTTP::Post.new(url)\nrequest[\"accept\"] = \"application/json\"\nrequest[\"content-type\"] = \"application/json\"\nrequest.body = JSON.dump({\n   \"id\": \"\",\n   \"type\": \"generic_product_promotion\",\n   \"promotionName\": \"\",\n   \"condition\": {\n      \"type\": \"after_item_price_threshold\"\n   },\n   \"promotionModel\": {\n      \"type\": \"absolute\",\n      \"measure\": {\n         \"type\": \"per_batch\"\n      }\n   }\n})\n\nresponse = https.request(request)\nputs response.read_body\n"
        },
        {
          "id": "Rksk89H5Kuvx3pbdLtIbe",
          "language": "python",
          "label": "Python",
          "code": "import requests\nimport json\n\nurl = \"https://app.amberflo.io/payments/pricing/amberflo/account-pricing/promotions/generic_product_promotion\"\n\npayload = json.dumps({\n   \"id\": \"\",\n   \"type\": \"generic_product_promotion\",\n   \"promotionName\": \"\",\n   \"condition\": {\n      \"type\": \"after_item_price_threshold\"\n   },\n   \"promotionModel\": {\n      \"type\": \"absolute\",\n      \"measure\": {\n         \"type\": \"per_batch\"\n      }\n   }\n})\nheaders = {\n   'accept': 'application/json',\n   'content-type': 'application/json'\n}\n\nresponse = requests.request(\"POST\", url, headers=headers, data=payload)\n\nprint(response.text)\n"
        }
      ],
      "selectedLanguageId": "oYvapd66wmdH4ALoxw_CP"
    },
    "results": {
      "languages": [
        {
          "id": "response-0-200",
          "language": "200",
          "code": "// Successful request\n{\n  \"id\": \"\",\n  \"type\": \"\",\n  \"promotionName\": \"\",\n  \"description\": \"\",\n  \"lockingStatus\": \"\",\n  \"lastUpdateTimeInMillis\": \"\",\n  \"targetProductId\": \"\",\n  \"promotionType\": \"\",\n  \"condition\": {},\n  \"promotionModel\": {}\n}"
        }
      ],
      "selectedLanguageId": "response-0-200"
    }
  },
  "children": [
    {
      "text": ""
    }
  ]
}