Skip to main content

create_feature

Create a feature from a name and Gherkin source (Feature: + Scenario:s). It starts as draft — generate its tests afterwards with generate_feature.

Request

POST /api/v1/ops/projects/{project}/features
ParameterInTypeRequiredDescription
projectpathstringyesThe project's public id.
namebodystringyesThe feature name.
gherkinbodystringyesThe Gherkin source.
curl -X POST -H "Authorization: Bearer $TESTVIBE_API_KEY" \
-H "Content-Type: application/json" \
-d '{"name": "Login Functionality", "gherkin": "Feature: Login Functionality\n Scenario: Valid user signs in\n ..."}' \
"$TESTVIBE_SERVER/api/v1/ops/projects/$PROJECT/features"

Response

201 Created

{ "id": 12 }

Errors

HTTPWhen
400 invalid_requestMissing name or Gherkin, or malformed JSON.
404 not_foundNo such project in this workspace.