PKCE తో ఖాతాను అధికారం ఇవ్వండి
authorization code మరియు S256 PKCE ను confidential మరియు public applications కోసం ఉపయోగించండి.
- ప్రతి అనుమతికి క్రిప్టోగ్రాఫిక్గా ర్యాండమ్ స్టేట్ మరియు కొత్త PKCE వెరిఫైయర్ను ఉత్పత్తి చేయండి. S256 ఛాలెంజ్ను లెక్కించండి.
- client_id, ఖచ్చితమైన redirect_uri, response_type=code, scope, state, code_challenge మరియు code_challenge_method=S256 తో అనుమతి ఎండ్పాయింట్కు రీడైరెక్ట్ చేయండి.
- కస్టమర్ సైన్ ఇన్ చేస్తారు, వారి వ్యక్తిగత లేదా సంస్థ ఖాతాను ఎంచుకుంటారు, స్కోపులను సమీక్షిస్తారు మరియు ఏదైనా బిల్లింగ్ ప్రణాళికను ఆమోదిస్తారు.
- మీ callback వద్ద స్థితిని ధృవీకరించండి. అసలు redirect URI మరియు code_verifier తో కోడ్ను ఒకసారి మార్పిడి చేయండి.
- టోకెన్లను సురక్షితంగా నిల్వ చేయండి. కస్టమర్ గుర్తింపుగా తిరిగి వచ్చిన client-scoped subject ను ఉపయోగించండి.
https://auth.shareai.now/oauth/token- బేస్ URL
https://auth.shareai.now- authentication
- పబ్లిక్ client ID + PKCE, లేదా confidential client authentication + PKCE
cURL
curl --fail-with-body 'https://auth.shareai.now/oauth/token' --data-urlencode 'grant_type=authorization_code' --data-urlencode "client_id=$SHAREAI_CLIENT_ID" --data-urlencode "code=$AUTHORIZATION_CODE" --data-urlencode 'redirect_uri=https://your-app.example/callback' --data-urlencode "code_verifier=$PKCE_VERIFIER"
ఈ ఉదాహరణ ఒక public client కోసం. ఒక secret లేదా HTTP Basic credentials ను జోడించవద్దు. ఒక confidential client తన server-side client credentials తో పాటు PKCE ఉపయోగించి authenticate చేస్తుంది. confidential secret ను browser, desktop, mobile లేదా self-hosted distributions లో ఎప్పుడూ పంపించవద్దు.
డిస్కవరీ: https://auth.shareai.now/.well-known/openid-configurationప్రకటన చేసిన endpoints మరియు signing keys ను ఉపయోగించండి. state mismatches, అనూహ్య issuers మరియు చెల్లని ID-token audience లేదా signature ను తిరస్కరించండి.
ప్రమాణాలు: OAuth భద్రత ఉత్తమ పద్ధతులు మరియు PKCE. రిఫ్రెష్ టోకెన్లు.
చివరిసారిగా నవీకరించబడింది సెప్టెంబర్ 18, 2026