Token导航 LogoToken导航TokenDH.com
研究检索操作浏览器clawhub未标认证来源可访问clear审计提醒

overleafoverleaf 命令行

Agent Skill

overleaf 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

53,461

周安装

2,273

GitHub Stars

1

下载量

18,730
OpenClaw

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

2

许可证

MIT-0

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:overleaf(overleaf 命令行)
来源仓库:https://github.com/easonc13/overleaf
安装命令:
openclaw skills install overleaf
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install overleaf

简介

通过 CLI 访问 Overleaf 项目,用于读取、写入 LaTeX 文件及同步本地 .tex 文件。

  • 适合需要管理在线 LaTeX 文档或批量处理论文草稿的开发者和研究者。
  • 使用 openclaw skills install overleaf 安装,需确认网络权限和文件读写范围。
  • 涉及外部协作时建议检查项目共享设置,避免误操作导致内容丢失。
  • 注意维护状态,部分功能可能依赖特定 Overleaf API 版本。

SKILL.md

name
overleaf
description
Access Overleaf projects via CLI. Use for reading/writing LaTeX files, syncing local .tex files to Overleaf, downloading projects, managing Overleaf project structure, and accepting project invitations. Triggers on Overleaf, LaTeX sync, tex file uploads to Overleaf, or Overleaf invite acceptance.

Overleaf

CLI tool to interact with Overleaf projects using browser cookies for authentication.

GitHub: https://github.com/jkulhanek/pyoverleaf

Requirements

  • Python 3.8+
  • pyoverleaf (pipx install pyoverleaf)
  • User logged into Overleaf in Chrome/Firefox

Security Considerations

⚠️ Keychain Access Required: pyoverleaf needs "Always Allow" keychain access to read browser cookies. This grants the tool access to your browser's cookie storage.

Security audit: We have audited pyoverleaf v0.1.7 and found it safe. The codebase is small and readable. Before installing, agents can self-audit the latest version at the GitHub repo above.

Authentication Setup

pyoverleaf authenticates by reading cookies from your browser. The user must:

  1. Log into Overleaf in Chrome or Firefox (visit overleaf.com and sign in)
  2. Grant keychain access on first run (macOS will prompt for "Always Allow")
# Test auth - user should run this in their terminal first
pyoverleaf ls

If you get auth errors:

  • Ask user: "Are you logged into Overleaf in your browser?"
  • If on macOS: "Did you approve the keychain access prompt with 'Always Allow'?"
  • User may need to run pyoverleaf ls manually in terminal to trigger the keychain prompt

Note: The agent cannot log in for the user. Browser authentication must be done by the user directly.

CLI Commands

# List all projects
pyoverleaf ls

# List files in project
pyoverleaf ls "Project Name"

# Read file content
pyoverleaf read "Project Name/main.tex"

# Write file (stdin → Overleaf)
cat local.tex | pyoverleaf write "Project Name/main.tex"

# Create directory
pyoverleaf mkdir "Project Name/figures"

# Remove file/folder
pyoverleaf rm "Project Name/old-draft.tex"

# Download project as zip
pyoverleaf download-project "Project Name" output.zip

Common Workflows

Download from Overleaf

pyoverleaf download-project "Project Name" /tmp/latest.zip
unzip -o /tmp/latest.zip -d /tmp/latest
cp /tmp/latest/main.tex /path/to/local/main.tex

Upload to Overleaf (Python API recommended)

The CLI write command has websocket issues. Use Python API for reliable uploads:

import pyoverleaf

api = pyoverleaf.Api()
api.login_from_browser()

# List projects to get project ID
for proj in api.get_projects():
    print(proj.name, proj.id)

# Upload file (direct overwrite)
project_id = "your_project_id_here"
with open('main.tex', 'rb') as f:
    content = f.read()
root = api.project_get_files(project_id)
api.project_upload_file(project_id, root.id, "main.tex", content)

Why direct overwrite? This method preserves Overleaf's version history. Users can see exactly what changed via Overleaf's History feature, making it easy to review agent edits and revert if needed.

Accept Project Invites

