diff --git a/lib/routes/telegram/channel-media.ts b/lib/routes/telegram/channel-media.ts index 34b12f12c..c1118aa18 100644 --- a/lib/routes/telegram/channel-media.ts +++ b/lib/routes/telegram/channel-media.ts @@ -161,9 +161,9 @@ function streamResponse(c: Context, bodyIter: AsyncGenerator) { } export const route: Route = { - path: '/channel/:entityName/:messageId', + path: '/media/:entityName/:messageId', categories: ['social-media'], - example: '/channel/telegram/1233', + example: '/telegram/media/telegram/1233', parameters: { entityName: 'entity name', messageId: 'message id' }, features: { requireConfig: [ diff --git a/lib/routes/telegram/stories.ts b/lib/routes/telegram/stories.ts index 7e266d3b2..fbeb9cb49 100644 --- a/lib/routes/telegram/stories.ts +++ b/lib/routes/telegram/stories.ts @@ -10,7 +10,7 @@ import { getGeoLink, getMediaLink } from './tglib/channel'; export const route: Route = { path: '/stories/:username/:story?', categories: ['social-media'], - example: '/stories/sandboxuser1', + example: '/telegram/stories/telegram', parameters: { username: 'entity name', story: 'story' }, features: { requireConfig: [ diff --git a/lib/routes/telegram/tglib/channel.ts b/lib/routes/telegram/tglib/channel.ts index cf44a353c..655f9389c 100644 --- a/lib/routes/telegram/tglib/channel.ts +++ b/lib/routes/telegram/tglib/channel.ts @@ -142,7 +142,7 @@ export default async function handler(ctx: Context) { } // messages that have no text are shown as if they're one post // because in TG only 1 attachment per message is possible - const src = `${new URL(ctx.req.url).origin}/telegram/channel/${username}/${message.id}`; + const src = `${new URL(ctx.req.url).origin}/telegram/media/${username}/${message.id}`; attachments.push(getMediaLink(src, media)); } if (message.replyMarkup instanceof Api.ReplyInlineMarkup) {