Skip to main content

Create project

POST 

/api/admin/projects

Create a new Unleash project.

Request

Body

required

createProjectSchema

    id stringdeprecated

    The project's identifier. If this property is not present or is an empty string, Unleash will generate the project id automatically. This property is deprecated.

    Possible values: Value must match regular expression [A-Za-z0-9_~.-]*

    Example: pet-shop
    name stringrequired

    The project's name. The name must contain at least one non-whitespace character.

    Possible values: Value must match regular expression ^(?!\s*$).+

    Example: Pet shop
    description stringnullable

    The project's description.

    Example: This project contains features related to the new pet shop.
    mode string

    A mode of the project affecting what actions are possible in this project

    Possible values: [open, protected, private]

    Default value: open
    Example: open
    defaultStickiness string

    A default stickiness for the project affecting the default stickiness value for variants and Gradual Rollout strategy

    Default value: default
    Example: userId
    environments string[]

    A list of environments that should be enabled for this project. When provided, the list must contain at least one environment. If this property is missing, Unleash will default to enabling all non-deprecated environments for the project.

    Possible values: >= 1

    Example: ["production","development"]

    changeRequestEnvironments

    object[]

    A list of environments that should have change requests enabled. If the list includes environments not in the environments list, they will still have change requests enabled.

  • Array [

  • name stringrequired

    The name of the environment to configure change requests for.

    Example: production
    requiredApprovals integer

    The number of approvals required for a change request to be fully approved and ready to applied in this environment. If no value is provided, it will be set to the default number, which is 1. Values will be clamped to between 1 and 10 inclusive.

    Default value: 1
    Example: 3
  • ]

Responses

The resource was successfully created.

Response Headers

  • location

    string

    The location of the newly created resource.

Schema

    id stringrequired

    The project's identifier.

    Possible values: Value must match regular expression [A-Za-z0-9_~.-]+

    Example: pet-shop
    name stringrequired

    The project's name.

    Possible values: non-empty

    Example: Pet shop
    description stringnullable

    The project's description.

    Example: This project contains features related to the new pet shop.
    featureLimit integernullable

    A limit on the number of features allowed in the project. null if no limit.

    Example: 100
    mode string

    A mode of the project affecting what actions are possible in this project

    Possible values: [open, protected, private]

    Example: open
    defaultStickiness string

    A default stickiness for the project affecting the default stickiness value for variants and Gradual Rollout strategy

    Example: userId
    environments string[]

    The environments enabled for the project.

    Possible values: >= 1

    Example: ["production","staging"]

    changeRequestEnvironments

    object[]

    The list of environments that have change requests enabled.

  • Array [

  • name stringrequired

    The name of the environment this change request configuration applies to.

    Example: production
    requiredApprovals integerrequired

    The number of approvals required for a change request to be fully approved and ready to applied in this environment. If no value is provided, it will be set to the default number, which is 1. The value must be greater than or equal to 1.

    Possible values: >= 1

    Default value: 1
    Example: 3
  • ]

Loading...