appleboy / telegram-action

GitHub Action that sends a Telegram message.
https://github.com/marketplace/actions/telegram-message-notify
MIT License
848 stars 108 forks source link

Unable to send apk to telegram group. A text message received instead #16

Open YajanaRao opened 4 years ago

YajanaRao commented 4 years ago

I have configured to upload apk after build in github actions. I get text instead of file

image

This is what I get image

This is the log

image

hkpanchani commented 4 years ago

while sending document you need to send absolute path not relative path document: ${{ github.workspace }}/app/build/outputs/apk/debug/app-debug.apk

I am saving my apk in github workspace

YajanaRao commented 4 years ago

while sending document you need to send absolute path not relative path document: ${{ github.workspace }}/app/build/outputs/apk/debug/app-debug.apk

I am saving my apk in github workspace

It sends the link to the apk right ?. I was wondering is there a possibility of sending apk file itself ?

hkpanchani commented 4 years ago

No it sends the apk itself Let me show you my code

`jobs: build: name: Generate APK runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: set up JDK 1.8
  uses: actions/setup-java@v1
  with:
    java-version: 1.8
- name: Build Debug APK
  run: bash ./gradlew :app:assembleDebug

- name: Upload APK
  uses: actions/upload-artifact@v2
  with:
    name: App
    path: ${{ github.workspace }}/app/build/outputs/apk/debug/app-debug.apk

- name: send custom message
  uses: appleboy/telegram-action@master
  with:
    to: ${{ secrets.MESSAGEID }}
    token: ${{ secrets.BOTTOKEN }}
    message: |
      Below is the apk for commit: ${{ github.event.head_commit.message }}
    document: ${{ github.workspace }}/app/build/outputs/apk/debug/app-debug.apk`
SGCEntertainment commented 2 years ago

не работает для меня

gumam commented 2 years ago

did not work

lkant8 commented 1 year ago

im also facing this issue

davidC1991 commented 1 year ago

i have the same problem. maybe because my apk file is 200 Mb Size, by telegram api documentation , bots just suppot until 50 Mb

markusressel commented 1 year ago

Facing the same issue when using curl to upload an APK, if the file exceeds a certain limit (looks like its 50 MB) the file is not uploaded.

Looks like it is possible to work around this by hosting your own bot api server: https://core.telegram.org/bots/api#using-a-local-bot-api-server

loderunner84 commented 1 year ago

how do you fill TELEGRAM_TO secret? I've tried set group chat id with "-" and without and no success both