Skip to content

Commit 36b08d6

Browse files
committed
fix reset signature
1 parent c54de7e commit 36b08d6

File tree

1 file changed

+5
-11
lines changed

1 file changed

+5
-11
lines changed

docs/idempotency.mdx

Lines changed: 5 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -367,22 +367,16 @@ When you reset an idempotency key, it will be cleared for all runs that match bo
367367
```ts
368368
idempotencyKeys.reset(
369369
taskIdentifier: string,
370-
idempotencyKey: IdempotencyKey | string | string[],
371-
options?: {
372-
scope?: "run" | "attempt" | "global";
373-
parentRunId?: string;
374-
attemptNumber?: number;
375-
}
376-
)
370+
idempotencyKey: string,
371+
requestOptions?: ZodFetchOptions
372+
): Promise<{ id: string }>
377373
```
378374

379375
| Parameter | Description |
380376
| --- | --- |
381377
| `taskIdentifier` | The identifier of the task (e.g., `"my-task"`) |
382-
| `idempotencyKey` | The idempotency key to reset. Can be an `IdempotencyKey` from `create()`, a raw string, or a string array |
383-
| `options.scope` | The scope used when the key was created. Defaults to `"run"` |
384-
| `options.parentRunId` | Required for `"run"` or `"attempt"` scope when called outside a task context |
385-
| `options.attemptNumber` | Required for `"attempt"` scope when called outside a task context |
378+
| `idempotencyKey` | The idempotency key hash to reset (the 64-character hash string) |
379+
| `requestOptions` | Optional fetch options for the API request |
386380

387381
### Resetting keys created with `idempotencyKeys.create()`
388382

0 commit comments

Comments
 (0)