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

# Create Project

> Creates a new project. You can add users, specify the cluster, timezone, currency, and other details.

All owners are added to the project by default.



## OpenAPI

````yaml /openapi/management.json post /management/v1/projects
openapi: 3.0.1
info:
  title: Voucherify API - Management
  version: v2018-08-01
  description: >-
    Voucherify promotion engine REST API. Please see
    https://docs.voucherify.io/docs for more details.
  contact:
    name: Voucherify Team
    url: https://www.voucherify.io/contact-support
    email: support@voucherify.io
  termsOfService: https://www.voucherify.io/legal/subscription-agreement
  license:
    name: MIT
    url: https://github.com/voucherifyio/voucherify-js-sdk/blob/main/LICENSE
servers:
  - url: https://{cluster}.voucherify.io
    description: Base URL
    variables:
      cluster:
        default: api
        enum:
          - api
          - us1.api
          - as1.api
          - download
          - us1.download
          - as1.download
security: []
paths:
  /management/v1/projects:
    post:
      tags:
        - Management
      summary: Create Project
      description: >-
        Creates a new project. You can add users, specify the cluster, timezone,
        currency, and other details.


        All owners are added to the project by default.
      operationId: create-project
      parameters: []
      requestBody:
        description: Define project details.
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ManagementProjectsCreateRequestBody'
        required: true
      responses:
        '200':
          description: Returns the details of a created project.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ManagementProjectsCreateResponseBody'
              examples:
                Example:
                  value:
                    id: proj_V0uCh3RiFy
                    name: Voucherify Team Project
                    currency: EUR
                    timezone: UTC
                    cluster_id: eu1
                    api_version: v2018-08-01
                    case_sensitive_codes: true
                    client_trusted_domains: []
                    client_redeem_enabled: false
                    client_publish_enabled: false
                    client_list_vouchers_enabled: false
                    client_create_customer_enabled: false
                    client_loyalty_events_enabled: false
                    client_set_voucher_expiration_date_enabled: false
                    api_usage_notifications:
                      messages:
                        value: 80
                        emails:
                          - your.email@your.domain
                        in_app: true
                        enabled: true
                      api_calls:
                        value: 80
                        emails:
                          - your.email@your.domain
                        in_app: true
                        enabled: true
                      cycle_calls:
                        value: 80
                        emails:
                          - your.email@your.domain
                        in_app: true
                        enabled: true
                      redemptions:
                        value: 80
                        emails: []
                        in_app: false
                        enabled: false
                      webhook_calls:
                        value: 80
                        emails:
                          - your.email@your.domain
                        in_app: true
                        enabled: true
                      bulk_api_calls:
                        value: 80
                        emails:
                          - your.email@your.domain
                        in_app: true
                        enabled: true
                    webhooks_callout_notifications:
                      webhooks:
                        email: true
                        emails:
                          - your.email@your.domain
                        in_app: true
                      distributions:
                        email: true
                        emails:
                          - your.email@your.domain
                        in_app: true
                    is_sandbox: false
                    webhook_version: v2024-01-01
        '400':
          description: >-
            Returns an error if the payload is missing required properties in
            the request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/e_400_invalid_payload'
              examples:
                Invalid payload:
                  value:
                    code: 400
                    key: invalid_payload
                    message: Invalid payload
                    details: Payload must have required property 'name'
                    request_id: v-0e9389ccac8da56f55
        '401':
          description: Returns an error if an invalid token was provided.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
              examples:
                Unauthorized:
                  value:
                    code: 401
                    message: Unauthorized
                    key: unauthorized
        '402':
          description: >-
            Returns an error if the current plan does not include the Management
            API feature.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorPaymentRequired'
              examples:
                Example:
                  value:
                    code: 402
                    message: Payment required
                    details: >-
                      Your current plan does not include a feature required to
                      perform this operation.
                    key: missing_required_feature
        '403':
          description: >-
            Returns an error if the project is to be created in a cluster that
            is unavailable to the user.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProjectBoundError'
              examples:
                Example:
                  value:
                    code: 403
                    key: forbidden
                    message: Forbidden
                    details: Project is bound to different region
                    request_id: v-0e938b8738000cc714
      security:
        - X-Management-Id: []
          X-Management-Token: []