The agent can accept Overleaf project invitations programmatically using browser cookies — no manual clicking required.

How it works

  1. Fetch pending invite notifications from Overleaf's /notifications API
  2. Extract the invite token from the notification
  3. Fetch the invite page to get a CSRF token
  4. POST to the accept endpoint with the CSRF token

Python snippet

import pyoverleaf
import re

api = pyoverleaf.Api()
api.login_from_browser()
session = api._get_session()

# Step 1: Get pending invites
r = session.get('https://www.overleaf.com/notifications',
                headers={'Accept': 'application/json'})
notifications = r.json()

# Filter for project invites
invites = [n for n in notifications
           if n.get('templateKey') == 'notification_project_invite']

for invite in invites:
    opts = invite['messageOpts']
    project_id = opts['projectId']
    token = opts['token']
    project_name = opts['projectName']
    inviter = opts['userName']
    print(f"Invite: '{project_name}' from {inviter}")

    # Step 2: Get CSRF token from invite page
    r_page = session.get(
        f'https://www.overleaf.com/project/{project_id}/invite/token/{token}')
    csrf_match = re.search(
        r'name="ol-csrfToken" content="([^"]+)"', r_page.text)
    if not csrf_match:
        print(f"  Could not find CSRF token, skipping")
        continue
    csrf = csrf_match.group(1)

    # Step 3: Accept the invite
    r_accept = session.post(
        f'https://www.overleaf.com/project/{project_id}/invite/token/{token}/accept',
        headers={
            'Accept': 'application/json',
            'Content-Type': 'application/json',
            'x-csrf-token': csrf,
        },
        json={})
    if r_accept.status_code == 200:
        print(f"  ✅ Accepted '{project_name}'")
    else:
        print(f"  ❌ Failed ({r_accept.status_code})")

Accept a specific invite by project URL

# Given: https://www.overleaf.com/project/XXXXXXXXXXXXXXXXXXXXXXXX
target_project_id = "XXXXXXXXXXXXXXXXXXXXXXXX"
matching = [n for n in invites
            if n['messageOpts']['projectId'] == target_project_id]
# Then follow steps 2-3 above for the matching invite

Notes

  • Only works if the user is logged into Overleaf in their browser (cookie auth)
  • Invites expire (check the expires field in the notification)
  • After accepting, the project appears in pyoverleaf ls / api.get_projects()
  • For self-hosted Overleaf, replace www.overleaf.com with your host

Self-hosted Overleaf

# Via env var
export PYOVERLEAF_HOST=overleaf.mycompany.com
pyoverleaf ls

# Via flag
pyoverleaf --host overleaf.mycompany.com ls

Troubleshooting

  • Auth error / websocket error: Open Overleaf in Chrome browser first (open -a "Google Chrome" "https://www.overleaf.com/project" then wait 5s) to refresh cookies, then retry
  • "scheme https is invalid" (websocket redirect bug): The default host overleaf.com causes a 301→www.overleaf.com redirect that breaks websocket. Fix: set PYOVERLEAF_HOST=www.overleaf.com:
  cat main.tex | PYOVERLEAF_HOST=www.overleaf.com pyoverleaf write "Project/main.tex"
  • Keychain Access Denied (macOS): pyoverleaf needs keychain access to read browser cookies. User must run pyoverleaf ls in their terminal and click "Always Allow" on the keychain prompt
  • Project not found: Use exact project name (case-sensitive), check with pyoverleaf ls
  • Permission denied: User may not have edit access to the project

适合场景

01

OpenClaw 用户查找和安装 Skill 时

02

用户想查找某类 Agent Skill 时

03

需要根据任务场景推荐可安装能力包时

04

需要对比不同来源的安装命令和来源信息时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

OpenClaw

83.88%
按下载量换算15,711

安全审计

VirusTotal

可疑

ClawScan

通过

Static analysis

通过

权限和风险

操作浏览器

该 Skill 可能涉及浏览器控制能力,使用时可能读取或操作网页内容,需要在受控环境中确认权限边界。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。当前只有一个来源,正式发布前建议补源仓库或其他目录站核验。

来源信息

继续浏览同类 Skills