> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stigg.io/llms.txt
> Use this file to discover all available pages before exploring further.

# createOneExperiment

> Create a new experiment



**mutation** `createOneExperiment(input: CreateExperimentInput!): Experiment!`

## Arguments

**`input`**: `CreateExperimentInput!` (required)

## Returns

`Experiment!`

**`controlGroupName`**: `String!`

Name for the control group

---

**`createdAt`**: `DateTime!`

Timestamp of when the record was created

---

**`customers`**: `Customer`

---

**`description`**: `String`

Description of the experiements

---

**`environment`**: `Environment`

---

**`environmentId`**: `UUID!`

The unique identifier for the environment

---

**`id`**: `UUID!`

Unique identifier for the entity

---

**`initialProductSettings`**: `ProductSettings`

The product settings for the control group

---

**`name`**: `String!`

Name of the experiment

---

**`product`**: `Product`

---

**`productId`**: `String!`

Internal identifier for the product experiment is associated with

---

**`productSettings`**: `ProductSettings!`

Product settings for the variant group

---

**`refId`**: `String!`

The unique identifier for the experiment

---

**`startedAt`**: `DateTime`

Start date of the experiment

---

**`status`**: `ExperimentStatus!`

The status of the experiment

---

**`stoppedAt`**: `DateTime`

Stop date of the experiment

---

**`updatedAt`**: `DateTime!`

Timestamp of when the record was last updated

---

**`variantGroupName`**: `String!`

Name for the variant group

---

**`variantPercentage`**: `Float!`

Percentage of users in the variant group

## Examples

```graphql Mutation
mutation CreateOneExperiment($input: CreateExperimentInput!) {
  createOneExperiment(input: $input) {
    controlGroupName
    createdAt
    customers {
      additionalMetaData
      awsMarketplaceCustomerId
      billingCurrency
      billingId
      billingLinkUrl
      coupon {
        additionalMetaData
        amountsOff {
          __typename
        }
        billingId
        billingLinkUrl
        createdAt
        customers {
          __typename
        }
      }
    }
    description
    environment {
      account {
        accessMethod
        accountEmailDomain
        accountStatus
        defaultSSORoles {
          __typename
        }
        displayName
        emailDomains {
          __typename
        }
      }
      apiKeys {
        createdAt
        description
        displayName
        environmentId
        expireAt
        id
      }
      color
      createdAt
      description
      displayName
    }
    environmentId
  }
}
```

```json Variables
{
  "input": {
    "controlGroupName": "string",
    "name": "string",
    "productId": "string",
    "variantGroupName": "string",
    "variantPercentage": 1.5
  }
}
```

```json Response
{
  "data": {
    "createOneExperiment": {
      "controlGroupName": "string",
      "createdAt": "value",
      "customers": {
        "additionalMetaData": "value",
        "awsMarketplaceCustomerId": "string",
        "billingCurrency": "AED",
        "billingId": "string",
        "billingLinkUrl": "string",
        "coupon": {
          "additionalMetaData": "value",
          "amountsOff": [
            {
              "__typename": "Money"
            }
          ],
          "billingId": "string",
          "billingLinkUrl": "string",
          "createdAt": "value",
          "customers": [
            {
              "__typename": "Customer"
            }
          ]
        }
      },
      "description": "string",
      "environment": {
        "account": {
          "accessMethod": "AUTHORIZED_DOMAIN",
          "accountEmailDomain": "string",
          "accountStatus": "ACTIVE",
          "defaultSSORoles": {
            "__typename": "AccessRoles"
          },
          "displayName": "string",
          "emailDomains": [
            {
              "__typename": "AccountEmailDomain"
            }
          ]
        },
        "apiKeys": [
          {
            "createdAt": "value",
            "description": "string",
            "displayName": "string",
            "environmentId": "value",
            "expireAt": "value",
            "id": "value"
          }
        ],
        "color": "string",
        "createdAt": "value",
        "description": "string",
        "displayName": "string"
      },
      "environmentId": "value"
    }
  }
}
```


## Related topics

- [CreateExperimentInput](https://docs.stigg.io/graphql-reference/types/CreateExperimentInput.md)
- [createOneProduct](https://docs.stigg.io/graphql-reference/mutations/createOneProduct.md)
- [createOneCustomer](https://docs.stigg.io/graphql-reference/mutations/createOneCustomer.md)
- [createOneAddon](https://docs.stigg.io/graphql-reference/mutations/createOneAddon.md)
- [createOneEnvironment](https://docs.stigg.io/graphql-reference/mutations/createOneEnvironment.md)


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.