---
title: "Update a consumer organization"
method: PUT
path: "/apiops/projects/{projectName}/consumer-organizations/{code}"
tags: ["Consumer"]
---

# Update a consumer organization

`PUT /apiops/projects/{projectName}/consumer-organizations/{code}`

## Request

- Base URL: `http://167.86.118.166:32080`
- URL: `http://167.86.118.166:32080/apiops/projects/{projectName}/consumer-organizations/{code}`
- Auth: none declared
- TypeScript: <https://skmtc.dev/apinizer/apis/apinizer-management-apis/docs/apiops/projects/:projectName/consumer-organizations/:code/put.ts> (a function with typed inputs; its response is checked against the schema)

Updates the organization. An omitted (or blank) name or parent code and an omitted metadata keep the stored value; metadata, when sent, replaces the stored list (a secret entry sent without a value is stored empty — send the value to keep it). code cannot change (400 immutableField). On an organization an identity source manages, the fields the source owns keep the source's values.

## Path parameters

- `projectName` string, required
- `code` string, required

## Request body

- ApiOpsConsumerOrganizationWriteDTO
  - `code` string
  - `nameDefault` string
  - `nameSecondary` string
  - `parentOrganizationCode` string
  - `metadata` CredentialMetadataDTO[]
    - `key` string
    - `value` string
    - `secret` boolean
    - `includeInJwt` boolean
    - `includeInTokenResponse` boolean
    - `jwtClaimName` string

## Response `200`

OK

- ApiOpsMutationResponseApiOpsResponseConsumerOrganization
  - `status` 'SUCCESS' | 'FAILURE'
  - `resourceVersion` integer
  - `runtimeDeployment` ApiOpsRuntimeDeploymentDTO
    - `state` 'IN_SYNC' | 'DEGRADED'
    - `environments` Environment[]
      - `name` string
      - `acknowledged` boolean
      - `detail` string
  - `result` ApiOpsResponseConsumerOrganization
    - `code` string
    - `nameDefault` string
    - `nameSecondary` string
    - `parentOrganizationCode` string
    - `metadata` CredentialMetadataDTO[]
      - `key` string
      - `value` string
      - `secret` boolean
      - `includeInJwt` boolean
      - `includeInTokenResponse` boolean
      - `jwtClaimName` string

---

[API](https://skmtc.dev/apinizer/apis/apinizer-management-apis.md) - [All operations](https://skmtc.dev/apinizer/apis/apinizer-management-apis/llms.txt) - [OpenAPI document](https://skmtc.dev/apinizer/apis/apinizer-management-apis/revisions/e083046b24cd?raw)
