شعار Google Workspace Setup

Google Workspace Setup

المجتمع
adityahimaone
google-workspace-setup

Properly set up Google Workspace OAuth2 authentication for Hermes agent, handling Python environment and module dependencies.

نظرة عامة

الناشرadityahimaone
المستودعhermes-agent-rtk-caveman
اسم المهارةgoogle-workspace-setup
النجوم
84
التفريعات
4
الملفات المرفقة
تعليمات فقط
الروابط
  • تعليمات بصيغة Markdown

    ملف SKILL.md يُحمّله النموذج عند الحاجة، فلا يستهلك توكنات إلا عندما يَرِد طلب ذو صلة فعلًا.

  • تعمل مع أي نموذج لغوي كبير

    مهارات الذكاء الاصطناعي مكتوبة بصيغة Markdown وليست شيفرة خاصة بمزوّد معيّن، لذا تعمل مع GPT أو Claude أو Gemini أو Grok أو نموذج محلي.

  • مكتفية بذاتها

    كل ما يحتاجه النموذج موجود في التعليمات — لا ملفات إضافية لمزامنتها.

  • مفتوحة المصدر

    نشرها adityahimaone على GitHub. اطّلع على المصدر قبل تثبيتها.

التثبيت

ثبّت مهارة الذكاء الاصطناعي Google Workspace Setup في TypingMind لاستخدامها مع أي نموذج لغوي كبير، أو أضفها إلى وكيل ذكاء اصطناعي آخر يقرأ SKILL.md.

1

التثبيت في TypingMind

يُثبّت TypingMind المهارة مباشرةً من مجلدها على GitHub — فيقرأ SKILL.md، ويجمع ملفات الموارد في حزمة، ويحفظ النتيجة محليًا.

  1. افتح التطبيق وانتقل إلى الإضافات → المهارات.
  2. اختر «تثبيت من GitHub».
  3. الصق رابط مجلد المهارة الموضّح أدناه وأكّد التثبيت.
    https://github.com/adityahimaone/hermes-agent-rtk-caveman/tree/main/skills/productivity/google-workspace-setup
  4. فعّل المهارة في كل محادثة تريد إتاحتها فيها.
الإضافات → المهارات → إضافة مهارة → من رابط GitHub، ثم الصق رابط المجلد واضغط على «متابعة».
2

التثبيت في وكيل ذكاء اصطناعي آخر

يمكن لأي وكيل ذكاء اصطناعي يقرأ تنسيق Agent Skills استخدام هذه المهارة — انسخ المجلد إلى مجلد المهارات الخاص بذلك الوكيل.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/adityahimaone/hermes-agent-rtk-caveman.git /tmp/hermes-agent-rtk-caveman
mkdir -p .claude/skills
cp -r /tmp/hermes-agent-rtk-caveman/skills/productivity/google-workspace-setup .claude/skills/google-workspace-setup
أعد تشغيل Claude Code بعد النسخ ليتعرّف على المهارة الجديدة.

استخدمها في TypingMind

فعّل Google Workspace Setup في أي محادثة على TypingMind وسيتولى النموذج الباقي. تتضمن مطالبة النظام اسمها ووصفها، وبمجرد ورود طلب ذي صلة، يُحمّل النموذج التعليمات الكاملة تلقائيًا — فلا تحتاج إلى استدعائها يدويًا، ولا تستهلك أي توكنات حتى تُستخدم فعليًا.

يُحمّل النموذج Google Workspace Setup تلقائيًا بمجرد ورود طلب ذي صلة بها.

تعمل مع أي نموذج ذكاء اصطناعي

مهارات الذكاء الاصطناعي هي تعليمات بصيغة Markdown وليست شيفرة خاصة بمزوّد معيّن، لذا لا ترتبط Google Workspace Setup بالنموذج الذي كُتبت له. ثبّتها مرة واحدة في TypingMind واستخدمها مع GPT-5 أو Claude أو Gemini أو Grok أو DeepSeek أو Mistral أو Llama أو نموذج محلي تشغّله بنفسك — كل ذلك باستخدام مفاتيح API الخاصة بك.

  • تُحمَّل عند الحاجة فقط

    تتضمن مطالبة النظام الاسم والوصف فقط. وتُجلب التعليمات عند أول طلب ذي صلة، لذا لا تترتب أي تكلفة على المهارة غير المستخدمة.

  • بدّل النماذج أثناء المحادثة

    لأن المهارة تعليمات وليست شيفرة، فإن تغيير النموذج لا يعطّلها — فالنموذج التالي يقرأ ملف SKILL.md نفسه.

