#hh #api-bindings #access-token #headhunter #hh-ru

headhunter-bindings

Rust对Headhunter API(https://hh.ru)的绑定

1个不稳定版本

0.1.0 2023年2月4日

#735 in 身份验证

22每月下载次数
headhunter-cli 中使用

MIT 许可证

14KB
291 代码行

bump-my-resume

Build Status Latest Version Documentation

Headhunter的工具,可以自动更新简历

现在您只需在 https://dev.hh.ru/admin 注册应用程序并使用Selenium获取一次访问令牌。此工具将模拟求职网站的活动并保持您的简历处于顶部。

要求

安装

# run ChromeDriver on the another thread (it should use port 9515)
chromedriver &

# pass authorization, this requires a ChromeDriver
cargo build --release
# replace it with your data
./target/release/headhunter-cli auth \
  "client_id" \
  "client_secret" \
  "login" \
  "password"

# credentials are written to response.json
cat response.json

# you can now use the CLI to update the latest date on your resume
./target/release/headhunter-cli bump

在Linux上构建静态链接的二进制文件

我发现这在远程机器上运行很有用。您需要添加一些软件包和musl目标来实现这一点。

# add musl-gcc command
sudo apt install musl-tools

# add linux musl target
rustup target add x86_64-unknown-linux-musl

# build statically linked binary
cargo build --release --target x86_64-unknown-linux-musl

# note: it's available in bit different directory
./target/x86_64-unknown-linux-musl/release/headhunter-cli --help

服务器配置

  1. response.json./target/release/headhunter-cli 放在同一目录中,例如 /root/bump-my-resume
  2. 运行 crontab -e
  3. 按照以下方式添加行:0 */1 * * * cd /root/bump-my-resume && ./target/release/headhunter-cli bump >> out.txt 2>&1

依赖项

~10–24MB
~353K SLoC