Skip to content

Commit 9c0cb42

Browse files
author
Remote release bot
committed
release v0.0.1
0 parents  commit 9c0cb42

7 files changed

Lines changed: 690 additions & 0 deletions

File tree

.claude-plugin/marketplace.json

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
{
2+
"name": "remote-cli",
3+
"owner": {
4+
"name": "Remote"
5+
},
6+
"plugins": [
7+
{
8+
"name": "remote-cli",
9+
"source": "./plugins/remote-cli",
10+
"description": "Tools and skills for interacting with the Remote.com partner API from the command line.",
11+
"version": "v0.0.1"
12+
}
13+
]
14+
}

LICENSE

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
MIT License
2+
3+
Copyright (c) 2026 Remote Technology Inc.
4+
5+
Permission is hereby granted, free of charge, to any person obtaining a copy
6+
of this software and associated documentation files (the "Software"), to deal
7+
in the Software without restriction, including without limitation the rights
8+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9+
copies of the Software, and to permit persons to whom the Software is
10+
furnished to do so, subject to the following conditions:
11+
12+
The above copyright notice and this permission notice shall be included in all
13+
copies or substantial portions of the Software.
14+
15+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21+
SOFTWARE.

README.md

Lines changed: 61 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,61 @@
1+
# remote-cli
2+
3+
Public binaries and Claude Code plugin marketplace for the Remote.com partner API CLI.
4+
5+
This repository is generated by an automated release pipeline. Do not open pull requests here — source lives elsewhere.
6+
7+
## Install
8+
9+
One-line install (latest release, `/usr/local/bin/remotecli`):
10+
11+
```sh
12+
curl -fsSL https://raw.githubusercontent.com/remoteoss/remote-cli/main/install.sh | sh
13+
```
14+
15+
Override the install location or pin a version:
16+
17+
```sh
18+
INSTALL_DIR="$HOME/bin" VERSION=v1.2.0 \
19+
sh -c "$(curl -fsSL https://raw.githubusercontent.com/remoteoss/remote-cli/main/install.sh)"
20+
```
21+
22+
## Manual download
23+
24+
Grab a binary from the [latest release](https://github.com/remoteoss/remote-cli/releases/latest):
25+
26+
| Platform | Asset |
27+
|---|---|
28+
| macOS (Apple Silicon) | `remotecli-darwin-arm64` |
29+
| Linux (x86_64) | `remotecli-linux-amd64` |
30+
31+
```sh
32+
curl -fsSL -o remotecli \
33+
https://github.com/remoteoss/remote-cli/releases/latest/download/remotecli-darwin-arm64
34+
chmod +x remotecli
35+
mv remotecli /usr/local/bin/
36+
remotecli --version
37+
```
38+
39+
Verify against `SHA256SUMS` from the same release if you care:
40+
41+
```sh
42+
shasum -a 256 remotecli # compare against the published SHA256SUMS
43+
```
44+
45+
## Claude Code skill
46+
47+
This repository is also a Claude Code plugin marketplace:
48+
49+
```
50+
/plugin marketplace add remoteoss/remote-cli
51+
/plugin install remote-cli@remote-cli
52+
/reload-plugins
53+
```
54+
55+
After installing, the `remote-cli` skill is available in Claude Code and knows how to drive the `remotecli` binary.
56+
57+
## Version
58+
59+
Current release: **v0.0.1**
60+
61+
See the [Releases page](https://github.com/remoteoss/remote-cli/releases) for history.

install.sh

Lines changed: 79 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,79 @@
1+
#!/bin/sh
2+
# Install remotecli — Remote.com partner API CLI.
3+
#
4+
# Usage:
5+
# curl -fsSL https://raw.githubusercontent.com/remoteoss/remote-cli/main/install.sh | sh
6+
#
7+
# Env overrides:
8+
# INSTALL_DIR default: /usr/local/bin
9+
# VERSION default: latest (e.g. v1.2.0 to pin)
10+
# REPO default: remoteoss/remote-cli (rarely needed)
11+
12+
set -eu
13+
14+
REPO="${REPO:-remoteoss/remote-cli}"
15+
INSTALL_DIR="${INSTALL_DIR:-/usr/local/bin}"
16+
VERSION="${VERSION:-latest}"
17+
18+
OS=$(uname -s | tr '[:upper:]' '[:lower:]')
19+
case "$OS" in
20+
darwin|linux) ;;
21+
*)
22+
printf 'unsupported OS: %s\n' "$OS" >&2
23+
exit 1
24+
;;
25+
esac
26+
27+
ARCH_RAW=$(uname -m)
28+
case "$ARCH_RAW" in
29+
arm64|aarch64) ARCH=arm64 ;;
30+
x86_64|amd64) ARCH=amd64 ;;
31+
*)
32+
printf 'unsupported architecture: %s\n' "$ARCH_RAW" >&2
33+
exit 1
34+
;;
35+
esac
36+
37+
# Published binaries today: darwin/arm64 and linux/amd64. Other combos error early.
38+
case "$OS-$ARCH" in
39+
darwin-arm64|linux-amd64) ;;
40+
*)
41+
printf 'no published binary for %s-%s\n' "$OS" "$ARCH" >&2
42+
printf 'published: darwin-arm64, linux-amd64\n' >&2
43+
exit 1
44+
;;
45+
esac
46+
47+
ASSET="remotecli-${OS}-${ARCH}"
48+
if [ "$VERSION" = "latest" ]; then
49+
URL="https://github.com/${REPO}/releases/latest/download/${ASSET}"
50+
else
51+
URL="https://github.com/${REPO}/releases/download/${VERSION}/${ASSET}"
52+
fi
53+
54+
TMP=$(mktemp)
55+
trap 'rm -f "$TMP"' EXIT INT TERM
56+
57+
printf 'Downloading %s\n' "$URL"
58+
if ! curl -fsSL -o "$TMP" "$URL"; then
59+
printf 'download failed: %s\n' "$URL" >&2
60+
exit 1
61+
fi
62+
63+
chmod +x "$TMP"
64+
65+
DEST="$INSTALL_DIR/remotecli"
66+
mkdir -p "$INSTALL_DIR" 2>/dev/null || true
67+
68+
if [ -w "$INSTALL_DIR" ]; then
69+
mv "$TMP" "$DEST"
70+
else
71+
printf 'Installing to %s requires elevated permissions.\n' "$INSTALL_DIR"
72+
sudo mv "$TMP" "$DEST"
73+
fi
74+
75+
# mv consumed the tempfile; clear the trap so EXIT doesn't try to remove a missing path.
76+
trap - EXIT INT TERM
77+
78+
printf 'Installed: %s\n' "$DEST"
79+
"$DEST" --version
Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"name": "remote-cli",
3+
"version": "v0.0.1",
4+
"description": "Skill that drives the `remotecli` binary against the Remote.com partner API.",
5+
"author": {
6+
"name": "Remote"
7+
}
8+
}
Lines changed: 115 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,115 @@
1+
---
2+
name: remote-cli
3+
description: Use when the user asks you to perform any Remote.com HR action — create or list time off, manage expenses (approve/decline/download receipts), list or create employments, download payslips, submit terminations — via the ./remote CLI tool in this project. Also triggers when asked to look up leave balance, employment status, or company info through the CLI.
4+
---
5+
6+
# Using the Remote CLI
7+
8+
## Overview
9+
10+
`./remote` is the built binary for this project. Build it with `go build -o remote .` if the binary is missing or stale after code changes.
11+
12+
Requires three environment variables:
13+
```bash
14+
export REMOTE_BASE_URL=https://gateway.remote.com/api/eor
15+
export REMOTE_CLIENT_ID=<your_client_id>
16+
export REMOTE_CLIENT_SECRET=<your_client_secret>
17+
```
18+
19+
An **active company** must be selected before most commands:
20+
```bash
21+
./remote companies list # see what's saved
22+
./remote use # interactively pick the active one
23+
```
24+
25+
## Non-Interactive Usage
26+
27+
Every command that normally prompts can be driven entirely with flags — always prefer flags when acting autonomously. See `references/commands.md` for every flag per command.
28+
29+
## Quick Command Reference
30+
31+
| Command | What it does | Key flags |
32+
|---------|-------------|-----------|
33+
| `login` | Authenticate via browser (PKCE) ||
34+
| `use` | Pick active company (interactive) ||
35+
| `me` | Show current identity ||
36+
| `companies list` | List saved companies | `--pretty` |
37+
| `companies create` | Create a company ||
38+
| `employments list` | List employments | `--status`, `--email`, `--all` |
39+
| `employments create` | Onboard a new employee | `--country` |
40+
| `employments show <id>` | Get a single employment ||
41+
| `expenses list` | List expenses | `--employment-id`, `--pretty` |
42+
| `expenses create` | Submit an expense | `--employment-id`, `--amount`, `--currency`, `--expense-date` |
43+
| `expenses approve` | Approve a pending expense | `--expense-id` |
44+
| `expenses decline` | Decline a pending expense | `--expense-id`, `--reason` |
45+
| `expenses download-receipt` | Download a receipt file | `--expense-id`, `--out-file` |
46+
| `payslips list` | List payslips | `--employment-id`, `--start-date`, `--end-date` |
47+
| `payslips download` | Download a payslip PDF | `--payslip-id`, `--out-file` |
48+
| `time-off policies` | List leave policies | `--employment-id` |
49+
| `time-off balance` | Show leave balance | `--employment-id` |
50+
| `time-off create` | Create approved time off | `--employment-id`, `--timeoff-type`, `--start-date`, `--end-date` |
51+
| `time-off list` | List time off records | `--employment-id`, `--status` |
52+
| `time-off approve` | Approve a requested time off | `--timeoff-id` |
53+
| `time-off cancel` | Cancel approved time off | `--timeoff-id`, `--reason` |
54+
| `time-off decline` | Decline a requested time off | `--timeoff-id`, `--reason` |
55+
| `terminations list` | List terminations | `--employment-id`, `--type` |
56+
| `terminations create` | Submit a termination request | `--employment-id` |
57+
58+
## Common Workflows
59+
60+
**Create time off for an employee:**
61+
```bash
62+
./remote time-off create \
63+
--employment-id emp_abc123 \
64+
--timeoff-type time_off \
65+
--start-date 2026-05-09 \
66+
--end-date 2026-05-09
67+
```
68+
Common types: `time_off`, `sick_leave`, `paid_time_off`, `public_holiday`, `unpaid_leave`, `maternity_leave`, `paternity_leave`, `bereavement`. Full list in `references/commands.md`.
69+
70+
**List active employments:**
71+
```bash
72+
./remote employments list --status active --pretty
73+
```
74+
75+
**Approve a pending expense:**
76+
```bash
77+
./remote expenses approve --expense-id exp_xyz789
78+
```
79+
80+
**Download the latest payslip for an employment:**
81+
```bash
82+
./remote payslips list --employment-id emp_abc123 --pretty
83+
./remote payslips download --payslip-id <id> --out-file ./payslip.pdf
84+
```
85+
86+
**Check an employee's leave balance:**
87+
```bash
88+
./remote time-off balance --employment-id emp_abc123 --pretty
89+
```
90+
91+
## Output Control
92+
93+
```bash
94+
./remote <cmd> # JSON output (default)
95+
./remote <cmd> --pretty # human-readable table
96+
./remote <cmd> --all # fetch all pages (list commands; default page-size: 100)
97+
```
98+
99+
## Role Restrictions
100+
101+
These operations require a **company manager token** and fail with employee tokens:
102+
- `expenses create / approve / decline`
103+
- `time-off create / approve / decline`
104+
- `terminations create`
105+
106+
Employee tokens use different endpoints (`/v1/employee/...`) and expose a read-only subset.
107+
108+
## Constraints to Know
109+
110+
- `expenses create --expense-date` must be **today or in the past** — future dates are rejected by the API.
111+
- File uploads (receipts, termination docs): PDF/DOC/DOCX only, max 10 MB each, max 5 files.
112+
113+
## Full Reference
114+
115+
See `references/commands.md` for every flag, valid enum values, and pagination options for each command.

0 commit comments

Comments
 (0)