# Rename or update a log view (/docs/api/logs/log_views_update)

Rename a view or change its query, columns or sharing. You can change your own views; owners and admins can also change shared ones.

`PUT /v1/logs/views/{id}`

```json
{
  "operationId": "log_views_update",
  "summary": "Rename or update a log view",
  "description": "Rename a view or change its query, columns or sharing. You can change your own views; owners and admins can also change shared ones.",
  "tags": [
    "logs"
  ],
  "security": [
    {
      "bearer": []
    }
  ],
  "parameters": [
    {
      "schema": {
        "type": "string",
        "pattern": "^lv_[a-z0-9]{8,32}$"
      },
      "required": true,
      "name": "id",
      "in": "path"
    }
  ],
  "requestBody": {
    "required": true,
    "content": {
      "application/json": {
        "schema": {
          "type": "object",
          "properties": {
            "name": {
              "type": "string",
              "minLength": 1,
              "maxLength": 60
            },
            "query": {
              "type": "string",
              "maxLength": 2000
            },
            "columns": {
              "type": [
                "object",
                "null"
              ],
              "additionalProperties": {
                "type": "boolean"
              }
            },
            "shared": {
              "type": "boolean"
            }
          }
        }
      }
    }
  },
  "responses": {
    "200": {
      "description": "OK",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string",
                "pattern": "^lv_[a-z0-9]{8,32}$"
              },
              "name": {
                "type": "string"
              },
              "query": {
                "type": "string"
              },
              "columns": {
                "type": [
                  "object",
                  "null"
                ],
                "additionalProperties": {
                  "type": "boolean"
                }
              },
              "shared": {
                "type": "boolean"
              },
              "owned": {
                "type": "boolean"
              },
              "created_at": {
                "type": "string"
              },
              "updated_at": {
                "type": "string"
              }
            },
            "required": [
              "id",
              "name",
              "query",
              "columns",
              "shared",
              "owned",
              "created_at",
              "updated_at"
            ]
          }
        }
      }
    },
    "default": {
      "description": "Error",
      "content": {
        "application/json": {
          "schema": {
            "type": "object",
            "properties": {
              "error": {
                "type": "object",
                "properties": {
                  "code": {
                    "type": "string",
                    "enum": [
                      "invalid_request",
                      "unauthorized",
                      "insufficient_balance",
                      "max_cost_exceeded",
                      "scope_denied",
                      "budget_blocked",
                      "not_found",
                      "idempotency_mismatch",
                      "invalid_meta",
                      "rate_limited",
                      "upstream_error",
                      "response_buffer_limit",
                      "provider_capacity_unavailable",
                      "grid_saturated",
                      "upstream_timeout",
                      "conflict",
                      "internal_error",
                      "account_frozen",
                      "strict_filters",
                      "plan_limit_reached",
                      "validation_failed",
                      "deadline_exceeded",
                      "cancelled"
                    ]
                  },
                  "message": {
                    "type": "string"
                  },
                  "request_id": {
                    "type": "string"
                  },
                  "call_id": {
                    "type": "string"
                  },
                  "retry_after_ms": {
                    "type": "integer",
                    "minimum": 0
                  },
                  "details": {
                    "type": "object",
                    "additionalProperties": {}
                  }
                },
                "required": [
                  "code",
                  "message"
                ]
              }
            },
            "required": [
              "error"
            ]
          }
        }
      }
    }
  }
}
```