components:
  schemas:
    ManagementProjectsCreateRequestBody:
      type: object
      title: Management Project Create Request Body
      description: Request body schema for **POST** `/management/v1/projects`.
      allOf:
        - type: object
          properties:
            case_sensitive_codes:
              type: boolean
              description: >-
                Determines if the vouchers in the project will be case sensitive
                (if `true`, `C0dE-cfV` is not equal to `c0de-cfv`) or case
                insensitive (if false, `C0dE-cfV` is equal to `c0de-cfv`).
        - $ref: '#/components/schemas/ManagementProjectBase'
        - type: object
          properties:
            api_usage_notifications:
              type: object
              title: API Usage Notifications
              description: Determines the notification settings.
              properties:
                messages:
                  type: object
                  description: >-
                    Determines the notification settings for distributed
                    messages according to the day and month limit. The
                    notification can be used as a warning that a limit will be
                    reached soon.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                api_calls:
                  type: object
                  description: >-
                    Determines the notification settings for API calls made for
                    the hourly limit. The notification can be used as a warning
                    that a limit will be reached soon. It is sent maximum once
                    per hour.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                bulk_api_calls:
                  type: object
                  description: >-
                    Determines the notification settings for bulk API calls made
                    for the hourly limit. The notification can be used as a
                    warning that a limit will be reached soon. It is sent
                    maximum once per hour.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                webhook_calls:
                  type: object
                  description: >-
                    Determines the notification settings for webhook calls made
                    for the daily limit. The notification can be used as a
                    warning that a limit will be reached soon. It is sent
                    maximum four times a day.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                cycle_calls:
                  type: object
                  description: >-
                    Determines the notification settings for API calls made for
                    the billing cycle limit. The notification can be used as a
                    warning that a limit will be reached soon. It is sent
                    maximum once per the billing cycle.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
              required:
                - redemptions
                - messages
                - api_calls
                - bulk_api_calls
                - webhook_calls
                - cycle_calls
            cluster_id:
              type: string
              description: >-
                The identifier of the cluster where the project will be created.
                The default cluster is `eu1` unless otherwise configured.
            api_version:
              type: string
              description: >-
                The API version used in the project. Currently, the default and
                only value is `v2018-08-01`.
              default: v2018-08-01
              enum:
                - v2018-08-01
            users:
              type: array
              description: >-
                The users (their identifiers, logins, and roles) who will be
                assigned to the project. You can assign only existing Voucherify
                users.


                It must be used either in the following combinations:

                - `id` and `role`, or

                - `login` and `role`.
              items:
                title: Create Project Users
                type: object
                description: >-
                  Contains details about the users who will be assigned to the
                  project.

                  Only the `id` and `role` or `login` and `role` should be
                  provided in the request.
                properties:
                  id:
                    type: string
                    description: >-
                      The unique identifier of the user who will be assigned to
                      the project. It can be found in Team Settings > Team >
                      Edit member. **Required** with the `role` string.


                      Do **not** use with the `login` string.
                  login:
                    type: string
                    description: >-
                      The login data of the user who will be assigned to the
                      project. **Required** with the `role` string.


                      Do **not** use with the `id` string.
                  role:
                    type: string
                    description: >-
                      The role of the user to be added. It can be one of the
                      following predefined roles:

                      `ADMIN`, `USER`, `VIEWER`, `MERCHANT`

                      or an ID of a custom role.
                required:
                  - role
      required:
        - name
        - case_sensitive_codes
        - timezone
        - currency
    ManagementProjectsCreateResponseBody:
      type: object
      title: Management Project Create Response Body
      description: Response body schema for **POST** `management/v1/projects`.
      allOf:
        - $ref: '#/components/schemas/ManagementProjectBaseWithConfig'
        - $ref: '#/components/schemas/ManagementProjectsAPIKeys'
    e_400_invalid_payload:
      title: Invalid Payload
      type: object
      description: 'Error: Bad Request &rarr; Invalid Payload'
      properties:
        code:
          type: integer
          default: 400
          description: Error's HTTP status code.
        key:
          type: string
          default: invalid_payload
          description: Short string describing the kind of error which occurred.
        message:
          type: string
          default: Invalid payload
          description: A human-readable message providing a short description of the error.
        details:
          type: string
          description: A human-readable message providing more details about the error.
        request_id:
          type: string
          example: v-0a884c6be8c3756f42
          description: >-
            This ID is useful when troubleshooting and/or finding the root cause
            of an error response by our support team.
    Error:
      title: Error Object
      type: object
      description: Error details
      properties:
        code:
          type: integer
          description: Error's HTTP status code.
        key:
          type: string
          description: Short string describing the kind of error which occurred.
        message:
          type: string
          description: A human-readable message providing a short description of the error.
        details:
          type: string
          description: A human-readable message providing more details about the error.
        request_id:
          type: string
          example: v-0a885062c80375740f
          description: >-
            This ID is useful when troubleshooting and/or finding the root cause
            of an error response by our support team.
        resource_id:
          type: string
          description: >-
            Unique resource ID that can be used in another endpoint to get more
            details.
          example: rf_0c5d710a87c8a31f86
        resource_type:
          type: string
          description: The resource type.
          example: voucher
        error:
          type: object
          description: Includes additional information about the error.
          properties:
            message:
              type: string
              description: The message configured by the user in a validation rule.
      required:
        - code
        - message
    ErrorPaymentRequired:
      title: Payment Required Error
      type: object
      description: 'Error: Payment required - the current plan does not include the feature.'
      properties:
        code:
          type: integer
          description: Error's HTTP status code.
        message:
          type: string
          description: A human-readable message providing a short description of the error.
        details:
          type: string
          description: A human-readable message providing more details about the error.
        key:
          type: string
          description: Short string describing the kind of error which occurred.
      required:
        - code
        - message
        - details
        - key
    ProjectBoundError:
      title: Error Object
      type: object
      description: Error details
      properties:
        code:
          type: integer
          description: Error's HTTP status code.
        key:
          type: string
          description: Short string describing the kind of error which occurred.
        message:
          type: string
          description: A human-readable message providing a short description of the error.
        details:
          type: string
          description: A human-readable message providing more details about the error.
        request_id:
          type: string
          example: v-0a96c19b1a41c03999
          description: >-
            This ID is useful when troubleshooting and/or finding the root cause
            of an error response by Voucherify support team.
    ManagementProjectBase:
      type: object
      title: Management Project Base
      properties:
        name:
          type: string
          description: The name of the project.
        description:
          type: string
          description: >-
            A user-defined description of the project, e.g. its purpose, scope,
            region.
        timezone:
          type: string
          description: >-
            The time zone in which the project is established. It can be in the
            GMT format or in accordance with IANA time zone database.
        currency:
          type: string
          description: >-
            The currency used in the project. It is equal to a 3-letter ISO 4217
            code.
        dial_code:
          type: string
          nullable: true
          description: >-
            The country dial code for the project. It is equal to an ITU country
            code.
        webhook_version:
          type: string
          description: The webhook version used in the project.
          default: v2024-01-01
          enum:
            - v2024-01-01
        client_trusted_domains:
          type: array
          description: An array of URL addresses that allow client requests.
          items:
            type: string
        client_redeem_enabled:
          type: boolean
          description: Enables client-side redemption.
        client_publish_enabled:
          type: boolean
          description: Enables client-side publication.
        client_list_vouchers_enabled:
          type: boolean
          description: Enables client-side listing of vouchers.
        client_create_customer_enabled:
          type: boolean
          description: Enables client-side creation of customers.
        client_loyalty_events_enabled:
          type: boolean
          description: Enables client-side events for loyalty and referral programs.
        client_set_voucher_expiration_date_enabled:
          type: boolean
          description: Enables client-side setting of voucher expiration date.
        webhooks_callout_notifications:
          type: object
          title: Webhook callout notification details
          description: >-
            Determines the notification settings for webhook callouts configured
            in Distributions and Project settings.
          properties:
            distributions:
              type: object
              description: >-
                Determines the notification settings for webhooks sent through
                Distributions.
              properties:
                email:
                  type: boolean
                  description: Enables the notification through an email.
                in_app:
                  type: boolean
                  description: Enables the notification through an email.
                emails:
                  type: array
                  description: >-
                    An array of email addresses which will receive the
                    notification.
                  items:
                    type: string
              required:
                - email
                - in_app
                - emails
            webhooks:
              type: object
              description: >-
                Determines the notification settings for webhooks sent as set
                out in the Project settings.
              properties:
                email:
                  type: boolean
                  description: Enables the notification through an email.
                in_app:
                  type: boolean
                  description: Enables the notification through an email.
                emails:
                  type: array
                  description: >-
                    An array of email addresses which will receive the
                    notification.
                  items:
                    type: string
              required:
                - email
                - in_app
                - emails
          required:
            - distributions
            - webhooks
    UsageNotifications:
      type: object
      title: Usage notification details
      properties:
        enabled:
          type: boolean
          description: Enables the notification.
        value:
          type: integer
          minimum: 10
          maximum: 90
          description: >-
            The percent value of the limit which, when reached, triggers the
            notification.
        in_app:
          type: boolean
          description: Enables the notification in the application.
        emails:
          type: array
          title: Email address
          description: An array of email addresses which will receive the notification.
          items:
            type: string
      required:
        - enabled
        - value
        - emails
        - in_app
    ManagementProjectBaseWithConfig:
      type: object
      description: Object representing a project.
      allOf:
        - type: object
          properties:
            id:
              type: string
              description: Unique identifier of the project.
        - $ref: '#/components/schemas/ManagementProjectBase'
        - type: object
          properties:
            api_usage_notifications:
              type: object
              title: API Usage Notifications
              description: Determines the notification settings.
              properties:
                redemptions:
                  type: object
                  description: >-
                    Determines the notification settings for redemptions. The
                    notification can be used as a warning that a limit will be
                    reached soon.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                messages:
                  type: object
                  description: >-
                    Determines the notification settings for distributed
                    messages according to the day and month limit. The
                    notification can be used as a warning that a limit will be
                    reached soon.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                api_calls:
                  type: object
                  description: >-
                    Determines the notification settings for API calls made for
                    the hourly limit. The notification can be used as a warning
                    that a limit will be reached soon. It is sent maximum once
                    per hour.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                bulk_api_calls:
                  type: object
                  description: >-
                    Determines the notification settings for bulk API calls made
                    for the hourly limit. The notification can be used as a
                    warning that a limit will be reached soon. It is sent
                    maximum once per hour.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                webhook_calls:
                  type: object
                  description: >-
                    Determines the notification settings for webhook calls made
                    for the daily limit. The notification can be used as a
                    warning that a limit will be reached soon. It is sent
                    maximum four times a day.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
                cycle_calls:
                  type: object
                  description: >-
                    Determines the notification settings for API calls made for
                    the billing cycle limit. The notification can be used as a
                    warning that a limit will be reached soon. It is sent
                    maximum once per the billing cycle.
                  allOf:
                    - $ref: '#/components/schemas/UsageNotifications'
              required:
                - redemptions
                - messages
                - api_calls
                - bulk_api_calls
                - webhook_calls
                - cycle_calls
            cluster_id:
              type: string
              description: The identifier of the cluster where the project will be created.
            case_sensitive_codes:
              type: boolean
              description: >-
                Determines if the vouchers in the project will be:

                - case sensitive - if `true`, `C0dE-cfV` is **not** equal to
                `c0de-cfv`),

                - case insensitive - if `false`, `C0dE-cfV` is equal to
                `c0de-cfv`.
            api_version:
              type: string
              description: >-
                The API version used in the project. Currently, the default and
                only value is `v2018-08-01`.
              default: v2018-08-01
              enum:
                - v2018-08-01
            is_sandbox:
              type: boolean
              description: Determines if the project is a sandbox project.
            webhook_token:
              type: string
              description: Webhook token used for authentication.
      required:
        - id
        - name
        - description
        - currency
        - timezone
        - cluster_id
        - api_version
        - case_sensitive_codes
        - client_trusted_domains
        - client_redeem_enabled
        - client_publish_enabled
        - client_list_vouchers_enabled
        - client_create_customer_enabled
        - client_loyalty_events_enabled
        - client_set_voucher_expiration_date_enabled
        - api_usage_notifications
        - webhooks_callout_notifications
        - is_sandbox
        - webhook_version
        - webhook_token
    ManagementProjectsAPIKeys:
      type: object
      title: Project and Side Keys
      description: >-
        Returns `app_id` and `app_token` for the server-side and client-side
        authentication.
      properties:
        server_side_key:
          type: object
          title: Server-side key
          description: >-
            Contains the `app_id` and `app_token` to authenticate server-side
            requests.
          properties:
            app_id:
              type: string
              title: Application ID
              description: >-
                Application ID to be used as `X-App-Id` header in every HTTP
                request.
            app_token:
              type: string
              title: Application token
              description: >-
                Application token to be used as `X-App-Token` header in every
                HTTP request.


                The application token (secret key) for the server-side
                authentication is visible in the Project Settings for 14 days
                when it is first generated in a newly-created project. Write
                your application token down and keep it in a safe place.
        client_side_key:
          type: object
          title: Client-side key
          description: >-
            Contains the `app_id` and `app_token` to authenticate client-side
            requests.
          properties:
            app_id:
              type: string
              title: Application ID
              description: >-
                Application ID to be used as `X-App-Id` header in every HTTP
                request.
            app_token:
              type: string
              title: Application token
              description: >-
                Application token to be used as `X-App-Token` header in every
                HTTP request.


                The application token (secret key) for the client-side
                authentication is visible in the Project Settings for 14 days
                when it is first generated in a newly-created project. Write
                your application token down and keep it in a safe place.
  securitySchemes:
    X-Management-Id:
      type: apiKey
      name: X-Management-Id
      in: header
    X-Management-Token:
      type: apiKey
      name: X-Management-Token
      in: header

````