# Send document from draft

{% post /%}
{% path text="/v1-beta/document/draftSend" /%}

This API endpoint converts a draft document to in-progress status and sends it for signature. In BoldSign, a draft document is one that has been created but not yet sent to recipients.

To use this endpoint, you'll need to provide the document ID of your draft document. The API will then initiate the sending process and return the same document ID, which you can use to track the document's progress.

This endpoint performs similar validations as the {% customlink href="/documents/send-document/" text="document send API" /%}. If any information is incomplete or incorrectly configured, you'll receive an error similar to those encountered with the {% customlink href="/documents/send-document/" text="document send API" /%}.

## Code snippet

{% codetab %}

cURL

```shell
curl -X POST 'https://api.boldsign.com/v1/document/draftSend?documentId=8f59295d-xxxx-xxxx-xxxx-e7dc88cfff2c' \
-H 'accept: application/json' \
-H 'X-API-KEY: {your-api-key}'
```

C#

```csharp
var apiClient = new ApiClient("https://api.boldsign.com", "Your_API_Key");

var documentClient = new DocumentClient(apiClient);
var documentCreated = documentClient.SendDocumentFromDraft("YOUR_DOCUMENT_ID");
```

Python

```python
import boldsign
 
configuration = boldsign.Configuration(host = "https://api.boldsign.com", api_key="YOUR_API_KEY")
 
with boldsign.ApiClient(configuration) as api_client:
 
   document_api = boldsign.DocumentApi(api_client)
   document_api.draft_send(document_id="YOUR_DOCUMENT_ID")
```

PHP

```php
<?php require_once "vendor/autoload.php";
 
use BoldSign\Configuration;
use BoldSign\Api\DocumentApi;
 
$config = new Configuration();
$config->setHost('https://api.boldsign.com');
$config->setApiKey('YOUR_API_KEY');
 
$document_api = new DocumentApi($config);
$document_sent = $document_api->draftSend($document_id = 'YOUR_DOCUMENT_ID');
```

Java

```java
ApiClient client = Configuration.getDefaultApiClient();
client.setBasePath("https://api.boldsign.com");
client.setApiKey("YOUR_API_KEY");

DocumentApi documentApi = new DocumentApi(client);
documentApi.draftSend("YOUR_DOCUMENT_ID");
```

NodeJS

```js
import { DocumentApi } from "boldsign";

const documentApi = new DocumentApi("https://api.boldsign.com");
documentApi.setApiKey("YOUR_API_KEY");
 
const documentCreated = await documentApi.draftSend("YOUR_DOCUMENT_ID");
```

{% /codetab %}

## Query parameters

{% nestedtable %}

- {% arguments name="documentId" /%}{% batch datatype="string" /%}{% required /%}
- The unique document id of the draft document.

---

{% /nestedtable %}

## Example response

***201 Created***

```json
{
  "documentId": "8f59295d-xxxx-xxxx-xxxx-e7dc88cfff2c"
}
```

