GitLab API

GitlabTool

Actions1095

Feature_flags → postApiV4ProjectsIdFeatureFlags

AI-generated

Summary

Create a new feature flag for a specified GitLab project by sending a POST request to the /api/v4/projects/{id}/feature_flags endpoint.

Inputs

  • id (required) — The ID or URL-encoded path of the GitLab project where the feature flag will be created.
  • postApiV4ProjectsIdFeatureFlags (required) — The request body containing the feature flag details according to the postApiV4ProjectsIdFeatureFlags schema.
  • baseUrl — Optional base URL of the GitLab instance, defaults to https://gitlab.com.
  • skipAuthentication — Boolean flag to skip authentication; defaults to false.

Output shape

a JSON object representing the created feature flag returned by the GitLab API

The output includes the full feature flag details as returned from the API. Authentication is required unless explicitly skipped. The project ID path parameter and request body are mandatory.

Examples

Example 1: Create feature flag in a project

Provide the project 'id' and full feature flag details in the request body, optionally changing baseUrl; authentication is used by default.

Links

Discussion