> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lyzr.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# Update Tool Credential Endpoint

> Update an existing tool credential by its ID.

### Description

Update an existing tool credential by its ID.

### Endpoint

**PUT** `/v3/tools/credentials/{credential_id}`

### Authentication

API Key (x-api-key) must be included in the header.

### Path Parameters

* `credential_id` (string) - The ID of the credential to update.

### Request Body

A JSON object containing the updated credential data.

### Response

A message confirming that the credential was updated.

### Example Request

```sh theme={null}
curl -X PUT "https://agent-prod.studio.lyzr.ai/v3/tools/credentials/credential_id" ^
-H "accept: application/json" ^
-H "content-type: application/json" ^
-H "x-api-key: sk-default-EXAMPLEKEY123" ^
-d "{\"name\":\"string\",\"credentials\":{},\"meta_data\":{}}"
```

***


## OpenAPI

````yaml put /tools/credentials/{credential_id}
openapi: 3.0.3
info:
  title: Lyzr Tool Credential API
  version: 1.0.0
servers:
  - url: https://agent-prod.studio.lyzr.ai/v3
security: []
paths:
  /tools/credentials/{credential_id}:
    put:
      tags:
        - Tools
      summary: Update Tool Credential
      description: Update an existing tool credential by its ID.
      operationId: updateToolCredential
      parameters:
        - name: credential_id
          in: path
          required: true
          description: The ID of the credential to update.
          schema:
            type: string
      requestBody:
        description: Updated credential data
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  type: string
                  example: string
                credentials:
                  type: object
                  additionalProperties: true
                meta_data:
                  type: object
                  additionalProperties: true
      responses:
        '200':
          description: Credential updated successfully
          content:
            application/json:
              schema:
                type: object
                properties:
                  message:
                    type: string
                    example: Credential updated successfully.
        '401':
          description: Unauthorized - Invalid API key
        '404':
          description: Credential not found
      security:
        - ApiKeyAuth: []
components:
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: x-api-key

````