fix: update authentication for latest Gojek app (v5.57.2)#34
Conversation
- New sdk/auth-gojek-node package for modern auth flow - Updated endpoints from goid.gojekapi.com to accounts.goto-products.com - 5-step login flow: methods → initiate → verify → accountlist → token - PIN and OTP authentication support - X-E1/X-E2/X-E3/X-M1 header documentation - Crypto-based UUID and hex generation - Redacted all PII from docs and examples
There was a problem hiding this comment.
Pull request overview
This PR updates the repo for the newer Gojek authentication stack by introducing a new Node auth SDK targeting accounts.goto-products.com, updating docs to describe the new multi-step login flow, and modernizing Node SDK dependencies (axios/typescript/@types/node) alongside refreshed examples and tooling.
Changes:
- Add
sdk/auth-gojek-nodeimplementing the new 5-step auth flow (methods → initiate → verify → accountlist → token) plus SSO support. - Update existing Node SDK packages to newer axios/typescript/node typings and refresh examples to load config from
.env. - Add mitmproxy capture tooling and new documentation describing signature headers (X-E1/X-E2/X-E3/X-M1) and iOS login flow.
Reviewed changes
Copilot reviewed 23 out of 31 changed files in this pull request and generated 12 comments.
Show a summary per file
| File | Description |
|---|---|
| tools/gojek_login.js | New CLI login helper for OTP/token retrieval (currently has correctness/syntax issues). |
| tools/capture_gojek_auth.py | New mitmproxy addon to capture auth-related headers. |
| tools/capture_all.py | New verbose mitmproxy addon to capture broader auth-domain traffic. |
| tools/PROXY_SETUP.md | Instructions for setting up mitmproxy and capturing App Check headers. |
| sdk/gopay-gojek-node/package.json | Bumps axios/typescript/@types/node versions. |
| sdk/gopay-gojek-node/package-lock.json | Lockfile updated for new dependency tree. |
| sdk/goid-gojek-node/package.json | Bumps axios/typescript/@types/node and adjusts repository metadata formatting. |
| sdk/goid-gojek-node/package-lock.json | Lockfile updated for new dependency tree. |
| sdk/api-gojek-node/package.json | Bumps axios/typescript/@types/node versions. |
| sdk/api-gojek-node/package-lock.json | Lockfile updated for new dependency tree. |
| sdk/auth-gojek-node/tsconfig.json | New TypeScript build configuration for auth SDK. |
| sdk/auth-gojek-node/src/index.ts | New AuthApi implementation for accounts.goto-products.com flows + header generation helpers. |
| sdk/auth-gojek-node/package.json | New auth SDK package manifest. |
| sdk/auth-gojek-node/package-lock.json | Lockfile for new auth SDK package. |
| sdk/auth-gojek-node/dist/index.js | Checked-in compiled output for auth SDK. |
| sdk/auth-gojek-node/dist/index.d.ts | Checked-in type declarations for auth SDK. |
| package.json | Adds root dependency on dotenv for examples/tooling. |
| package-lock.json | Lockfile for root dotenv dependency. |
| examples/node/gopay/get-balance.js | Example updated to read headers/tokens from .env and use generated IDs. |
| examples/node/api/get-customer.js | Example updated to read headers/tokens from .env and use generated IDs. |
| examples/node/goid/sso-login.js | New SSO login example using the new auth SDK. |
| examples/node/goid/goid.js | Removes legacy example that hardcoded secrets/PII. |
| examples/node/goid/auth.js | New OTP/SSO auth flow example using the new auth SDK (currently has syntax issues). |
| docs/gopay-gojekapi.yaml | Bumps doc version and improves header parameter descriptions/examples. |
| docs/goid-gojekapi.yaml | Bumps doc version and removes hardcoded client_secret defaults in favor of descriptions. |
| docs/api-gojekapi.yaml | Bumps doc version and improves header parameter docs/examples. |
| docs/LOGIN_FLOW_IOS.md | New documentation describing iOS auth flow and required headers. |
| docs/AUTHENTICATION_CHANGES.md | New high-level migration doc for the new auth endpoints and signature headers. |
| README.md | Expanded setup/auth instructions (currently corrupted by line-number artifacts). |
| .gitignore | Adds ignores for captured headers/tokens/logs and sensitive artifacts (.env, APKs, certs). |
| .env.example | New environment variable template (currently malformed). |
Files not reviewed (4)
- sdk/api-gojek-node/package-lock.json: Language not supported
- sdk/auth-gojek-node/package-lock.json: Language not supported
- sdk/goid-gojek-node/package-lock.json: Language not supported
- sdk/gopay-gojek-node/package-lock.json: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 23 out of 31 changed files in this pull request and generated 18 comments.
Files not reviewed (4)
- sdk/api-gojek-node/package-lock.json: Language not supported
- sdk/auth-gojek-node/package-lock.json: Language not supported
- sdk/goid-gojek-node/package-lock.json: Language not supported
- sdk/gopay-gojek-node/package-lock.json: Language not supported
Comments suppressed due to low confidence (1)
README.md:5
- README content includes diff/line-number artifacts (e.g.,
1| 1|# gojek) as literal text, which will render incorrectly. Remove these prefixes so the Markdown contains only the intended content.
# gojek
Un-official Go-jek API Wrapper. API end point known by decompile the android APK.
- [Have trouble ?](https://github.com/mychaelgo/gojek/issues)
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 23 out of 31 changed files in this pull request and generated 12 comments.
Files not reviewed (4)
- sdk/api-gojek-node/package-lock.json: Language not supported
- sdk/auth-gojek-node/package-lock.json: Language not supported
- sdk/goid-gojek-node/package-lock.json: Language not supported
- sdk/gopay-gojek-node/package-lock.json: Language not supported
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Updates Gojek SDK with working authentication for the new
accounts.goto-products.comendpoints.Changes
sdk/auth-gojek-nodepackage for modern auth flowgoid.gojekapi.comtoaccounts.goto-products.comKnown Limitations
validation_jwt(PIN encryption) is generated client-side by the appTested with Gojek iOS app v5.57.2.