---
title: "Create a mixture"
method: POST
path: "/mixtures"
tags: ["mixtures"]
---

# Create a mixture

`POST /mixtures`

## Request

- Base URL: `https://{tenant_name}.benchling.com/api/v2`
- URL: `https://{tenant_name}.benchling.com/api/v2/mixtures`
- Auth: HTTP bearer

Create a mixture.
To create a new child mixture (eg. a prep) from a parent mixture (eg. a recipe), set the parent mixture field and specify the desired final state for your ingredients.
Benchling will recognize that any ingredients you specify that match ingredients on the parent mixture (based on component entity) are inherited. This can be seen on the returned `ingredients[i].hasParent` attribute.

## Request body

- MixtureCreate
  - `aliases` string[]: Aliases to add to the mixture
  - `amount` string: The positive numerical amount value of this mixture in string format (to preserve full precision). Pair with `units`. Supports scientific notation (1.23e4).
  - `authorIds` string[]: IDs of users to set as the mixture's authors.
  - `customFields` CustomFields
  - `entityRegistryId` string: Entity registry ID to set for the registered entity. Cannot specify both entityRegistryId and namingStrategy at the same time.
  - `fields` Fields
  - `folderId` string: ID of the folder containing the entity. Can be left empty when registryId is present.
  - `ingredients` IngredientWriteParams[]: Desired final state for the ingredients on this mixture. Each ingredient you specify will be matched with the existing ingredients on the mixture based on the component entity, and Benchling will create, update, or delete this mixture's ingredients so that the final state of this mixture's ingredients matches your request. Benchling will recognize that any ingredients you specify that match ingredients on the parent mixture (based on component entity) are inherited. This can be seen on the returned `ingredients[i].hasParent` attribute.
    - `amount` string, nullable, required: The amount value of this ingredient in its mixture, in string format (to preserve full precision). Pair with `units`. Supports scientific notation (1.23e4). One ingredient on this mixture can have an amount value of `"QS"`.
    - `catalogIdentifier` string, nullable, required
    - `componentEntityId` string, required: The entity that uniquely identifies this component.
    - `componentLotContainerId` string, nullable, required: The container representing the component lot for this ingredient. This is only writable if the mixture schema supports component lots in "inventory" format.
    - `componentLotEntityId` string, nullable, required: The entity representing the component lot for this ingredient. This is only writable if the mixture schema supports component lots in "inventory" format.
    - `componentLotText` string, nullable, required: Text representing the component lot for this ingredient. This is only writable if the mixture schema supports component lots in "text" format.
    - `notes` string, nullable, required
    - `units` 'nL' | 'uL' | 'mL' | 'L' | 'mg' | 'g' | 'kg' | 'ug' | 'Units' | 'Cells' | 'mol' | 'mmol' | 'umol', required
  - `name` string
  - `schemaId` string
  - `units` 'nL' | 'uL' | 'mL' | 'L' | 'g' | 'kg' | 'mg' | 'ug' | 'Units'
  - `namingStrategy` 'NEW_IDS' | 'IDS_FROM_NAMES' | 'DELETE_NAMES' | 'SET_FROM_NAME_PARTS' | 'REPLACE_NAMES_FROM_PARTS' | 'KEEP_NAMES' | 'REPLACE_ID_AND_NAME_FROM_PARTS': Specifies the behavior for automatically generated names when registering an entity. - NEW_IDS: Generate new registry IDs - IDS_FROM_NAMES: Generate registry IDs based on entity names - DELETE_NAMES: Generate new registry IDs and replace name with registry ID - SET_FROM_NAME_PARTS: Generate new registry IDs, rename according to name template, and keep old name as alias - REPLACE_NAMES_FROM_PARTS: Generate new registry IDs, and replace name according to name template - KEEP_NAMES: Keep existing entity names as registry IDs - REPLACE_ID_AND_NAME_FROM_PARTS: Generate registry IDs and names according to name template
  - `registryId` string: Registry ID into which entity should be registered. this is the ID of the registry which was configured for a particular organization To get available registryIds, use the [/registries endpoint](https://docs.benchling.com/docs/api/v2/benchling-api/registry/list-registries) Required in order for entities to be created directly in the registry.

## Response `201`

Created

- Mixture
  - `aliases` string[]
  - `allowMeasuredIngredients` boolean: Derived from the mixture's schema.
  - `amount` string: The positive numerical amount value of this mixture in string format (to preserve full precision). Pair with `units`. Supports scientific notation (1.23e4).
  - `apiURL` string, uri: The canonical url of the Mixture in the API.
  - `archiveRecord` ArchiveRecord
    - `reason` string
  - `authors` UserSummary[]
    - `handle` string
    - `id` string
    - `name` string
  - `createdAt` string, date-time
  - `creator` MixtureCreator
    - `handle` string
    - `id` string
    - `name` string
  - `customFields` CustomFields
  - `entityRegistryId` string, nullable
  - `fields` Fields
  - `folderId` string, nullable
  - `id` string
  - `ingredients` Ingredient[]: List of ingredients on this mixture.
    - `amount` string, nullable: The amount value of this ingredient in its mixture, in string format (to preserve full precision). Pair with `units`. Supports scientific notation (1.23e4). One ingredient on this mixture can have an amount value of `"QS"`.
    - `catalogIdentifier` string, nullable
    - `componentEntity` IngredientComponentEntity: The entity that uniquely identifies this component.
      - `entityRegistryId` string, nullable
      - `id` string
      - `name` string
    - `componentLotContainer` ContainerLabels
      - `barcode` string
      - `id` string
      - `name` string
    - `componentLotEntity` EntityLabels
      - `entityRegistryId` string, nullable
      - `id` string
      - `name` string
    - `componentLotText` string, nullable: Text representing the component lot for this ingredient. This is only present if the mixture schema supports component lots in "text" format.
    - `hasParent` boolean
    - `notes` string, nullable
    - `targetAmount` string, nullable: The target amount for this ingredient such that this ingredient's proportion in its mixture would preserve the equivalent ingredient's proportion in the parent mixture. Pair with `units`.
    - `units` 'nL' | 'uL' | 'mL' | 'L' | 'mg' | 'g' | 'kg' | 'ug' | 'Units' | 'Cells' | 'mol' | 'mmol' | 'umol'
  - `modifiedAt` string, date-time
  - `name` string
  - `registrationOrigin` RegistrationOrigin
    - `originEntryId` string, nullable
    - `registeredAt` string, date-time
  - `registryId` string, nullable
  - `schema` SchemaSummary
    - `id` string
    - `name` string
  - `units` 'nL' | 'uL' | 'mL' | 'L' | 'g' | 'kg' | 'mg' | 'ug' | 'Units'
  - `webURL` string

## Other responses

- `400`: Bad Request
- `503`: Deprecated, a 429 is returned for too many requests

---

[API](https://skmtc.dev/benchling/apis/benchling-api-2.md) - [All operations](https://skmtc.dev/benchling/apis/benchling-api-2/llms.txt) - [OpenAPI document](https://skmtc.dev/benchling/apis/benchling-api-2/revisions/01d2fa8523cd?raw)
