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

Cost Categories

Allows you to categorize based on business requirements and get a contextual view of your expenses.

Fetch details of a Cost category

get

Retrieve a specific Cost Category by its unique identifier. Returns the complete Cost Category configuration including all cost buckets, shared costs, and rule definitions.

Path parameters
idstringRequired
Query parameters
accountIdentifierstringOptional
Responses
400

Bad Request

application/json

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/business-mapping/{id}
GET /gateway/ccm/api/business-mapping/{id} HTTP/1.1
Host: nextgen-ce-d788d786-ssnpc
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Delete a Cost category

delete

Delete a Cost Category by its unique identifier. The deletion will fail if the Cost Category is currently used in any Perspectives. Returns a list of linked Perspectives if deletion is blocked.

Path parameters
idstringRequired
Query parameters
accountIdentifierstringRequired
Responses
400

Bad Request

application/json

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
delete/business-mapping/{id}
DELETE /gateway/ccm/api/business-mapping/{id}?accountIdentifier=text HTTP/1.1
Host: nextgen-ce-d788d786-ssnpc
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Get (cost-categories)/(cost buckets) for recommendation filter panel

get

Get (cost-categories)/(cost buckets) for recommendation filter panel

Query parameters
accountIdentifierstringRequired

Account Identifier for the Entity.

costCategorystringOptional
searchstringOptional
Responses
400

Bad Request

application/json

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/business-mapping/filter-panel
GET /gateway/ccm/api/business-mapping/filter-panel?accountIdentifier=text HTTP/1.1
Host: nextgen-ce-d788d786-ssnpc
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Return details of all the Cost categories

get

List all Cost Categories for your account with support for search, sorting, and pagination. Use this endpoint to browse and discover existing Cost Categories and their configurations.

Query parameters
accountIdentifierstringOptional
searchKeystringOptional
sortTypestring · enumOptionalPossible values:
sortOrderstring · enumOptionalPossible values:
limitinteger · int32Optional
offsetinteger · int32Optional
Responses
400

Bad Request

application/json

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
get/business-mapping
GET /gateway/ccm/api/business-mapping HTTP/1.1
Host: nextgen-ce-d788d786-ssnpc
Accept: */*
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Create a Cost Category

post

Create a Cost Category to organize and allocate cloud and AI costs based on your business structure. Define custom rules and cost buckets to automatically categorize expenses by teams, projects, environments, or any business dimension. Cost Categories enable accurate cost allocation, chargeback, and financial reporting across your organization.

Query parameters
accountIdentifierstringOptional
Body
uuidstringOptional
namestring · min: 1 · max: 32RequiredPattern: ^[^\d][^'"\\]*$
accountIdstringRequired
supportsTagNormalizationbooleanOptional
createdAtinteger · int64Optional
lastUpdatedAtinteger · int64Optional
Responses
400

Bad Request - Invalid Cost Category definition

No content

post/business-mapping
POST /gateway/ccm/api/business-mapping HTTP/1.1
Host: nextgen-ce-d788d786-ssnpc
Content-Type: application/json
Accept: */*
Content-Length: 286

{
  "name": "Engineering Teams",
  "accountId": "acc_xyz789",
  "costBuckets": [
    {
      "name": "Backend Team",
      "rules": [
        {
          "conditions": [
            {
              "type": "LABEL",
              "key": "team",
              "value": "backend"
            }
          ]
        }
      ]
    },
    {
      "name": "Frontend Team",
      "rules": [
        {
          "conditions": [
            {
              "type": "LABEL",
              "key": "team",
              "value": "frontend"
            }
          ]
        }
      ]
    }
  ],
  "sharedCosts": []
}

No content

Update a Cost category

put

Update an existing Cost Category configuration. Modify cost buckets, shared costs, rules, or rename the Cost Category. The update is identified by the UUID in the request body.

Query parameters
accountIdentifierstringOptional
Body
uuidstringOptional
namestring · min: 1 · max: 32RequiredPattern: ^[^\d][^'"\\]*$
accountIdstringRequired
supportsTagNormalizationbooleanOptional
createdAtinteger · int64Optional
lastUpdatedAtinteger · int64Optional
Responses
400

Bad Request

application/json

This is Failure entity as defied in Harness

statusstring · enumOptionalPossible values:
codestring · enumOptionalPossible values:
messagestringOptional
correlationIdstringOptional
put/business-mapping
PUT /gateway/ccm/api/business-mapping HTTP/1.1
Host: nextgen-ce-d788d786-ssnpc
Content-Type: application/json
Accept: */*
Content-Length: 783

{
  "uuid": "text",
  "name": "text",
  "accountId": "text",
  "costTargets": [
    {
      "name": "text",
      "rules": [
        {
          "viewConditions": [
            {
              "type": "text"
            }
          ]
        }
      ]
    }
  ],
  "sharedCosts": [
    {
      "name": "text",
      "rules": [
        {
          "viewConditions": [
            {
              "type": "text"
            }
          ]
        }
      ],
      "strategy": "EQUAL",
      "splits": [
        {
          "costTargetName": "text",
          "percentageContribution": 1
        }
      ]
    }
  ],
  "unallocatedCost": {
    "strategy": "DISPLAY_NAME",
    "label": "text",
    "sharingStrategy": "EQUAL",
    "splits": [
      {
        "costTargetName": "text",
        "percentageContribution": 1
      }
    ]
  },
  "dataSources": [
    "CLUSTER"
  ],
  "supportsTagNormalization": true,
  "createdAt": 1,
  "lastUpdatedAt": 1,
  "createdBy": {
    "uuid": "text",
    "name": "text",
    "email": "text",
    "externalUserId": "text"
  },
  "lastUpdatedBy": {
    "uuid": "text",
    "name": "text",
    "email": "text",
    "externalUserId": "text"
  },
  "costTargetsWithUUID": [
    {
      "name": "text",
      "rules": [
        {
          "viewConditions": [
            {
              "type": "text"
            }
          ]
        }
      ]
    }
  ]
}
{
  "status": "SUCCESS",
  "code": "DEFAULT_ERROR_CODE",
  "message": "text",
  "correlationId": "text",
  "errors": [
    {
      "fieldId": "text",
      "error": "text"
    }
  ]
}

Last updated

Was this helpful?