Closed humpataa closed 1 year ago
Use exactly the syntax specified in the example, named parameters must be used.
Okay, now it breaks with "InvalidArgumentException: Invalid file type provided: 3900530663". As you can see, I am using the mime value of getDownloadInfo – which should be okay. My guess is that the file-id is not correct? Please advise.
Wait sorry, I noticed you're doing something wrong, you just need to do $MadelineProto->getDownloadLink($message);
I am trying this to get the link to a file that is attached to a message to a channel:
It breaks with the above error message, but the syntax is: $link = $MadelineProto->getDownloadLink($botApiFileId, size: $fileSize, name: $fileName, mime: $mimeType);
What am I doing wrong here?