تعليمات المهارة

هذا هو محتوى SKILL.md الذي يُحمّله النموذج. اقرأه قبل التثبيت — فالمهارة عبارة عن تعليمات سيتبعها نموذجك.

Google Workspace Setup Skill

This skill provides a reliable method to set up Google Workspace OAuth2 authentication for the Hermes agent, addressing common issues with Python module imports and environment configuration.

Problem

The standard Google Workspace setup script (setup.py) fails with ModuleNotFoundError: No module named 'hermes_constants' when run directly because:

  1. The script depends on Hermes internal modules
  2. It needs to be run from the Hermes agent directory with proper Python path
  3. Virtual environment activation is required for dependencies

Solution

Always activate the Hermes virtual environment and run the setup script from the hermes-agent directory.

Prerequisites

  • Google OAuth2 client secret JSON file (from Google Cloud Console)
  • Hermes agent installed and accessible

Steps

Step 1: Prepare OAuth Credentials

  1. Go to https://console.cloud.google.com/apis/credentials
  2. Create/select a project
  3. Enable required APIs: Gmail, Calendar, Drive, Sheets, Docs, People API
  4. Create OAuth 2.0 Client ID (Desktop app type)
  5. Download the JSON file

Step 2: Copy Credentials to Hermes Directory

bash
# Copy your downloaded client secret to Hermes Google Workspace skill directory
cp /path/to/downloaded/client_secret_*.json ~/.hermes/skills/productivity/google-workspace/google_client_secret.json

Step 3: Run Setup with Proper Environment

bash
# Change to Hermes agent directory and activate virtual environment
cd ~/.hermes/hermes-agent
source venv/bin/activate

# Run the setup script with your client secret
python ~/.hermes/skills/productivity/google-workspace/scripts/setup.py --client-secret ~/.hermes/skills/productivity/google-workspace/google_client_secret.json

# You should see: "OK: Client secret saved to /Users/yourname/.hermes/google_client_secret.json"

Step 4: Get Authorization URL

bash
# Still in the same terminal session (venv activated, in hermes-agent directory)
python ~/.hermes/skills/productivity/google-workspace/scripts/setup.py --auth-url

# Copy the entire URL output and open it in your browser

Step 5: Complete Authorization

  1. Open the URL from Step 4 in your browser
  2. Sign in with your Google account
  3. Grant the requested permissions
  4. After redirection (may show an error page - this is normal), copy the ENTIRE URL from the browser's address bar

Step 6: Exchange Authorization Code

bash
# Still in the same terminal session
python ~/.hermes/skills/productivity/google-workspace/scripts/setup.py --auth-code "PASTE_THE_ENTIRE_URL_FROM_STEP_5_HERE"

# You should see: "OK: Token saved to /Users/yourname/.hermes/google_token.json"

Step 7: Verify Authentication

bash
# Still in the same terminal session
python ~/.hermes/skills/productivity/google-workspace/scripts/setup.py --check

# Should output: "AUTHENTICATED"

Verification

After successful setup, you can test Google Workspace access:

bash
# Test Gmail access
python ~/.hermes/skills/productivity/google-workspace/scripts/google_api.py gmail search "is:unread" --max 5

# Test Calendar access
python ~/.hermes/skills/productivity/google-workspace/scripts/google_api.py calendar list

Notes

  • Must maintain same terminal session: Steps 3-7 need to be run in the same terminal session where the venv is activated and you're in the hermes-agent directory
  • Token storage: The OAuth token is saved automatically to ~/.hermes/google_token.json and refreshes automatically
  • Re-authentication: To revoke and restart, use --revoke flag then repeat from Step 3
  • Troubleshooting:
    • If you get ModuleNotFoundError again, you likely left the hermes-agent directory or deactivated the venv
    • If you get permission errors, ensure you enabled all required APIs in Google Cloud Console
    • For Advanced Protection accounts, your Workspace admin needs to allowlist the OAuth client ID

Integration with Market Alpha Scout

Once Google Workspace is authenticated, the market_alpha_scout skill can successfully:

  1. Authenticate to stockbro.id via Google Workspace
  2. Scrape Daily Hot Stocks and Broker Summary data
  3. Combine with Google-based sentiment analysis for stock picks

Error Handling

