Skip to content
For the complete documentation index, see llms.txt. This page is also available as Markdown.

Project

This contains APIs related to Project as defined in Harness

List all Projects for a user

get

Lists all Projects the user is a member of by using the user's API key token.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization Identifier for the Entity.

hasModulebooleanOptional

This boolean specifies whether to Filter Projects which has the Module of type passed in the module type parameter or to Filter Projects which does not has the Module of type passed in the module type parameter

Default: true
identifiersstring[]Optional

This is the list of Project IDs. Details specific to these IDs would be fetched.

moduleTypestring · enumOptional

Filter Projects by module type

Possible values:
searchTermstringOptional

This would be used to filter Projects. Any Project having the specified string in its Name, ID and Tag would be filtered.

onlyFavoritesbooleanOptionalDefault: false
pageIndexinteger · int32Optional

Page Index of the results to fetch.Default Value: 0

Default: 0
pageSizeinteger · int32 · max: 100Optional

Results per page(max 100)Default Value: 50

Default: 50
pageTokenstringOptional

Page Token of the next results to fetch.Default Value: ''

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/projects
GET /gateway/ng/api/projects?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Create a Project

post

Creates a new Harness Project.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization identifier for the Project. If left empty, the Project is created under Default Organization

Default: default
Body
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
post/projects
POST /gateway/ng/api/projects?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 165

{
  "project": {
    "orgIdentifier": "text",
    "identifier": "text",
    "name": "text",
    "color": "text",
    "modules": [
      "CD"
    ],
    "description": "text",
    "tags": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    }
  }
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

List Project details

get

Lists a Project's details for the given ID.

Path parameters
identifierstringRequired

Project Identifier for the Entity.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization identifier for the project. If left empty, Default Organization is assumed

Default: default
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/projects/{identifier}
GET /gateway/ng/api/projects/{identifier}?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Update a Project

put

Updates Project details for the given ID.

Path parameters
identifierstringRequired

Project Identifier for the Entity.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

Organization identifier for the Project. If left empty, Default Organization is assumed

Default: default
Header parameters
If-MatchstringOptional

Version number of Project

Body
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
put/projects/{identifier}
PUT /gateway/ng/api/projects/{identifier}?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Content-Type: application/json
Accept: */*
Content-Length: 165

{
  "project": {
    "orgIdentifier": "text",
    "identifier": "text",
    "name": "text",
    "color": "text",
    "modules": [
      "CD"
    ],
    "description": "text",
    "tags": {
      "ANY_ADDITIONAL_PROPERTY": "text"
    }
  }
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Delete a Project

delete

Deletes a Project corresponding to the given ID.

Path parameters
identifierstringRequired

Project Identifier for the Entity.

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifierstringOptional

This is the Organization Identifier for the Project. By default, the Default Organization's Identifier is considered.

Default: default
Header parameters
If-MatchstringOptional

Version number of Project

Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
delete/projects/{identifier}
DELETE /gateway/ng/api/projects/{identifier}?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

List user's project with support to filter by multiple organizations

get
Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

orgIdentifiersstring[]Optional

List of Organization Identifiers for the Entities.

hasModulebooleanOptional

This boolean specifies whether to Filter Projects which has the Module of type passed in the module type parameter or to Filter Projects which does not has the Module of type passed in the module type parameter

Default: true
identifiersstring[]Optional

This is the list of Project Identifiers. Details specific to these IDs would be fetched.

moduleTypestring · enumOptional

Filter Projects by module type

Possible values:
searchTermstringOptional

Filter Projects by searching for this word in Name, Id, and Tag

onlyFavoritesbooleanOptionalDefault: false
pageIndexinteger · int32Optional

Page Index of the results to fetch.Default Value: 0

Default: 0
pageSizeinteger · int32 · max: 100Optional

Results per page(max 100)Default Value: 50

Default: 50
pageTokenstringOptional

Page Token of the next results to fetch.Default Value: ''

withFavoritesInfobooleanOptionalDefault: true
Responses
400

Bad Request

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/projects/list
GET /gateway/ng/api/projects/list?accountIdentifier=text HTTP/1.1
Host: ng-manager-7b6bb5bdbc-5jxjn
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Last updated

Was this helpful?