botman / botman/driver-telegram
Is there way to send files (not images) without extending the driver?
Open
- Dominant language
- PHP
- Stars
- 94
- Forks
- 74
- PR merge metrics
- No merged PRs in 30d
Description
Can I send CSV, XLS, PDF, or other files without rewriting the driver to get this feature?
```
$filePath = $this->createRatesCsv($rates);
$fileAttachment = new File($filePath, [
'custom_payload' => false,
]);
$message = OutgoingMessage::create('Rate Data')->withAttachment($fileAttachment);
$this->bot->reply($message);
```
The construction like that doesn't work with both (URL or path) cases.
Someone may have had the proper piece of code not to dance with that thing.
Contributor guide
Assessment
This issue has not been assessed yet.