{"id":51405279,"url":"https://github.com/alyldas/uniauth-messenger-provider","last_synced_at":"2026-07-04T10:31:41.809Z","repository":{"id":360712816,"uuid":"1250378197","full_name":"alyldas/uniauth-messenger-provider","owner":"alyldas","description":"Telegram and Max messenger provider adapters for UniAuth.","archived":false,"fork":false,"pushed_at":"2026-05-27T16:13:02.000Z","size":46,"stargazers_count":0,"open_issues_count":1,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-27T16:14:54.890Z","etag":null,"topics":["auth","authentication","max","messenger","telegram","typescript","uniauth"],"latest_commit_sha":null,"homepage":"https://github.com/alyldas/uniauth-messenger-provider#readme","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"other","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/alyldas.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"SECURITY.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":"NOTICE","maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-05-26T15:13:13.000Z","updated_at":"2026-05-27T16:13:07.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/alyldas/uniauth-messenger-provider","commit_stats":null,"previous_names":["alyldas/uniauth-messenger-provider"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/alyldas/uniauth-messenger-provider","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alyldas%2Funiauth-messenger-provider","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alyldas%2Funiauth-messenger-provider/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alyldas%2Funiauth-messenger-provider/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alyldas%2Funiauth-messenger-provider/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/alyldas","download_url":"https://codeload.github.com/alyldas/uniauth-messenger-provider/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/alyldas%2Funiauth-messenger-provider/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":35118970,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-07-04T02:00:05.987Z","response_time":113,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["auth","authentication","max","messenger","telegram","typescript","uniauth"],"created_at":"2026-07-04T10:31:41.075Z","updated_at":"2026-07-04T10:31:41.791Z","avatar_url":"https://github.com/alyldas.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# UniAuth Messenger Provider\n\n[![GitHub Packages](https://img.shields.io/static/v1?label=GitHub%20Packages\u0026message=%40alyldas%2Funiauth-messenger-provider\u0026color=24292f\u0026logo=github)](https://github.com/users/alyldas/packages/npm/package/uniauth-messenger-provider)\n\n`@alyldas/uniauth-messenger-provider` contains SDK-free UniAuth provider adapters for signed\nmessenger WebApp launch data:\n\n- Telegram Mini App `initData`;\n- MAX WebApp `initData` / `WebAppData`.\n\nThe package validates the signed launch payload and maps the signed user into UniAuth\n`ProviderIdentityAssertion`.\n\n## Runtime Boundary\n\nThis package does not own bot setup, frontend bridge code, HTTP routes, cookies, session transport,\nstorage, or UI.\n\n## Install\n\nConfigure the GitHub Packages registry for the package scope before installing:\n\n```ini\n@alyldas:registry=https://npm.pkg.github.com\n```\n\nGitHub Packages can require authentication for package reads. Use a token with `read:packages` in local npm config or CI secrets; do not commit tokens.\n\n```bash\nnpm install @alyldas/uniauth-core @alyldas/uniauth-messenger-provider\n```\n\n## Telegram\n\n```ts\nimport {\n  TELEGRAM_MINI_APP_PROVIDER_ID,\n  createTelegramMiniAppProvider,\n} from '@alyldas/uniauth-messenger-provider/telegram'\n\nproviderRegistry.register(\n  createTelegramMiniAppProvider({\n    botToken: process.env.TELEGRAM_BOT_TOKEN!,\n    maxAgeSeconds: 60 * 5,\n  }),\n)\n\nconst result = await auth.public.provider.signIn({\n  provider: TELEGRAM_MINI_APP_PROVIDER_ID,\n  finishInput: {\n    payload: {\n      initData: request.body.initData,\n    },\n  },\n})\n```\n\n## MAX\n\n```ts\nimport {\n  MAX_WEBAPP_PROVIDER_ID,\n  createMaxWebAppProvider,\n} from '@alyldas/uniauth-messenger-provider/max'\n\nproviderRegistry.register(\n  createMaxWebAppProvider({\n    botToken: process.env.MAX_BOT_TOKEN!,\n    maxAgeSeconds: 60 * 5,\n  }),\n)\n\nconst result = await auth.public.provider.signIn({\n  provider: MAX_WEBAPP_PROVIDER_ID,\n  finishInput: {\n    payload: {\n      url: request.body.url,\n    },\n  },\n})\n```\n\n`createMaxWebAppProvider` accepts direct signed `initData` and URL fragments that contain\n`WebAppData`.\n\n## Root Import\n\nThe root entry point re-exports Telegram, MAX, and the shared validator:\n\n```ts\nimport {\n  createMaxWebAppProvider,\n  createTelegramMiniAppProvider,\n  validateSignedWebAppInitData,\n} from '@alyldas/uniauth-messenger-provider'\n```\n\n## Security Notes\n\n- Keep bot tokens in server-only bootstrap code.\n- Set `maxAgeSeconds` for production sign-in endpoints.\n- Do not use `initDataUnsafe` for authentication.\n- Do not persist raw launch payloads unless the application has a separate audit policy.\n- Exact `(provider, providerUserId)` matching stays owned by UniAuth core.\n- Auto-link and merge decisions remain controlled by `AuthPolicy`.\n\n## Local Checks\n\n```bash\nnpm run check\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falyldas%2Funiauth-messenger-provider","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Falyldas%2Funiauth-messenger-provider","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Falyldas%2Funiauth-messenger-provider/lists"}