first commit
This commit is contained in:
34
test_github.sh
Normal file
34
test_github.sh
Normal file
@@ -0,0 +1,34 @@
|
||||
#!/bin/bash
|
||||
|
||||
# GitHub OAuth Test Script
|
||||
# Usage: ./test_github.sh <access_token>
|
||||
|
||||
if [ -z "$1" ]; then
|
||||
echo "❌ Access token gerekli!"
|
||||
echo ""
|
||||
echo "Kullanım: ./test_github.sh <access_token>"
|
||||
echo ""
|
||||
echo "Personal Access Token almak için:"
|
||||
echo "1. https://github.com/settings/tokens"
|
||||
echo "2. Generate new token (classic)"
|
||||
echo "3. Scopes: user, user:email"
|
||||
echo "4. Token'ı kopyala"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
ACCESS_TOKEN="$1"
|
||||
|
||||
echo "⚫ GitHub OAuth Test"
|
||||
echo "===================="
|
||||
echo ""
|
||||
echo "📤 Request gönderiliyor..."
|
||||
echo ""
|
||||
|
||||
curl -X POST http://localhost:8000/api/v1/auth/social/github/ \
|
||||
-H "Content-Type: application/json" \
|
||||
-d "{\"access_token\":\"$ACCESS_TOKEN\"}" \
|
||||
| python -m json.tool
|
||||
|
||||
echo ""
|
||||
echo "===================="
|
||||
|
||||
Reference in New Issue
Block a user