# Introduction

> Laravel Anydoc Rust converts Word, PowerPoint, Excel, OpenDocument, RTF, EPUB, CSV, and PDF files to Markdown from Laravel Rust.

Laravel Anydoc Rust converts Word, PowerPoint, Excel, OpenDocument, RTF, EPUB, CSV, and PDF files to GitHub-Flavored Markdown, or to [anydoc](https://github.com/firecrawl/anydoc)'s document model, from [Laravel Rust](https://laravel.com/rust). It reads local files, uploads, bytes, and files on storage disks, and sends scanned PDFs to [Firecrawl](https://firecrawl.dev) for OCR when you ask it to.

## Quick start

After [installing the package](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/installation/), receive `Anydoc` with `Inject<Anydoc>` and convert a file:

```rust
use laravel::prelude::*;
use laravel_anydoc::Anydoc;

pub async fn show(anydoc: Inject<Anydoc>) -> laravel::Result<String> {
    anydoc.file("storage/app/report.docx").markdown().await
}
```

## Supported formats

| Format | Extensions |
| --- | --- |
| CSV | `.csv` |
| EPUB | `.epub` |
| Excel | `.xls`, `.xlsb`, `.xlsm`, `.xlsx` |
| OpenDocument | `.odp`, `.ods`, `.odt` |
| PDF | `.pdf` |
| PowerPoint | `.pot`, `.pps`, `.ppsm`, `.ppsx`, `.ppt`, `.pptm`, `.pptx` |
| Rich Text Format | `.rtf` |
| Word | `.doc`, `.docm`, `.docx` |

## Next steps

- [Converting documents](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/basic-usage/converting-documents/) covers local files, uploads, and bytes.
- [Storage disks](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/basic-usage/storage-disks/) converts files on the application's filesystem disks, such as S3.
- [Formats and output](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/basic-usage/formats-and-output/) explains format detection and anydoc's document model.
- [Handling errors](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/basic-usage/handling-errors/) explains why a conversion fails and how to respond.
- [Testing](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/basic-usage/testing/) swaps a fake `Anydoc` into application tests.
- [OCR](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/advanced-usage/ocr/) sends scanned PDFs to Firecrawl.
- [Configuration](https://hosmelq.com/docs/laravel-anydoc-rust/v0.1/configuration/) lists the Firecrawl settings and the size limit.
