---
title: "Create Elements Config"
method: POST
path: "/v2/elements/{proj_id}/{env_id}/config"
tags: ["Elements Configs (EAP)"]
---

# Create Elements Config

`POST /v2/elements/{proj_id}/{env_id}/config`

Creates a new elements_config under the active organization.

## Path parameters

- `proj_id` string, required — Either the unique id of the project, or the URL-friendly key of the project (i.e: the "slug").
- `env_id` string, required — Either the unique id of the environment, or the URL-friendly key of the environment (i.e: the "slug").

## Request body

- ElementsConfigCreate
  - `key` string, required — A URL-friendly name of the elements_config (i.e: slug). You will be able to query later using this key instead of the id (UUID) of the elements_config.
  - `name` string, required — The name of the elements_config
  - `elements_type` 'user_management' | 'audit_log' | 'approval_flow' | 'operation_approval' | 'approval_management', required — An enumeration.
  - `settings` object, required — Obj with the options of the elements interface, e.g: primary color
  - `email_notifications` boolean — Whether to send email notifications to users using your Email Provider you set
  - `roles_to_levels` object, required — Obj with levels as keys and role ids as values
  - `webhook` WebhookCreateWithElements
    - `type` 'elements'
    - `url` string, required — The url to POST the webhook to
    - `bearer_token` string — An optional bearer token to use to authenticate the request

## Response `200`

Successful Response

- ElementsConfigRead
  - `key` string, required — A URL-friendly name of the elements_config (i.e: slug). You will be able to query later using this key instead of the id (UUID) of the elements_config.
  - `id` string, uuid, required — Unique id of the elements_config
  - `organization_id` string, uuid, required — Unique id of the organization that the elements_config belongs to.
  - `project_id` string, uuid, required — Unique id of the project that the elements_config belongs to.
  - `environment_id` string, uuid, required — Unique id of the environment that the elements_config belongs to.
  - `created_at` string, date-time, required — Date and time when the elements_config was created (ISO_8601 format).
  - `updated_at` string, date-time, required — Date and time when the elements_config was last updated/modified (ISO_8601 format).
  - `is_active` boolean, required
  - `name` string, required — The name of the elements_config
  - `elements_type` 'user_management' | 'audit_log' | 'approval_flow' | 'operation_approval' | 'approval_management', required — An enumeration.
  - `settings` object, required — Obj with the options of the elements interface, e.g: primary color
  - `email_notifications` boolean — Whether to send email notifications to users using your Email Provider you set
  - `roles_to_levels` object, required — Obj with levels as keys and role ids as values
  - `webhook` WebhookRead
    - `type` 'elements' | 'pdp_sync_error', required — An enumeration.
    - `id` string, uuid, required — Unique id of the webhook
    - `organization_id` string, uuid, required — Unique id of the organization that the webhook belongs to.
    - `project_id` string, uuid, required — Unique id of the project that the webhook belongs to.
    - `environment_id` string, uuid, required — Unique id of the environment that the webhook belongs to.
    - `created_at` string, date-time, required — Date and time when the webhook was created (ISO_8601 format).
    - `updated_at` string, date-time, required — Date and time when the webhook was last updated/modified (ISO_8601 format).
    - `url` string, required — The url to POST the webhook to

## Other responses

- `422` — Validation Error

---

[API](https://skmtc.net/permit/apis/permit-io-api.md) · [All operations](https://skmtc.net/permit/apis/permit-io-api/llms.txt) · [OpenAPI document](https://skmtc-service-staging.skmtc.workers.dev/v1/apis/permit/permit-io-api/versions/dd6be355a62e/schema)
