Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there way to send files (not images) without extending the driver? #119

Open
kirchevsky opened this issue Apr 24, 2024 · 0 comments
Open

Comments

@kirchevsky
Copy link

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.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant