> For the complete documentation index, see [llms.txt](https://pollz.gitbook.io/pollz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://pollz.gitbook.io/pollz/api-reference/polls/deleteone.md).

# deleteOne()

**`deleteOne(id: EntryIdType): Promise<void>`**

Delete a poll.

**Parameters:**

* `id` (EntryIdType): The ID of the poll to be deleted.

**Returns:**

* A `Promise` resolving to `void` indicating the successful deletion of the specified poll.

**Example:**

```javascript
const pollIdToDelete = 1;

try {
  await pollz.polls.deleteOne(pollIdToDelete);
  console.log('Poll Deleted Successfully.');
} catch (error) {
  console.error('Failed to delete poll:', error.message);
}
```

The `deleteOne` method allows you to delete a specific poll identified by its unique ID (`id`). Once deleted, the poll and its associated data, including options and votes, will be permanently removed from the system.

The method returns a `Promise` resolving to `void`, indicating the successful deletion of the specified poll.

**Note:** Ensure that the provided `id` corresponds to an existing poll in the system.