Common errors and solutions:

  • ModuleNotFoundError: No module named 'hermes_constants' → Not in hermes-agent directory or venv not activated
  • FileNotFoundError for client secret → Check file path and permissions
  • invalid_grant → Token expired, redo authorization flow
  • 403: Insufficient Permission → Missing API scopes, redo OAuth flow with all required APIs enabled

الأسئلة الشائعة

ماذا تفعل مهارة الذكاء الاصطناعي Google Workspace Setup؟

Properly set up Google Workspace OAuth2 authentication for Hermes agent, handling Python environment and module dependencies.

لماذا تستخدم Google Workspace Setup على TypingMind؟

لأنك تثبّتها مرة واحدة وتستخدمها مع أي نموذج. مهارة Google Workspace Setup عبارة عن نص Markdown وليست شيفرة خاصة بمزود بعينه، لذا تعمل المهارة نفسها مع GPT-5 أو Claude أو Gemini أو Grok أو نموذج محلي، ويمكنك تبديل النموذج أثناء المحادثة دون تعطّل المهارة. يعمل TypingMind بمفاتيح API الخاصة بك، فتدفع للمزودين مباشرةً بدلًا من اشتراك لكل مقعد، وتبقى مهاراتك ومحادثاتك في مساحة التخزين الخاصة بك.

كيف أثبّت Google Workspace Setup في TypingMind؟

افتح الإضافات → المهارات → التثبيت من GitHub في TypingMind والصق https://github.com/adityahimaone/hermes-agent-rtk-caveman/tree/main/skills/productivity/google-workspace-setup. يقرأ TypingMind ملف SKILL.md الخاص بها ويثبّتها كمهارة يمكنك تفعيلها لكل محادثة على حدة.

ما نماذج الذكاء الاصطناعي التي يمكنها استخدام Google Workspace Setup؟

أي نموذج تربطه في TypingMind. مهارات الذكاء الاصطناعي عبارة عن تعليمات Markdown وليست شيفرة خاصة بمزود بعينه، لذا يمكن لكل من GPT وClaude وGemini وGrok والنماذج المحلية تحميل هذه المهارة عندما يتوافق الطلب معها.

كم نموذج ذكاء اصطناعي يمكنني استخدامه مع Google Workspace Setup؟

أي عدد تريده. ما دام النموذج يدعم المهارات، يمكنك استخدام Google Workspace Setup معه، سواء كان GPT أو Claude أو Gemini أو Grok أو DeepSeek أو Mistral أو Llama أو غيرها، وكل ذلك على TypingMind باستخدام مفاتيح API الخاصة بك.

هل مهارة الذكاء الاصطناعي Google Workspace Setup مجانية؟

نشرها adityahimaone على GitHub. راجع المستودع للاطلاع على شروط الترخيص. لا تدفع إلا لمزود الذكاء الاصطناعي الخاص بك مقابل التوكنات التي تستخدمها.

ما هي مهارات الذكاء الاصطناعي؟

مهارة الذكاء الاصطناعي حزمة تعليمات قابلة لإعادة الاستخدام تعلّم نموذج الذكاء الاصطناعي كيفية تنفيذ مهمة محددة. وتتبع تنسيق Agent Skills المفتوح: ملف SKILL.md يتضمن اسمًا ووصفًا، إلى جانب أي نصوص برمجية أو قوالب أو ملفات مرجعية قد يحتاج إليها النموذج. لا يقرأ النموذج التعليمات إلا عندما يتوافق طلبك مع المهارة، لذا لا تترتب على المهارة المثبتة أي تكلفة حتى تُستخدم.

كيف تختلف مهارات الذكاء الاصطناعي عن الإضافات أو موصلات MCP؟

تمنح الإضافة أو موصل MCP النموذج أدوات جديدة يمكنه استدعاؤها، وهي شيفرة تُنفَّذ في مكان ما وتُرجع نتيجة. أما مهارة الذكاء الاصطناعي فتزوّد النموذج بالمعرفة ومنهجية العمل: كيفية التعامل مع مهمة، والخطوات التي ينبغي اتباعها، وما ينبغي أن تكون عليه المخرجات الجيدة. المهارات عبارة عن نصوص Markdown، لذا لا تحتاج إلى خادم أو مفتاح API أو بيئة تشغيل، وتعمل مع أي نموذج.

عرض الكل

أنشئ مساحة عملك للذكاء الاصطناعي الآن

اشترك في نشرتنا البريدية لتصلك أخبار الميزات الجديدة والهدايا القادمة 👇