# Create Variant

Creates a new Variant resource from the supplied JSON body and returns its location in the Location header.
            
## Authentication
            
Requires a valid API key in the X-API-KEY header.
            
## Headers
            
### Accept-Language
            
Culture used to interpret the localized field values supplied in the request body.
- omitted / null: tenant's default culture.
- culture-code (e.g. en-US, es): the specified culture.
            
## Request Body
            
A single JSON object whose properties match the writable fields published by
/Variants/$metadata. The body is normalized before reaching the application layer:
            
- Must be a non-empty JSON object.
- A JSON array is accepted only if it contains exactly one element.
- Values are coerced to CLR primitives (string, long, double, bool, null),
  nested objects and arrays.
            
## Response
            
201 Created — The Location header points to the new resource: /Variants({id}).
No response body.
            
## Error Responses
            
- 400 Bad Request — Payload normalization or validation failure (empty body,
  multi-element array, invalid field values, etc.). Validation errors are returned
  as ValidationFailureRepresentation.
- 401 Unauthorized — Missing or invalid API key.
- 404 Not Found — Tenant or referenced Product resource not found.
- 500 Internal Server Error — Unexpected technical error.
            
## Example
            
Request:
http
POST /Variants HTTP/1.1
X-API-KEY: your-api-key-here
Accept-Language: en-US
Content-Type: application/json
            
{
  "frmt_ref": "SKU-001-RED-M",
  "prod_id": 456
}

            
Response:
http
HTTP/1.1 201 Created
Location: /Variants(789)

Endpoint: POST /Variants
Version: 2.0.0

## Header parameters:

  - `X-API-KEY` (string)
    Tenant's API key (required)

  - `Accept-Language` (string)
    Culture for localized field values in the request body (Accept-Language header)

## Response 200 fields (application/json):

  - `readLink` (object)

  - `readLink.uri` (string,null)

  - `value` (any,null)

## Response 400 fields (application/json):

  - `validationFailures` (object,null)
    Example: {"Layout":[{"PropertyName":"Layout","ErrorMessage":"The layout must contain exactly the attributes of the stored layout. Missing: tags. Unknown: extra_field.","AttemptedValue":null}]}

## Response 401 fields (application/json):

  - `type` (string,null)

  - `title` (string,null)

  - `status` (integer,null)

  - `detail` (string,null)

  - `instance` (string,null)

## Response 500 fields (application/json):

  - `error` (string,null)

  - `details` (any,null)


