replicas-cli 0.2.470 → 0.2.472
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.mjs +15 -11
- package/package.json +1 -1
package/dist/index.mjs
CHANGED
|
@@ -9325,7 +9325,7 @@ LENGTH=$(stat -c%s "$FILE" 2>/dev/null || stat -f%z "$FILE")
|
|
|
9325
9325
|
|
|
9326
9326
|
# 1. Reserve an upload URL + file ID.
|
|
9327
9327
|
RESERVE=$(curl -s -G "https://slack.com/api/files.getUploadURLExternal" \\
|
|
9328
|
-
-H "Authorization: Bearer $
|
|
9328
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN" \\
|
|
9329
9329
|
--data-urlencode "filename=$FILENAME" \\
|
|
9330
9330
|
--data-urlencode "length=$LENGTH")
|
|
9331
9331
|
UPLOAD_URL=$(echo "$RESERVE" | jq -r '.upload_url')
|
|
@@ -9340,7 +9340,7 @@ curl -s -X POST "$UPLOAD_URL" \\
|
|
|
9340
9340
|
|
|
9341
9341
|
# 3. Complete the upload, sharing it into the channel/thread with the dashboard link.
|
|
9342
9342
|
curl -s -X POST "https://slack.com/api/files.completeUploadExternal" \\
|
|
9343
|
-
-H "Authorization: Bearer $
|
|
9343
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN" \\
|
|
9344
9344
|
-H "Content-Type: application/json; charset=utf-8" \\
|
|
9345
9345
|
-d "{
|
|
9346
9346
|
\\"files\\": [{\\"id\\": \\"$FILE_ID\\", \\"title\\": \\"Screenshot\\"}],
|
|
@@ -9851,10 +9851,10 @@ This guide covers how to interact with Slack from within your Replicas workspace
|
|
|
9851
9851
|
|
|
9852
9852
|
## Prerequisites
|
|
9853
9853
|
|
|
9854
|
-
Check if the \`
|
|
9854
|
+
Check if the \`REPLICAS_SLACK_BOT_TOKEN\` environment variable is set:
|
|
9855
9855
|
|
|
9856
9856
|
\`\`\`bash
|
|
9857
|
-
echo "\${
|
|
9857
|
+
echo "\${REPLICAS_SLACK_BOT_TOKEN:+set}"
|
|
9858
9858
|
\`\`\`
|
|
9859
9859
|
|
|
9860
9860
|
- If **set**: Your workspace has Slack access. You can use the Slack Web API as described below.
|
|
@@ -9862,7 +9862,7 @@ echo "\${SLACK_BOT_TOKEN:+set}"
|
|
|
9862
9862
|
|
|
9863
9863
|
## Using the Slack API
|
|
9864
9864
|
|
|
9865
|
-
All requests use the \`$
|
|
9865
|
+
All requests use the \`$REPLICAS_SLACK_BOT_TOKEN\` for authentication via the Slack Web API.
|
|
9866
9866
|
|
|
9867
9867
|
### Fetching a Thread from a Slack Link
|
|
9868
9868
|
|
|
@@ -9873,14 +9873,14 @@ If you encounter a Slack message link (e.g. \`https://team.slack.com/archives/C0
|
|
|
9873
9873
|
|
|
9874
9874
|
\`\`\`bash
|
|
9875
9875
|
curl -s "https://slack.com/api/conversations.replies?channel=CHANNEL_ID&ts=THREAD_TS" \\
|
|
9876
|
-
-H "Authorization: Bearer $
|
|
9876
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN"
|
|
9877
9877
|
\`\`\`
|
|
9878
9878
|
|
|
9879
9879
|
### Sending a Message
|
|
9880
9880
|
|
|
9881
9881
|
\`\`\`bash
|
|
9882
9882
|
curl -s -X POST "https://slack.com/api/chat.postMessage" \\
|
|
9883
|
-
-H "Authorization: Bearer $
|
|
9883
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN" \\
|
|
9884
9884
|
-H "Content-Type: application/json" \\
|
|
9885
9885
|
-d '{
|
|
9886
9886
|
"channel": "CHANNEL_ID",
|
|
@@ -9919,7 +9919,7 @@ The channel and thread flags default to \`SLACK_CHANNEL_ID\` and \`SLACK_THREAD_
|
|
|
9919
9919
|
|
|
9920
9920
|
\`\`\`bash
|
|
9921
9921
|
curl -s "https://slack.com/api/search.messages?query=YOUR_SEARCH_QUERY" \\
|
|
9922
|
-
-H "Authorization: Bearer $
|
|
9922
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN"
|
|
9923
9923
|
\`\`\`
|
|
9924
9924
|
|
|
9925
9925
|
### Uploading Files
|
|
@@ -9933,7 +9933,7 @@ LENGTH=$(stat -c%s "$FILE" 2>/dev/null || stat -f%z "$FILE")
|
|
|
9933
9933
|
|
|
9934
9934
|
# 1. Reserve an upload URL + file ID.
|
|
9935
9935
|
RESERVE=$(curl -s -G "https://slack.com/api/files.getUploadURLExternal" \\
|
|
9936
|
-
-H "Authorization: Bearer $
|
|
9936
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN" \\
|
|
9937
9937
|
--data-urlencode "filename=$FILENAME" \\
|
|
9938
9938
|
--data-urlencode "length=$LENGTH")
|
|
9939
9939
|
UPLOAD_URL=$(echo "$RESERVE" | jq -r '.upload_url')
|
|
@@ -9948,7 +9948,7 @@ curl -s -X POST "$UPLOAD_URL" \\
|
|
|
9948
9948
|
|
|
9949
9949
|
# 3. Complete the upload and share into a channel (and optionally a thread).
|
|
9950
9950
|
curl -s -X POST "https://slack.com/api/files.completeUploadExternal" \\
|
|
9951
|
-
-H "Authorization: Bearer $
|
|
9951
|
+
-H "Authorization: Bearer $REPLICAS_SLACK_BOT_TOKEN" \\
|
|
9952
9952
|
-H "Content-Type: application/json; charset=utf-8" \\
|
|
9953
9953
|
-d "{
|
|
9954
9954
|
\\"files\\": [{\\"id\\": \\"$FILE_ID\\", \\"title\\": \\"File title\\"}],
|
|
@@ -10084,7 +10084,7 @@ function formatTurnElapsed(ms) {
|
|
|
10084
10084
|
}
|
|
10085
10085
|
|
|
10086
10086
|
// ../shared/src/cli-version.ts
|
|
10087
|
-
var CLI_VERSION = "0.2.
|
|
10087
|
+
var CLI_VERSION = "0.2.472";
|
|
10088
10088
|
|
|
10089
10089
|
// ../shared/src/version.ts
|
|
10090
10090
|
function compareVersions(v1, v2) {
|
|
@@ -24754,6 +24754,10 @@ function applyCodexAspTranscriptDelta(current, delta) {
|
|
|
24754
24754
|
};
|
|
24755
24755
|
}
|
|
24756
24756
|
|
|
24757
|
+
// ../shared/src/routes/client-state.ts
|
|
24758
|
+
var MAX_CLIENT_STATE_REQUEST_BYTES = 5 * 1024 * 1024;
|
|
24759
|
+
var MAX_CLIENT_STATE_BYTES_PER_USER = 10 * 1024 * 1024;
|
|
24760
|
+
|
|
24757
24761
|
// ../shared/src/routes/workspaces.ts
|
|
24758
24762
|
var WORKSPACE_STATUSES = ["active", "sleeping", "archived", "preparing", "error"];
|
|
24759
24763
|
function isWorkspaceSuspendedStatus(status) {
|