# Update Workflow

## Workflow: Update Workflow

### User Intent

"I want to update a workflow's configuration"

### Operation

* **SDK Method**: `graphlit.updateWorkflow()`
* **GraphQL**: `updateWorkflow` mutation
* **Entity Type**: Workflow
* **Common Use Cases**: Change workflow steps, update specifications, enable/disable

### TypeScript (Canonical)

```typescript
import { Graphlit } from 'graphlit-client';
import { Types } from 'graphlit-client/dist/generated/graphql-types';

const graphlit = new Graphlit();

// Replace with ID from creating a workflow or from queryWorkflows
const workflowId = 'workflow-id-here';

// Update workflow
await graphlit.updateWorkflow({
  id: workflowId,
  name: 'Updated Workflow Name'
});

console.log('Workflow updated');
```

## Update workflow (snake\_case)

await graphlit.updateWorkflow( workflow=WorkflowUpdateInput( id=workflow\_id, name="Updated Workflow Name" ) )

````

**C#**:
```csharp
using Graphlit;

var client = new Graphlit();

var workflowId = "workflow-id-here";

// Update workflow (PascalCase)
await graphlit.UpdateWorkflow(new WorkflowUpdateInput {
    Id = workflowId,
    Name = "Updated Workflow Name"
});
````

### Parameters

#### WorkflowUpdateInput (Required)

* **`id`** (string): Workflow ID
* **`name`** (string): New name (optional)

### Response

```typescript
{
  updateWorkflow: {
    id: string;
  }
}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.graphlit.dev/api-guides/use-cases/workflows/workflow-update.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
