> ## Documentation Index
> Fetch the complete documentation index at: https://docs.box.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Generating documents using Doc Gen

After [adding your template to Box Doc Gen](https://docs.box.com/en/box-doc-gen/box-doc-gen-templates/uploading-templates-to-doc-gen.md), you can generate documents using one of four methods. Choose the method that best fits your workflow and technical requirements.

1. **Generating documents using the Box Doc Gen API**. For developers and automated workflows, you can generate documents programmatically using the Box Doc Gen API. See the [Box Doc Gen API documentation](https://developer.box.com/guides/docgen/generate-document/) for detailed instructions.
2. **Generating documents using Box Relay**. You can automate document generation as part of your business workflows using Box Relay. See [Generating Documents with Box Doc Gen and Box Relay](https://docs.box.com/en/box-doc-gen/generating-documents-using-doc-gen/generating-documents-with-box-doc-gen-and-box-relay.md) for step-by-step instructions.
3. **Generating documents using the Box Doc Gen UI**. You can manually generate documents directly from the Box Doc Gen interface in Relay. [Learn how to generate documents using the UI](https://docs.box.com/en/box-doc-gen/generating-documents-using-doc-gen/generating-documents-using-box-web-app.md).
4. **Generating documents using Box for Salesforce**. If you use Salesforce, you can generate Box Doc Gen documents directly from Salesforce records. See the [Box for Salesforce documentation](https://docs.box.com/en/box-doc-gen/generating-documents-using-doc-gen/setting-up-box-doc-gen-in-salesforce.md) for configuration and usage instructions.
