---
title: "Element <draft>"
source: https://dev.pageseeder.com/api/elements/element_draft.html
description: "API Element reference for <draft>"
last_updated: 2026-08-07T17:09:54+10:00
tokens: ~392
---

# \<draft\>

## Summary

Represents a draft edit on a PSML document in PageSeeder.

## Usage context

| Permitted content | `<author>`, `<locator>`, \<metadata\> |
| --- | --- |
| Permitted parent | `<drafts>, <edits>` |

## Attributes

This element includes the following attributes:

| Name | Type | Required | Description |
| --- | --- | --- | --- |
| id | `xs:long` | yes | The ID of the draft edit in PageSeeder |
| created | `xs:dateTime` | no | The draft's creation date in ISO 8601 format |
| deleted | `xs:boolean` | no | If the draft was deleted |

## Examples

```lang-xml

<draft id="654654" created="2017-03-07T14:12:49+11:00">
  <author id="542"
          firstname="Bob"
          surname="Taylor"
          status="activated">
    <fullname>Bob Taylor</fullname>
  </author>
  <locator fragment="example"/>
</draft>
```

## Schema

### XML Schema

```lang-relax

<xs:element name="draft">
  <xs:sequence>
    <xs:element ref="author"    minOccurs="0"/>
    <xs:element name="metadata" minOccurs="0" />
    <xs:element name="locator"  minOccurs="0" />
  </xs:sequence>
  <xs:attribute name="id"      type="id"/>
  <xs:attribute name="created" type="xs:dateTime" use="optional"/>
  <xs:attribute name="deleted" type="xs:boolean"  use="optional"/>
</xs:complexType>
```

### Relax Schema

```lang-relax

element draft {
   attribute id { xs:long }?,
   attribute created  { xs:dateTime }?,
   attribute deleted  { xs:boolean }?,
   element author?,
   element locator?,
   element metadata?
}
```

## Compatibility

No change since initial API release.

