@keystrokehq/sendbird 0.1.0
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/README.md +17 -0
- package/dist/action.cjs +21 -0
- package/dist/action.cjs.map +1 -0
- package/dist/action.mjs +21 -0
- package/dist/action.mjs.map +1 -0
- package/dist/actions/add-members-group-channel.cjs +35 -0
- package/dist/actions/add-members-group-channel.cjs.map +1 -0
- package/dist/actions/add-members-group-channel.d.cts +9 -0
- package/dist/actions/add-members-group-channel.d.cts.map +1 -0
- package/dist/actions/add-members-group-channel.d.mts +9 -0
- package/dist/actions/add-members-group-channel.d.mts.map +1 -0
- package/dist/actions/add-members-group-channel.mjs +34 -0
- package/dist/actions/add-members-group-channel.mjs.map +1 -0
- package/dist/actions/ban-user-from-group-channel.cjs +33 -0
- package/dist/actions/ban-user-from-group-channel.cjs.map +1 -0
- package/dist/actions/ban-user-from-group-channel.d.cts +9 -0
- package/dist/actions/ban-user-from-group-channel.d.cts.map +1 -0
- package/dist/actions/ban-user-from-group-channel.d.mts +9 -0
- package/dist/actions/ban-user-from-group-channel.d.mts.map +1 -0
- package/dist/actions/ban-user-from-group-channel.mjs +32 -0
- package/dist/actions/ban-user-from-group-channel.mjs.map +1 -0
- package/dist/actions/create-channel.cjs +77 -0
- package/dist/actions/create-channel.cjs.map +1 -0
- package/dist/actions/create-channel.d.cts +9 -0
- package/dist/actions/create-channel.d.cts.map +1 -0
- package/dist/actions/create-channel.d.mts +9 -0
- package/dist/actions/create-channel.d.mts.map +1 -0
- package/dist/actions/create-channel.mjs +76 -0
- package/dist/actions/create-channel.mjs.map +1 -0
- package/dist/actions/create-user.cjs +41 -0
- package/dist/actions/create-user.cjs.map +1 -0
- package/dist/actions/create-user.d.cts +9 -0
- package/dist/actions/create-user.d.cts.map +1 -0
- package/dist/actions/create-user.d.mts +9 -0
- package/dist/actions/create-user.d.mts.map +1 -0
- package/dist/actions/create-user.mjs +38 -0
- package/dist/actions/create-user.mjs.map +1 -0
- package/dist/actions/delete-channel.cjs +16 -0
- package/dist/actions/delete-channel.cjs.map +1 -0
- package/dist/actions/delete-channel.d.cts +9 -0
- package/dist/actions/delete-channel.d.cts.map +1 -0
- package/dist/actions/delete-channel.d.mts +9 -0
- package/dist/actions/delete-channel.d.mts.map +1 -0
- package/dist/actions/delete-channel.mjs +13 -0
- package/dist/actions/delete-channel.mjs.map +1 -0
- package/dist/actions/delete-message.cjs +19 -0
- package/dist/actions/delete-message.cjs.map +1 -0
- package/dist/actions/delete-message.d.cts +9 -0
- package/dist/actions/delete-message.d.cts.map +1 -0
- package/dist/actions/delete-message.d.mts +9 -0
- package/dist/actions/delete-message.d.mts.map +1 -0
- package/dist/actions/delete-message.mjs +16 -0
- package/dist/actions/delete-message.mjs.map +1 -0
- package/dist/actions/delete-user.cjs +19 -0
- package/dist/actions/delete-user.cjs.map +1 -0
- package/dist/actions/delete-user.d.cts +9 -0
- package/dist/actions/delete-user.d.cts.map +1 -0
- package/dist/actions/delete-user.d.mts +9 -0
- package/dist/actions/delete-user.d.mts.map +1 -0
- package/dist/actions/delete-user.mjs +16 -0
- package/dist/actions/delete-user.mjs.map +1 -0
- package/dist/actions/get-count-preference-of-channel.cjs +26 -0
- package/dist/actions/get-count-preference-of-channel.cjs.map +1 -0
- package/dist/actions/get-count-preference-of-channel.d.cts +9 -0
- package/dist/actions/get-count-preference-of-channel.d.cts.map +1 -0
- package/dist/actions/get-count-preference-of-channel.d.mts +9 -0
- package/dist/actions/get-count-preference-of-channel.d.mts.map +1 -0
- package/dist/actions/get-count-preference-of-channel.mjs +23 -0
- package/dist/actions/get-count-preference-of-channel.mjs.map +1 -0
- package/dist/actions/get-number-of-channels-by-join-status.cjs +40 -0
- package/dist/actions/get-number-of-channels-by-join-status.cjs.map +1 -0
- package/dist/actions/get-number-of-channels-by-join-status.d.cts +9 -0
- package/dist/actions/get-number-of-channels-by-join-status.d.cts.map +1 -0
- package/dist/actions/get-number-of-channels-by-join-status.d.mts +9 -0
- package/dist/actions/get-number-of-channels-by-join-status.d.mts.map +1 -0
- package/dist/actions/get-number-of-channels-by-join-status.mjs +37 -0
- package/dist/actions/get-number-of-channels-by-join-status.mjs.map +1 -0
- package/dist/actions/get-number-of-unread-items.cjs +30 -0
- package/dist/actions/get-number-of-unread-items.cjs.map +1 -0
- package/dist/actions/get-number-of-unread-items.d.cts +9 -0
- package/dist/actions/get-number-of-unread-items.d.cts.map +1 -0
- package/dist/actions/get-number-of-unread-items.d.mts +9 -0
- package/dist/actions/get-number-of-unread-items.d.mts.map +1 -0
- package/dist/actions/get-number-of-unread-items.mjs +27 -0
- package/dist/actions/get-number-of-unread-items.mjs.map +1 -0
- package/dist/actions/index.cjs +75 -0
- package/dist/actions/index.d.cts +38 -0
- package/dist/actions/index.d.mts +38 -0
- package/dist/actions/index.mjs +38 -0
- package/dist/actions/issue-session-token.cjs +23 -0
- package/dist/actions/issue-session-token.cjs.map +1 -0
- package/dist/actions/issue-session-token.d.cts +9 -0
- package/dist/actions/issue-session-token.d.cts.map +1 -0
- package/dist/actions/issue-session-token.d.mts +9 -0
- package/dist/actions/issue-session-token.d.mts.map +1 -0
- package/dist/actions/issue-session-token.mjs +20 -0
- package/dist/actions/issue-session-token.mjs.map +1 -0
- package/dist/actions/leave-group-channels.cjs +21 -0
- package/dist/actions/leave-group-channels.cjs.map +1 -0
- package/dist/actions/leave-group-channels.d.cts +9 -0
- package/dist/actions/leave-group-channels.d.cts.map +1 -0
- package/dist/actions/leave-group-channels.d.mts +9 -0
- package/dist/actions/leave-group-channels.d.mts.map +1 -0
- package/dist/actions/leave-group-channels.mjs +18 -0
- package/dist/actions/leave-group-channels.mjs.map +1 -0
- package/dist/actions/list-banned-members.cjs +31 -0
- package/dist/actions/list-banned-members.cjs.map +1 -0
- package/dist/actions/list-banned-members.d.cts +9 -0
- package/dist/actions/list-banned-members.d.cts.map +1 -0
- package/dist/actions/list-banned-members.d.mts +9 -0
- package/dist/actions/list-banned-members.d.mts.map +1 -0
- package/dist/actions/list-banned-members.mjs +30 -0
- package/dist/actions/list-banned-members.mjs.map +1 -0
- package/dist/actions/list-group-channel-messages.cjs +89 -0
- package/dist/actions/list-group-channel-messages.cjs.map +1 -0
- package/dist/actions/list-group-channel-messages.d.cts +9 -0
- package/dist/actions/list-group-channel-messages.d.cts.map +1 -0
- package/dist/actions/list-group-channel-messages.d.mts +9 -0
- package/dist/actions/list-group-channel-messages.d.mts.map +1 -0
- package/dist/actions/list-group-channel-messages.mjs +88 -0
- package/dist/actions/list-group-channel-messages.mjs.map +1 -0
- package/dist/actions/list-group-channels.cjs +102 -0
- package/dist/actions/list-group-channels.cjs.map +1 -0
- package/dist/actions/list-group-channels.d.cts +9 -0
- package/dist/actions/list-group-channels.d.cts.map +1 -0
- package/dist/actions/list-group-channels.d.mts +9 -0
- package/dist/actions/list-group-channels.d.mts.map +1 -0
- package/dist/actions/list-group-channels.mjs +101 -0
- package/dist/actions/list-group-channels.mjs.map +1 -0
- package/dist/actions/list-members-group-channel.cjs +53 -0
- package/dist/actions/list-members-group-channel.cjs.map +1 -0
- package/dist/actions/list-members-group-channel.d.cts +9 -0
- package/dist/actions/list-members-group-channel.d.cts.map +1 -0
- package/dist/actions/list-members-group-channel.d.mts +9 -0
- package/dist/actions/list-members-group-channel.d.mts.map +1 -0
- package/dist/actions/list-members-group-channel.mjs +52 -0
- package/dist/actions/list-members-group-channel.mjs.map +1 -0
- package/dist/actions/list-operators-custom-channel-type.cjs +29 -0
- package/dist/actions/list-operators-custom-channel-type.cjs.map +1 -0
- package/dist/actions/list-operators-custom-channel-type.d.cts +9 -0
- package/dist/actions/list-operators-custom-channel-type.d.cts.map +1 -0
- package/dist/actions/list-operators-custom-channel-type.d.mts +9 -0
- package/dist/actions/list-operators-custom-channel-type.d.mts.map +1 -0
- package/dist/actions/list-operators-custom-channel-type.mjs +28 -0
- package/dist/actions/list-operators-custom-channel-type.mjs.map +1 -0
- package/dist/actions/list-operators-group-channel.cjs +28 -0
- package/dist/actions/list-operators-group-channel.cjs.map +1 -0
- package/dist/actions/list-operators-group-channel.d.cts +9 -0
- package/dist/actions/list-operators-group-channel.d.cts.map +1 -0
- package/dist/actions/list-operators-group-channel.d.mts +9 -0
- package/dist/actions/list-operators-group-channel.d.mts.map +1 -0
- package/dist/actions/list-operators-group-channel.mjs +27 -0
- package/dist/actions/list-operators-group-channel.mjs.map +1 -0
- package/dist/actions/list-operators-open-channel.cjs +29 -0
- package/dist/actions/list-operators-open-channel.cjs.map +1 -0
- package/dist/actions/list-operators-open-channel.d.cts +9 -0
- package/dist/actions/list-operators-open-channel.d.cts.map +1 -0
- package/dist/actions/list-operators-open-channel.d.mts +9 -0
- package/dist/actions/list-operators-open-channel.d.mts.map +1 -0
- package/dist/actions/list-operators-open-channel.mjs +28 -0
- package/dist/actions/list-operators-open-channel.mjs.map +1 -0
- package/dist/actions/list-users.cjs +50 -0
- package/dist/actions/list-users.cjs.map +1 -0
- package/dist/actions/list-users.d.cts +9 -0
- package/dist/actions/list-users.d.cts.map +1 -0
- package/dist/actions/list-users.d.mts +9 -0
- package/dist/actions/list-users.d.mts.map +1 -0
- package/dist/actions/list-users.mjs +49 -0
- package/dist/actions/list-users.mjs.map +1 -0
- package/dist/actions/mark-all-user-messages-as-read.cjs +16 -0
- package/dist/actions/mark-all-user-messages-as-read.cjs.map +1 -0
- package/dist/actions/mark-all-user-messages-as-read.d.cts +9 -0
- package/dist/actions/mark-all-user-messages-as-read.d.cts.map +1 -0
- package/dist/actions/mark-all-user-messages-as-read.d.mts +9 -0
- package/dist/actions/mark-all-user-messages-as-read.d.mts.map +1 -0
- package/dist/actions/mark-all-user-messages-as-read.mjs +13 -0
- package/dist/actions/mark-all-user-messages-as-read.mjs.map +1 -0
- package/dist/actions/mute-user.cjs +21 -0
- package/dist/actions/mute-user.cjs.map +1 -0
- package/dist/actions/mute-user.d.cts +9 -0
- package/dist/actions/mute-user.d.cts.map +1 -0
- package/dist/actions/mute-user.d.mts +9 -0
- package/dist/actions/mute-user.d.mts.map +1 -0
- package/dist/actions/mute-user.mjs +18 -0
- package/dist/actions/mute-user.mjs.map +1 -0
- package/dist/actions/register-operators-custom-channel-type.cjs +25 -0
- package/dist/actions/register-operators-custom-channel-type.cjs.map +1 -0
- package/dist/actions/register-operators-custom-channel-type.d.cts +9 -0
- package/dist/actions/register-operators-custom-channel-type.d.cts.map +1 -0
- package/dist/actions/register-operators-custom-channel-type.d.mts +9 -0
- package/dist/actions/register-operators-custom-channel-type.d.mts.map +1 -0
- package/dist/actions/register-operators-custom-channel-type.mjs +24 -0
- package/dist/actions/register-operators-custom-channel-type.mjs.map +1 -0
- package/dist/actions/register-operators-group-channel.cjs +28 -0
- package/dist/actions/register-operators-group-channel.cjs.map +1 -0
- package/dist/actions/register-operators-group-channel.d.cts +9 -0
- package/dist/actions/register-operators-group-channel.d.cts.map +1 -0
- package/dist/actions/register-operators-group-channel.d.mts +9 -0
- package/dist/actions/register-operators-group-channel.d.mts.map +1 -0
- package/dist/actions/register-operators-group-channel.mjs +27 -0
- package/dist/actions/register-operators-group-channel.mjs.map +1 -0
- package/dist/actions/register-operators-open-channel.cjs +25 -0
- package/dist/actions/register-operators-open-channel.cjs.map +1 -0
- package/dist/actions/register-operators-open-channel.d.cts +9 -0
- package/dist/actions/register-operators-open-channel.d.cts.map +1 -0
- package/dist/actions/register-operators-open-channel.d.mts +9 -0
- package/dist/actions/register-operators-open-channel.d.mts.map +1 -0
- package/dist/actions/register-operators-open-channel.mjs +24 -0
- package/dist/actions/register-operators-open-channel.mjs.map +1 -0
- package/dist/actions/revoke-all-session-tokens.cjs +19 -0
- package/dist/actions/revoke-all-session-tokens.cjs.map +1 -0
- package/dist/actions/revoke-all-session-tokens.d.cts +9 -0
- package/dist/actions/revoke-all-session-tokens.d.cts.map +1 -0
- package/dist/actions/revoke-all-session-tokens.d.mts +9 -0
- package/dist/actions/revoke-all-session-tokens.d.mts.map +1 -0
- package/dist/actions/revoke-all-session-tokens.mjs +16 -0
- package/dist/actions/revoke-all-session-tokens.mjs.map +1 -0
- package/dist/actions/send-message.cjs +79 -0
- package/dist/actions/send-message.cjs.map +1 -0
- package/dist/actions/send-message.d.cts +9 -0
- package/dist/actions/send-message.d.cts.map +1 -0
- package/dist/actions/send-message.d.mts +9 -0
- package/dist/actions/send-message.d.mts.map +1 -0
- package/dist/actions/send-message.mjs +78 -0
- package/dist/actions/send-message.mjs.map +1 -0
- package/dist/actions/unban-user.cjs +19 -0
- package/dist/actions/unban-user.cjs.map +1 -0
- package/dist/actions/unban-user.d.cts +9 -0
- package/dist/actions/unban-user.d.cts.map +1 -0
- package/dist/actions/unban-user.d.mts +9 -0
- package/dist/actions/unban-user.d.mts.map +1 -0
- package/dist/actions/unban-user.mjs +16 -0
- package/dist/actions/unban-user.mjs.map +1 -0
- package/dist/actions/unmute-user.cjs +26 -0
- package/dist/actions/unmute-user.cjs.map +1 -0
- package/dist/actions/unmute-user.d.cts +9 -0
- package/dist/actions/unmute-user.d.cts.map +1 -0
- package/dist/actions/unmute-user.d.mts +9 -0
- package/dist/actions/unmute-user.d.mts.map +1 -0
- package/dist/actions/unmute-user.mjs +23 -0
- package/dist/actions/unmute-user.mjs.map +1 -0
- package/dist/actions/unregister-operators-custom-channel-type.cjs +23 -0
- package/dist/actions/unregister-operators-custom-channel-type.cjs.map +1 -0
- package/dist/actions/unregister-operators-custom-channel-type.d.cts +9 -0
- package/dist/actions/unregister-operators-custom-channel-type.d.cts.map +1 -0
- package/dist/actions/unregister-operators-custom-channel-type.d.mts +9 -0
- package/dist/actions/unregister-operators-custom-channel-type.d.mts.map +1 -0
- package/dist/actions/unregister-operators-custom-channel-type.mjs +22 -0
- package/dist/actions/unregister-operators-custom-channel-type.mjs.map +1 -0
- package/dist/actions/update-count-preference-of-channel.cjs +28 -0
- package/dist/actions/update-count-preference-of-channel.cjs.map +1 -0
- package/dist/actions/update-count-preference-of-channel.d.cts +9 -0
- package/dist/actions/update-count-preference-of-channel.d.cts.map +1 -0
- package/dist/actions/update-count-preference-of-channel.d.mts +9 -0
- package/dist/actions/update-count-preference-of-channel.d.mts.map +1 -0
- package/dist/actions/update-count-preference-of-channel.mjs +25 -0
- package/dist/actions/update-count-preference-of-channel.mjs.map +1 -0
- package/dist/actions/update-group-channel.cjs +42 -0
- package/dist/actions/update-group-channel.cjs.map +1 -0
- package/dist/actions/update-group-channel.d.cts +9 -0
- package/dist/actions/update-group-channel.d.cts.map +1 -0
- package/dist/actions/update-group-channel.d.mts +9 -0
- package/dist/actions/update-group-channel.d.mts.map +1 -0
- package/dist/actions/update-group-channel.mjs +39 -0
- package/dist/actions/update-group-channel.mjs.map +1 -0
- package/dist/actions/update-message.cjs +54 -0
- package/dist/actions/update-message.cjs.map +1 -0
- package/dist/actions/update-message.d.cts +9 -0
- package/dist/actions/update-message.d.cts.map +1 -0
- package/dist/actions/update-message.d.mts +9 -0
- package/dist/actions/update-message.d.mts.map +1 -0
- package/dist/actions/update-message.mjs +51 -0
- package/dist/actions/update-message.mjs.map +1 -0
- package/dist/actions/update-user.cjs +39 -0
- package/dist/actions/update-user.cjs.map +1 -0
- package/dist/actions/update-user.d.cts +9 -0
- package/dist/actions/update-user.d.cts.map +1 -0
- package/dist/actions/update-user.d.mts +9 -0
- package/dist/actions/update-user.d.mts.map +1 -0
- package/dist/actions/update-user.mjs +36 -0
- package/dist/actions/update-user.mjs.map +1 -0
- package/dist/actions/view-group-channel.cjs +59 -0
- package/dist/actions/view-group-channel.cjs.map +1 -0
- package/dist/actions/view-group-channel.d.cts +9 -0
- package/dist/actions/view-group-channel.d.cts.map +1 -0
- package/dist/actions/view-group-channel.d.mts +9 -0
- package/dist/actions/view-group-channel.d.mts.map +1 -0
- package/dist/actions/view-group-channel.mjs +58 -0
- package/dist/actions/view-group-channel.mjs.map +1 -0
- package/dist/actions/view-message.cjs +67 -0
- package/dist/actions/view-message.cjs.map +1 -0
- package/dist/actions/view-message.d.cts +9 -0
- package/dist/actions/view-message.d.cts.map +1 -0
- package/dist/actions/view-message.d.mts +9 -0
- package/dist/actions/view-message.d.mts.map +1 -0
- package/dist/actions/view-message.mjs +66 -0
- package/dist/actions/view-message.mjs.map +1 -0
- package/dist/actions/view-user.cjs +31 -0
- package/dist/actions/view-user.cjs.map +1 -0
- package/dist/actions/view-user.d.cts +9 -0
- package/dist/actions/view-user.d.cts.map +1 -0
- package/dist/actions/view-user.d.mts +9 -0
- package/dist/actions/view-user.d.mts.map +1 -0
- package/dist/actions/view-user.mjs +28 -0
- package/dist/actions/view-user.mjs.map +1 -0
- package/dist/app.cjs +9 -0
- package/dist/app.cjs.map +1 -0
- package/dist/app.d.cts +5 -0
- package/dist/app.d.cts.map +1 -0
- package/dist/app.d.mts +5 -0
- package/dist/app.d.mts.map +1 -0
- package/dist/app.mjs +10 -0
- package/dist/app.mjs.map +1 -0
- package/dist/catalog.cjs +15 -0
- package/dist/catalog.cjs.map +1 -0
- package/dist/catalog.d.cts +14 -0
- package/dist/catalog.d.cts.map +1 -0
- package/dist/catalog.d.mts +14 -0
- package/dist/catalog.d.mts.map +1 -0
- package/dist/catalog.mjs +15 -0
- package/dist/catalog.mjs.map +1 -0
- package/dist/execute.cjs +18 -0
- package/dist/execute.cjs.map +1 -0
- package/dist/execute.mjs +18 -0
- package/dist/execute.mjs.map +1 -0
- package/dist/index.cjs +80 -0
- package/dist/index.d.cts +40 -0
- package/dist/index.d.mts +40 -0
- package/dist/index.mjs +41 -0
- package/package.json +49 -0
package/README.md
ADDED
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
# @keystrokehq/sendbird
|
|
2
|
+
|
|
3
|
+
Keystroke-managed integration.
|
|
4
|
+
|
|
5
|
+
**App:** `sendbird`
|
|
6
|
+
**Version:** `20260615_00`
|
|
7
|
+
**Actions:** 37
|
|
8
|
+
|
|
9
|
+
```ts
|
|
10
|
+
import { defineAgent } from "@keystrokehq/keystroke/agent";
|
|
11
|
+
import { sendbirdAddMembersGroupChannel } from "@keystrokehq/sendbird/actions";
|
|
12
|
+
|
|
13
|
+
export default defineAgent({
|
|
14
|
+
key: "sendbird-agent",
|
|
15
|
+
tools: [sendbirdAddMembersGroupChannel],
|
|
16
|
+
});
|
|
17
|
+
```
|
package/dist/action.cjs
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
const require_app = require("./app.cjs");
|
|
2
|
+
const require_execute = require("./execute.cjs");
|
|
3
|
+
require("zod");
|
|
4
|
+
//#region src/action.ts
|
|
5
|
+
/** Bind one gateway tool to a typed app action; the call's output is parsed against `def.output`. */
|
|
6
|
+
function action(tool, def) {
|
|
7
|
+
return require_app.sendbird.action({
|
|
8
|
+
slug: def.slug,
|
|
9
|
+
name: def.name,
|
|
10
|
+
description: def.description,
|
|
11
|
+
input: def.input,
|
|
12
|
+
output: def.output,
|
|
13
|
+
async run(input) {
|
|
14
|
+
return def.output.parse(await require_execute.executeSendbirdTool(tool, input));
|
|
15
|
+
}
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
//#endregion
|
|
19
|
+
exports.action = action;
|
|
20
|
+
|
|
21
|
+
//# sourceMappingURL=action.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action.cjs","names":["sendbird","executeSendbirdTool"],"sources":["../src/action.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { sendbird } from \"./app\";\nimport { executeSendbirdTool } from \"./execute\";\n\n/** Bind one gateway tool to a typed app action; the call's output is parsed against `def.output`. */\nexport function action(\n tool: string,\n def: {\n slug: string;\n name: string;\n description: string;\n input: z.ZodTypeAny;\n output: z.ZodTypeAny;\n },\n) {\n return sendbird.action({\n slug: def.slug,\n name: def.name,\n description: def.description,\n input: def.input,\n output: def.output,\n async run(input) {\n return def.output.parse(await executeSendbirdTool(tool, input as Record<string, unknown>));\n },\n });\n}\n"],"mappings":";;;;;AAMA,SAAgB,OACd,MACA,KAOA;CACA,OAAOA,YAAAA,SAAS,OAAO;EACrB,MAAM,IAAI;EACV,MAAM,IAAI;EACV,aAAa,IAAI;EACjB,OAAO,IAAI;EACX,QAAQ,IAAI;EACZ,MAAM,IAAI,OAAO;GACf,OAAO,IAAI,OAAO,MAAM,MAAMC,gBAAAA,oBAAoB,MAAM,KAAgC,CAAC;EAC3F;CACF,CAAC;AACH"}
|
package/dist/action.mjs
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { sendbird } from "./app.mjs";
|
|
2
|
+
import { executeSendbirdTool } from "./execute.mjs";
|
|
3
|
+
import "zod";
|
|
4
|
+
//#region src/action.ts
|
|
5
|
+
/** Bind one gateway tool to a typed app action; the call's output is parsed against `def.output`. */
|
|
6
|
+
function action(tool, def) {
|
|
7
|
+
return sendbird.action({
|
|
8
|
+
slug: def.slug,
|
|
9
|
+
name: def.name,
|
|
10
|
+
description: def.description,
|
|
11
|
+
input: def.input,
|
|
12
|
+
output: def.output,
|
|
13
|
+
async run(input) {
|
|
14
|
+
return def.output.parse(await executeSendbirdTool(tool, input));
|
|
15
|
+
}
|
|
16
|
+
});
|
|
17
|
+
}
|
|
18
|
+
//#endregion
|
|
19
|
+
export { action };
|
|
20
|
+
|
|
21
|
+
//# sourceMappingURL=action.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"action.mjs","names":[],"sources":["../src/action.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { sendbird } from \"./app\";\nimport { executeSendbirdTool } from \"./execute\";\n\n/** Bind one gateway tool to a typed app action; the call's output is parsed against `def.output`. */\nexport function action(\n tool: string,\n def: {\n slug: string;\n name: string;\n description: string;\n input: z.ZodTypeAny;\n output: z.ZodTypeAny;\n },\n) {\n return sendbird.action({\n slug: def.slug,\n name: def.name,\n description: def.description,\n input: def.input,\n output: def.output,\n async run(input) {\n return def.output.parse(await executeSendbirdTool(tool, input as Record<string, unknown>));\n },\n });\n}\n"],"mappings":";;;;;AAMA,SAAgB,OACd,MACA,KAOA;CACA,OAAO,SAAS,OAAO;EACrB,MAAM,IAAI;EACV,MAAM,IAAI;EACV,aAAa,IAAI;EACjB,OAAO,IAAI;EACX,QAAQ,IAAI;EACZ,MAAM,IAAI,OAAO;GACf,OAAO,IAAI,OAAO,MAAM,MAAM,oBAAoB,MAAM,KAAgC,CAAC;EAC3F;CACF,CAAC;AACH"}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
const require_action = require("../action.cjs");
|
|
2
|
+
let zod = require("zod");
|
|
3
|
+
//#region src/actions/add-members-group-channel.ts
|
|
4
|
+
const SendbirdAddMembersGroupChannelInput = zod.z.object({
|
|
5
|
+
seconds: zod.z.number().int().describe("Duration in seconds to hide previous messages. Required if hide_existing_messages is true.").optional(),
|
|
6
|
+
user_ids: zod.z.array(zod.z.string()).describe("List of User IDs to add to the channel."),
|
|
7
|
+
channel_url: zod.z.string().describe("URL-encoded identifier of the target group channel."),
|
|
8
|
+
hide_existing_messages: zod.z.boolean().describe("Whether to hide previous messages for new members.").optional()
|
|
9
|
+
}).describe("Request model for adding members to a group channel.");
|
|
10
|
+
const SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema = zod.z.object({
|
|
11
|
+
user_id: zod.z.string().describe("User ID of the member."),
|
|
12
|
+
nickname: zod.z.string().describe("Nickname of the member.").nullable().optional(),
|
|
13
|
+
is_active: zod.z.boolean().describe("Whether the user is active (online status).").nullable().optional(),
|
|
14
|
+
friend_name: zod.z.string().describe("Friend name if available.").nullable().optional(),
|
|
15
|
+
profile_url: zod.z.string().describe("Profile URL of the member.").nullable().optional(),
|
|
16
|
+
last_seen_at: zod.z.number().int().describe("Timestamp (ms) when the user was last seen.").nullable().optional(),
|
|
17
|
+
member_state: zod.z.string().describe("State of the member in channel (joined, invited, etc.).").nullable().optional(),
|
|
18
|
+
connection_id: zod.z.number().int().describe("Connection identifier if connected.").nullable().optional(),
|
|
19
|
+
hide_start_ts: zod.z.number().int().describe("Timestamp (ms) when hiding messages started for the user.").nullable().optional(),
|
|
20
|
+
registered_at: zod.z.number().int().describe("Timestamp (ms) when the user registered.").nullable().optional(),
|
|
21
|
+
preferred_languages: zod.z.array(zod.z.string()).describe("Preferred language codes of the member.").nullable().optional(),
|
|
22
|
+
require_auth_for_profile_image: zod.z.boolean().describe("Whether the member requires auth for profile image access.").nullable().optional()
|
|
23
|
+
}).describe("Member object returned after adding to group channel.");
|
|
24
|
+
const SendbirdAddMembersGroupChannelOutput = zod.z.object({ members: zod.z.array(SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema).describe("List of members successfully added to the channel.") }).describe("Response model for adding members to a group channel.");
|
|
25
|
+
const sendbirdAddMembersGroupChannel = require_action.action("SENDBIRD_ADD_MEMBERS_GROUP_CHANNEL", {
|
|
26
|
+
slug: "sendbird-add-members-group-channel",
|
|
27
|
+
name: "Add Members To Group Channel",
|
|
28
|
+
description: "Tool to add members to a group channel. Use when you need to invite one or more users into an existing group channel.",
|
|
29
|
+
input: SendbirdAddMembersGroupChannelInput,
|
|
30
|
+
output: SendbirdAddMembersGroupChannelOutput
|
|
31
|
+
});
|
|
32
|
+
//#endregion
|
|
33
|
+
exports.sendbirdAddMembersGroupChannel = sendbirdAddMembersGroupChannel;
|
|
34
|
+
|
|
35
|
+
//# sourceMappingURL=add-members-group-channel.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-members-group-channel.cjs","names":["z","action"],"sources":["../../src/actions/add-members-group-channel.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const SendbirdAddMembersGroupChannelInput: z.ZodTypeAny = z.object({\n seconds: z.number().int().describe(\"Duration in seconds to hide previous messages. Required if hide_existing_messages is true.\").optional(),\n user_ids: z.array(z.string()).describe(\"List of User IDs to add to the channel.\"),\n channel_url: z.string().describe(\"URL-encoded identifier of the target group channel.\"),\n hide_existing_messages: z.boolean().describe(\"Whether to hide previous messages for new members.\").optional(),\n}).describe(\"Request model for adding members to a group channel.\");\nconst SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema: z.ZodTypeAny = z.object({\n user_id: z.string().describe(\"User ID of the member.\"),\n nickname: z.string().describe(\"Nickname of the member.\").nullable().optional(),\n is_active: z.boolean().describe(\"Whether the user is active (online status).\").nullable().optional(),\n friend_name: z.string().describe(\"Friend name if available.\").nullable().optional(),\n profile_url: z.string().describe(\"Profile URL of the member.\").nullable().optional(),\n last_seen_at: z.number().int().describe(\"Timestamp (ms) when the user was last seen.\").nullable().optional(),\n member_state: z.string().describe(\"State of the member in channel (joined, invited, etc.).\").nullable().optional(),\n connection_id: z.number().int().describe(\"Connection identifier if connected.\").nullable().optional(),\n hide_start_ts: z.number().int().describe(\"Timestamp (ms) when hiding messages started for the user.\").nullable().optional(),\n registered_at: z.number().int().describe(\"Timestamp (ms) when the user registered.\").nullable().optional(),\n preferred_languages: z.array(z.string()).describe(\"Preferred language codes of the member.\").nullable().optional(),\n require_auth_for_profile_image: z.boolean().describe(\"Whether the member requires auth for profile image access.\").nullable().optional(),\n}).describe(\"Member object returned after adding to group channel.\");\nexport const SendbirdAddMembersGroupChannelOutput: z.ZodTypeAny = z.object({\n members: z.array(SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema).describe(\"List of members successfully added to the channel.\"),\n}).describe(\"Response model for adding members to a group channel.\");\n\nexport const sendbirdAddMembersGroupChannel = action(\"SENDBIRD_ADD_MEMBERS_GROUP_CHANNEL\", {\n slug: \"sendbird-add-members-group-channel\",\n name: \"Add Members To Group Channel\",\n description: \"Tool to add members to a group channel. Use when you need to invite one or more users into an existing group channel.\",\n input: SendbirdAddMembersGroupChannelInput,\n output: SendbirdAddMembersGroupChannelOutput,\n});\n"],"mappings":";;;AAIA,MAAa,sCAAoDA,IAAAA,EAAE,OAAO;CACxE,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,4FAA4F,CAAC,CAAC,SAAS;CAC1I,UAAUA,IAAAA,EAAE,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,CAAC,SAAS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qBA,IAAAA,EAAE,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,CAAC,SAAS,yCAAyC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACjH,gCAAgCA,IAAAA,EAAE,QAAQ,CAAC,CAAC,SAAS,4DAA4D,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACzI,CAAC,CAAC,CAAC,SAAS,uDAAuD;AACnE,MAAa,uCAAqDA,IAAAA,EAAE,OAAO,EACzE,SAASA,IAAAA,EAAE,MAAM,iEAAiE,CAAC,CAAC,SAAS,oDAAoD,EACnJ,CAAC,CAAC,CAAC,SAAS,uDAAuD;AAEnE,MAAa,iCAAiCC,eAAAA,OAAO,sCAAsC;CACzF,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/actions/add-members-group-channel.d.ts
|
|
4
|
+
declare const SendbirdAddMembersGroupChannelInput: z.ZodTypeAny;
|
|
5
|
+
declare const SendbirdAddMembersGroupChannelOutput: z.ZodTypeAny;
|
|
6
|
+
declare const sendbirdAddMembersGroupChannel: import("@keystrokehq/action").WorkflowActionDefinition<unknown, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { sendbirdAddMembersGroupChannel };
|
|
9
|
+
//# sourceMappingURL=add-members-group-channel.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-members-group-channel.d.cts","names":[],"sources":["../../src/actions/add-members-group-channel.ts"],"mappings":";;;cAIa,mCAAA,EAAqC,CAAA,CAAE,UAKe;AAAA,cAetD,oCAAA,EAAsC,CAAA,CAAE,UAEe;AAAA,cAEvD,8BAAA,gCAA8B,wBAAA,iDAAA,mBAAA,yCAAA,UAAA,4CAAA,UAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/actions/add-members-group-channel.d.ts
|
|
4
|
+
declare const SendbirdAddMembersGroupChannelInput: z.ZodTypeAny;
|
|
5
|
+
declare const SendbirdAddMembersGroupChannelOutput: z.ZodTypeAny;
|
|
6
|
+
declare const sendbirdAddMembersGroupChannel: import("@keystrokehq/action").WorkflowActionDefinition<unknown, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { sendbirdAddMembersGroupChannel };
|
|
9
|
+
//# sourceMappingURL=add-members-group-channel.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-members-group-channel.d.mts","names":[],"sources":["../../src/actions/add-members-group-channel.ts"],"mappings":";;;cAIa,mCAAA,EAAqC,CAAA,CAAE,UAKe;AAAA,cAetD,oCAAA,EAAsC,CAAA,CAAE,UAEe;AAAA,cAEvD,8BAAA,gCAA8B,wBAAA,iDAAA,mBAAA,yCAAA,UAAA,4CAAA,UAAA"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { action } from "../action.mjs";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
//#region src/actions/add-members-group-channel.ts
|
|
4
|
+
const SendbirdAddMembersGroupChannelInput = z.object({
|
|
5
|
+
seconds: z.number().int().describe("Duration in seconds to hide previous messages. Required if hide_existing_messages is true.").optional(),
|
|
6
|
+
user_ids: z.array(z.string()).describe("List of User IDs to add to the channel."),
|
|
7
|
+
channel_url: z.string().describe("URL-encoded identifier of the target group channel."),
|
|
8
|
+
hide_existing_messages: z.boolean().describe("Whether to hide previous messages for new members.").optional()
|
|
9
|
+
}).describe("Request model for adding members to a group channel.");
|
|
10
|
+
const SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema = z.object({
|
|
11
|
+
user_id: z.string().describe("User ID of the member."),
|
|
12
|
+
nickname: z.string().describe("Nickname of the member.").nullable().optional(),
|
|
13
|
+
is_active: z.boolean().describe("Whether the user is active (online status).").nullable().optional(),
|
|
14
|
+
friend_name: z.string().describe("Friend name if available.").nullable().optional(),
|
|
15
|
+
profile_url: z.string().describe("Profile URL of the member.").nullable().optional(),
|
|
16
|
+
last_seen_at: z.number().int().describe("Timestamp (ms) when the user was last seen.").nullable().optional(),
|
|
17
|
+
member_state: z.string().describe("State of the member in channel (joined, invited, etc.).").nullable().optional(),
|
|
18
|
+
connection_id: z.number().int().describe("Connection identifier if connected.").nullable().optional(),
|
|
19
|
+
hide_start_ts: z.number().int().describe("Timestamp (ms) when hiding messages started for the user.").nullable().optional(),
|
|
20
|
+
registered_at: z.number().int().describe("Timestamp (ms) when the user registered.").nullable().optional(),
|
|
21
|
+
preferred_languages: z.array(z.string()).describe("Preferred language codes of the member.").nullable().optional(),
|
|
22
|
+
require_auth_for_profile_image: z.boolean().describe("Whether the member requires auth for profile image access.").nullable().optional()
|
|
23
|
+
}).describe("Member object returned after adding to group channel.");
|
|
24
|
+
const sendbirdAddMembersGroupChannel = action("SENDBIRD_ADD_MEMBERS_GROUP_CHANNEL", {
|
|
25
|
+
slug: "sendbird-add-members-group-channel",
|
|
26
|
+
name: "Add Members To Group Channel",
|
|
27
|
+
description: "Tool to add members to a group channel. Use when you need to invite one or more users into an existing group channel.",
|
|
28
|
+
input: SendbirdAddMembersGroupChannelInput,
|
|
29
|
+
output: z.object({ members: z.array(SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema).describe("List of members successfully added to the channel.") }).describe("Response model for adding members to a group channel.")
|
|
30
|
+
});
|
|
31
|
+
//#endregion
|
|
32
|
+
export { sendbirdAddMembersGroupChannel };
|
|
33
|
+
|
|
34
|
+
//# sourceMappingURL=add-members-group-channel.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"add-members-group-channel.mjs","names":[],"sources":["../../src/actions/add-members-group-channel.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const SendbirdAddMembersGroupChannelInput: z.ZodTypeAny = z.object({\n seconds: z.number().int().describe(\"Duration in seconds to hide previous messages. Required if hide_existing_messages is true.\").optional(),\n user_ids: z.array(z.string()).describe(\"List of User IDs to add to the channel.\"),\n channel_url: z.string().describe(\"URL-encoded identifier of the target group channel.\"),\n hide_existing_messages: z.boolean().describe(\"Whether to hide previous messages for new members.\").optional(),\n}).describe(\"Request model for adding members to a group channel.\");\nconst SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema: z.ZodTypeAny = z.object({\n user_id: z.string().describe(\"User ID of the member.\"),\n nickname: z.string().describe(\"Nickname of the member.\").nullable().optional(),\n is_active: z.boolean().describe(\"Whether the user is active (online status).\").nullable().optional(),\n friend_name: z.string().describe(\"Friend name if available.\").nullable().optional(),\n profile_url: z.string().describe(\"Profile URL of the member.\").nullable().optional(),\n last_seen_at: z.number().int().describe(\"Timestamp (ms) when the user was last seen.\").nullable().optional(),\n member_state: z.string().describe(\"State of the member in channel (joined, invited, etc.).\").nullable().optional(),\n connection_id: z.number().int().describe(\"Connection identifier if connected.\").nullable().optional(),\n hide_start_ts: z.number().int().describe(\"Timestamp (ms) when hiding messages started for the user.\").nullable().optional(),\n registered_at: z.number().int().describe(\"Timestamp (ms) when the user registered.\").nullable().optional(),\n preferred_languages: z.array(z.string()).describe(\"Preferred language codes of the member.\").nullable().optional(),\n require_auth_for_profile_image: z.boolean().describe(\"Whether the member requires auth for profile image access.\").nullable().optional(),\n}).describe(\"Member object returned after adding to group channel.\");\nexport const SendbirdAddMembersGroupChannelOutput: z.ZodTypeAny = z.object({\n members: z.array(SendbirdAddMembersGroupChannel_AddMembersGroupChannelMemberSchema).describe(\"List of members successfully added to the channel.\"),\n}).describe(\"Response model for adding members to a group channel.\");\n\nexport const sendbirdAddMembersGroupChannel = action(\"SENDBIRD_ADD_MEMBERS_GROUP_CHANNEL\", {\n slug: \"sendbird-add-members-group-channel\",\n name: \"Add Members To Group Channel\",\n description: \"Tool to add members to a group channel. Use when you need to invite one or more users into an existing group channel.\",\n input: SendbirdAddMembersGroupChannelInput,\n output: SendbirdAddMembersGroupChannelOutput,\n});\n"],"mappings":";;;AAIA,MAAa,sCAAoD,EAAE,OAAO;CACxE,SAAS,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,4FAA4F,CAAC,CAAC,SAAS;CAC1I,UAAU,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,SAAS,yCAAyC;CAChF,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,qDAAqD;CACtF,wBAAwB,EAAE,QAAQ,CAAC,CAAC,SAAS,oDAAoD,CAAC,CAAC,SAAS;AAC9G,CAAC,CAAC,CAAC,SAAS,sDAAsD;AAClE,MAAM,oEAAkF,EAAE,OAAO;CAC/F,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,wBAAwB;CACrD,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,yBAAyB,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC7E,WAAW,EAAE,QAAQ,CAAC,CAAC,SAAS,6CAA6C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACnG,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,2BAA2B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAClF,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,4BAA4B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACnF,cAAc,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,6CAA6C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC3G,cAAc,EAAE,OAAO,CAAC,CAAC,SAAS,yDAAyD,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACjH,eAAe,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,qCAAqC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACpG,eAAe,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,2DAA2D,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC1H,eAAe,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,0CAA0C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACzG,qBAAqB,EAAE,MAAM,EAAE,OAAO,CAAC,CAAC,CAAC,SAAS,yCAAyC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACjH,gCAAgC,EAAE,QAAQ,CAAC,CAAC,SAAS,4DAA4D,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AACzI,CAAC,CAAC,CAAC,SAAS,uDAAuD;AAKnE,MAAa,iCAAiC,OAAO,sCAAsC;CACzF,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QATgE,EAAE,OAAO,EACzE,SAAS,EAAE,MAAM,iEAAiE,CAAC,CAAC,SAAS,oDAAoD,EACnJ,CAAC,CAAC,CAAC,SAAS,uDAOF;AACV,CAAC"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
const require_action = require("../action.cjs");
|
|
2
|
+
let zod = require("zod");
|
|
3
|
+
//#region src/actions/ban-user-from-group-channel.ts
|
|
4
|
+
const SendbirdBanUserFromGroupChannelInput = zod.z.object({
|
|
5
|
+
seconds: zod.z.number().int().describe("Duration of the ban in seconds. If omitted, ban is permanent.").optional(),
|
|
6
|
+
user_id: zod.z.string().describe("ID of the user to ban from the channel."),
|
|
7
|
+
agent_id: zod.z.string().describe("ID of the admin or moderator performing the ban.").optional(),
|
|
8
|
+
channel_url: zod.z.string().describe("URL-encoded identifier of the group channel to ban the user from."),
|
|
9
|
+
description: zod.z.string().describe("Reason for the ban in moderation records.").optional()
|
|
10
|
+
}).describe("Request model for banning a user from a group channel.");
|
|
11
|
+
const SendbirdBanUserFromGroupChannel_BannedUserInfoSchema = zod.z.object({
|
|
12
|
+
user_id: zod.z.string().describe("ID of the banned user."),
|
|
13
|
+
nickname: zod.z.string().describe("Nickname of the banned user.").nullable().optional(),
|
|
14
|
+
profile_url: zod.z.string().describe("Profile image URL of the banned user.").nullable().optional()
|
|
15
|
+
}).describe("Information about the banned user.");
|
|
16
|
+
const SendbirdBanUserFromGroupChannelOutput = zod.z.object({
|
|
17
|
+
user: SendbirdBanUserFromGroupChannel_BannedUserInfoSchema.nullable(),
|
|
18
|
+
end_at: zod.z.number().int().describe("Unix epoch timestamp when ban ends.").nullable().optional(),
|
|
19
|
+
seconds: zod.z.number().int().describe("Duration of the ban in seconds.").nullable().optional(),
|
|
20
|
+
created_at: zod.z.number().int().describe("Unix epoch timestamp when ban was created.").nullable().optional(),
|
|
21
|
+
description: zod.z.string().describe("Reason for the ban.").nullable().optional()
|
|
22
|
+
}).describe("Response model for a banned user record.");
|
|
23
|
+
const sendbirdBanUserFromGroupChannel = require_action.action("SENDBIRD_BAN_USER_FROM_GROUP_CHANNEL", {
|
|
24
|
+
slug: "sendbird-ban-user-from-group-channel",
|
|
25
|
+
name: "Ban User from Group Channel",
|
|
26
|
+
description: "Tool to ban a user from a group channel. Use when moderating group channels to restrict member access. Execute after confirming channel_url and user_id.",
|
|
27
|
+
input: SendbirdBanUserFromGroupChannelInput,
|
|
28
|
+
output: SendbirdBanUserFromGroupChannelOutput
|
|
29
|
+
});
|
|
30
|
+
//#endregion
|
|
31
|
+
exports.sendbirdBanUserFromGroupChannel = sendbirdBanUserFromGroupChannel;
|
|
32
|
+
|
|
33
|
+
//# sourceMappingURL=ban-user-from-group-channel.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ban-user-from-group-channel.cjs","names":["z","action"],"sources":["../../src/actions/ban-user-from-group-channel.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const SendbirdBanUserFromGroupChannelInput: z.ZodTypeAny = z.object({\n seconds: z.number().int().describe(\"Duration of the ban in seconds. If omitted, ban is permanent.\").optional(),\n user_id: z.string().describe(\"ID of the user to ban from the channel.\"),\n agent_id: z.string().describe(\"ID of the admin or moderator performing the ban.\").optional(),\n channel_url: z.string().describe(\"URL-encoded identifier of the group channel to ban the user from.\"),\n description: z.string().describe(\"Reason for the ban in moderation records.\").optional(),\n}).describe(\"Request model for banning a user from a group channel.\");\nconst SendbirdBanUserFromGroupChannel_BannedUserInfoSchema: z.ZodTypeAny = z.object({\n user_id: z.string().describe(\"ID of the banned user.\"),\n nickname: z.string().describe(\"Nickname of the banned user.\").nullable().optional(),\n profile_url: z.string().describe(\"Profile image URL of the banned user.\").nullable().optional(),\n}).describe(\"Information about the banned user.\");\nexport const SendbirdBanUserFromGroupChannelOutput: z.ZodTypeAny = z.object({\n user: SendbirdBanUserFromGroupChannel_BannedUserInfoSchema.nullable(),\n end_at: z.number().int().describe(\"Unix epoch timestamp when ban ends.\").nullable().optional(),\n seconds: z.number().int().describe(\"Duration of the ban in seconds.\").nullable().optional(),\n created_at: z.number().int().describe(\"Unix epoch timestamp when ban was created.\").nullable().optional(),\n description: z.string().describe(\"Reason for the ban.\").nullable().optional(),\n}).describe(\"Response model for a banned user record.\");\n\nexport const sendbirdBanUserFromGroupChannel = action(\"SENDBIRD_BAN_USER_FROM_GROUP_CHANNEL\", {\n slug: \"sendbird-ban-user-from-group-channel\",\n name: \"Ban User from Group Channel\",\n description: \"Tool to ban a user from a group channel. Use when moderating group channels to restrict member access. Execute after confirming channel_url and user_id.\",\n input: SendbirdBanUserFromGroupChannelInput,\n output: SendbirdBanUserFromGroupChannelOutput,\n});\n"],"mappings":";;;AAIA,MAAa,uCAAqDA,IAAAA,EAAE,OAAO;CACzE,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,+DAA+D,CAAC,CAAC,SAAS;CAC7G,SAASA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,yCAAyC;CACtE,UA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
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/actions/ban-user-from-group-channel.d.ts
|
|
4
|
+
declare const SendbirdBanUserFromGroupChannelInput: z.ZodTypeAny;
|
|
5
|
+
declare const SendbirdBanUserFromGroupChannelOutput: z.ZodTypeAny;
|
|
6
|
+
declare const sendbirdBanUserFromGroupChannel: import("@keystrokehq/action").WorkflowActionDefinition<unknown, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { sendbirdBanUserFromGroupChannel };
|
|
9
|
+
//# sourceMappingURL=ban-user-from-group-channel.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ban-user-from-group-channel.d.cts","names":[],"sources":["../../src/actions/ban-user-from-group-channel.ts"],"mappings":";;;cAIa,oCAAA,EAAsC,CAAA,CAAE,UAMgB;AAAA,cAMxD,qCAAA,EAAuC,CAAA,CAAE,UAMC;AAAA,cAE1C,+BAAA,gCAA+B,wBAAA,iDAAA,mBAAA,yCAAA,UAAA,4CAAA,UAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/actions/ban-user-from-group-channel.d.ts
|
|
4
|
+
declare const SendbirdBanUserFromGroupChannelInput: z.ZodTypeAny;
|
|
5
|
+
declare const SendbirdBanUserFromGroupChannelOutput: z.ZodTypeAny;
|
|
6
|
+
declare const sendbirdBanUserFromGroupChannel: import("@keystrokehq/action").WorkflowActionDefinition<unknown, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { sendbirdBanUserFromGroupChannel };
|
|
9
|
+
//# sourceMappingURL=ban-user-from-group-channel.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ban-user-from-group-channel.d.mts","names":[],"sources":["../../src/actions/ban-user-from-group-channel.ts"],"mappings":";;;cAIa,oCAAA,EAAsC,CAAA,CAAE,UAMgB;AAAA,cAMxD,qCAAA,EAAuC,CAAA,CAAE,UAMC;AAAA,cAE1C,+BAAA,gCAA+B,wBAAA,iDAAA,mBAAA,yCAAA,UAAA,4CAAA,UAAA"}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import { action } from "../action.mjs";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
//#region src/actions/ban-user-from-group-channel.ts
|
|
4
|
+
const SendbirdBanUserFromGroupChannelInput = z.object({
|
|
5
|
+
seconds: z.number().int().describe("Duration of the ban in seconds. If omitted, ban is permanent.").optional(),
|
|
6
|
+
user_id: z.string().describe("ID of the user to ban from the channel."),
|
|
7
|
+
agent_id: z.string().describe("ID of the admin or moderator performing the ban.").optional(),
|
|
8
|
+
channel_url: z.string().describe("URL-encoded identifier of the group channel to ban the user from."),
|
|
9
|
+
description: z.string().describe("Reason for the ban in moderation records.").optional()
|
|
10
|
+
}).describe("Request model for banning a user from a group channel.");
|
|
11
|
+
const SendbirdBanUserFromGroupChannel_BannedUserInfoSchema = z.object({
|
|
12
|
+
user_id: z.string().describe("ID of the banned user."),
|
|
13
|
+
nickname: z.string().describe("Nickname of the banned user.").nullable().optional(),
|
|
14
|
+
profile_url: z.string().describe("Profile image URL of the banned user.").nullable().optional()
|
|
15
|
+
}).describe("Information about the banned user.");
|
|
16
|
+
const sendbirdBanUserFromGroupChannel = action("SENDBIRD_BAN_USER_FROM_GROUP_CHANNEL", {
|
|
17
|
+
slug: "sendbird-ban-user-from-group-channel",
|
|
18
|
+
name: "Ban User from Group Channel",
|
|
19
|
+
description: "Tool to ban a user from a group channel. Use when moderating group channels to restrict member access. Execute after confirming channel_url and user_id.",
|
|
20
|
+
input: SendbirdBanUserFromGroupChannelInput,
|
|
21
|
+
output: z.object({
|
|
22
|
+
user: SendbirdBanUserFromGroupChannel_BannedUserInfoSchema.nullable(),
|
|
23
|
+
end_at: z.number().int().describe("Unix epoch timestamp when ban ends.").nullable().optional(),
|
|
24
|
+
seconds: z.number().int().describe("Duration of the ban in seconds.").nullable().optional(),
|
|
25
|
+
created_at: z.number().int().describe("Unix epoch timestamp when ban was created.").nullable().optional(),
|
|
26
|
+
description: z.string().describe("Reason for the ban.").nullable().optional()
|
|
27
|
+
}).describe("Response model for a banned user record.")
|
|
28
|
+
});
|
|
29
|
+
//#endregion
|
|
30
|
+
export { sendbirdBanUserFromGroupChannel };
|
|
31
|
+
|
|
32
|
+
//# sourceMappingURL=ban-user-from-group-channel.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ban-user-from-group-channel.mjs","names":[],"sources":["../../src/actions/ban-user-from-group-channel.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const SendbirdBanUserFromGroupChannelInput: z.ZodTypeAny = z.object({\n seconds: z.number().int().describe(\"Duration of the ban in seconds. If omitted, ban is permanent.\").optional(),\n user_id: z.string().describe(\"ID of the user to ban from the channel.\"),\n agent_id: z.string().describe(\"ID of the admin or moderator performing the ban.\").optional(),\n channel_url: z.string().describe(\"URL-encoded identifier of the group channel to ban the user from.\"),\n description: z.string().describe(\"Reason for the ban in moderation records.\").optional(),\n}).describe(\"Request model for banning a user from a group channel.\");\nconst SendbirdBanUserFromGroupChannel_BannedUserInfoSchema: z.ZodTypeAny = z.object({\n user_id: z.string().describe(\"ID of the banned user.\"),\n nickname: z.string().describe(\"Nickname of the banned user.\").nullable().optional(),\n profile_url: z.string().describe(\"Profile image URL of the banned user.\").nullable().optional(),\n}).describe(\"Information about the banned user.\");\nexport const SendbirdBanUserFromGroupChannelOutput: z.ZodTypeAny = z.object({\n user: SendbirdBanUserFromGroupChannel_BannedUserInfoSchema.nullable(),\n end_at: z.number().int().describe(\"Unix epoch timestamp when ban ends.\").nullable().optional(),\n seconds: z.number().int().describe(\"Duration of the ban in seconds.\").nullable().optional(),\n created_at: z.number().int().describe(\"Unix epoch timestamp when ban was created.\").nullable().optional(),\n description: z.string().describe(\"Reason for the ban.\").nullable().optional(),\n}).describe(\"Response model for a banned user record.\");\n\nexport const sendbirdBanUserFromGroupChannel = action(\"SENDBIRD_BAN_USER_FROM_GROUP_CHANNEL\", {\n slug: \"sendbird-ban-user-from-group-channel\",\n name: \"Ban User from Group Channel\",\n description: \"Tool to ban a user from a group channel. Use when moderating group channels to restrict member access. Execute after confirming channel_url and user_id.\",\n input: SendbirdBanUserFromGroupChannelInput,\n output: SendbirdBanUserFromGroupChannelOutput,\n});\n"],"mappings":";;;AAIA,MAAa,uCAAqD,EAAE,OAAO;CACzE,SAAS,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,+DAA+D,CAAC,CAAC,SAAS;CAC7G,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,yCAAyC;CACtE,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,kDAAkD,CAAC,CAAC,SAAS;CAC3F,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,mEAAmE;CACpG,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,2CAA2C,CAAC,CAAC,SAAS;AACzF,CAAC,CAAC,CAAC,SAAS,wDAAwD;AACpE,MAAM,uDAAqE,EAAE,OAAO;CAClF,SAAS,EAAE,OAAO,CAAC,CAAC,SAAS,wBAAwB;CACrD,UAAU,EAAE,OAAO,CAAC,CAAC,SAAS,8BAA8B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAClF,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,uCAAuC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;AAChG,CAAC,CAAC,CAAC,SAAS,oCAAoC;AAShD,MAAa,kCAAkC,OAAO,wCAAwC;CAC5F,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAbiE,EAAE,OAAO;EAC1E,MAAM,qDAAqD,SAAS;EACpE,QAAQ,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,qCAAqC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;EAC7F,SAAS,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,iCAAiC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;EAC1F,YAAY,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,4CAA4C,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;EACxG,aAAa,EAAE,OAAO,CAAC,CAAC,SAAS,qBAAqB,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC9E,CAAC,CAAC,CAAC,SAAS,0CAOF;AACV,CAAC"}
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
const require_action = require("../action.cjs");
|
|
2
|
+
let zod = require("zod");
|
|
3
|
+
//#region src/actions/create-channel.ts
|
|
4
|
+
const SendbirdCreateChannelInput = zod.z.object({
|
|
5
|
+
data: zod.z.string().describe("Custom data for the channel").optional(),
|
|
6
|
+
name: zod.z.string().describe("Name of the channel").optional(),
|
|
7
|
+
strict: zod.z.boolean().describe("True for strict creation; fails if channel exists").optional(),
|
|
8
|
+
is_super: zod.z.boolean().describe("True to create a supergroup channel").optional(),
|
|
9
|
+
user_ids: zod.z.array(zod.z.string()).describe("List of user IDs to invite to the channel (max 100)").optional(),
|
|
10
|
+
cover_url: zod.z.string().describe("URL of the channel cover image").optional(),
|
|
11
|
+
is_public: zod.z.boolean().describe("True to create a public channel").optional(),
|
|
12
|
+
cover_file: zod.z.string().describe("Binary content of the cover image for multipart upload").optional(),
|
|
13
|
+
access_code: zod.z.string().describe("Access code for private channels").optional(),
|
|
14
|
+
channel_url: zod.z.string().describe("Custom URL of the channel; autogenerated if omitted").optional(),
|
|
15
|
+
custom_type: zod.z.string().describe("Custom type identifier for the channel").optional(),
|
|
16
|
+
is_distinct: zod.z.boolean().describe("True to create a distinct channel").optional(),
|
|
17
|
+
is_ephemeral: zod.z.boolean().describe("True to create an ephemeral channel").optional(),
|
|
18
|
+
operator_ids: zod.z.array(zod.z.string()).describe("List of user IDs to assign as operators").optional(),
|
|
19
|
+
custom_fields: zod.z.record(zod.z.string(), zod.z.unknown()).describe("Custom fields object").optional(),
|
|
20
|
+
is_discoverable: zod.z.boolean().describe("True to list the channel in search results").optional(),
|
|
21
|
+
is_chat_notification: zod.z.boolean().describe("True to send system notifications for channel events").optional(),
|
|
22
|
+
message_survival_seconds: zod.z.number().int().describe("Message retention period in seconds").optional()
|
|
23
|
+
}).describe("Request model for creating a new Sendbird group channel.");
|
|
24
|
+
const SendbirdCreateChannel_MemberSchema = zod.z.object({
|
|
25
|
+
state: zod.z.string().describe("Member state (joined, invited, etc.)").nullable().optional(),
|
|
26
|
+
has_pin: zod.z.boolean().describe("Whether member has pinned the channel").nullable().optional(),
|
|
27
|
+
user_id: zod.z.string().describe("Member user ID"),
|
|
28
|
+
nickname: zod.z.string().describe("Member nickname").nullable().optional(),
|
|
29
|
+
profile_url: zod.z.string().describe("Member profile image URL").nullable().optional(),
|
|
30
|
+
last_seen_at: zod.z.number().int().describe("Timestamp when member was last active (ms)").nullable().optional(),
|
|
31
|
+
connection_id: zod.z.number().int().describe("Member connection ID").nullable().optional(),
|
|
32
|
+
pin_timestamp: zod.z.number().int().describe("Timestamp when channel was pinned (ms)").nullable().optional()
|
|
33
|
+
});
|
|
34
|
+
const SendbirdCreateChannel_LastMessageSchema = zod.z.object({
|
|
35
|
+
data: zod.z.string().describe("Data payload of the last message").nullable().optional(),
|
|
36
|
+
message: zod.z.string().describe("Content of the last message if text-based").nullable().optional(),
|
|
37
|
+
created_at: zod.z.number().int().describe("Timestamp when the last message was created (ms)"),
|
|
38
|
+
message_id: zod.z.string().describe("ID of the last message"),
|
|
39
|
+
updated_at: zod.z.number().int().describe("Timestamp when the last message was last updated (ms)"),
|
|
40
|
+
custom_type: zod.z.string().describe("Custom type of the last message").nullable().optional(),
|
|
41
|
+
message_type: zod.z.string().describe("Type of the last message (MESG, FILE, ADMM)")
|
|
42
|
+
});
|
|
43
|
+
const SendbirdCreateChannelOutput = zod.z.object({
|
|
44
|
+
data: zod.z.string().describe("Custom data of the channel").nullable().optional(),
|
|
45
|
+
name: zod.z.string().describe("Name of the channel").nullable().optional(),
|
|
46
|
+
freeze: zod.z.boolean().describe("Whether the channel is frozen"),
|
|
47
|
+
members: zod.z.array(SendbirdCreateChannel_MemberSchema).describe("List of channel members"),
|
|
48
|
+
is_super: zod.z.boolean().describe("Whether the channel is a supergroup channel"),
|
|
49
|
+
metadata: zod.z.object({}).describe("Channel metadata key-value pairs").nullable().optional(),
|
|
50
|
+
cover_url: zod.z.string().describe("Cover image URL of the channel").nullable().optional(),
|
|
51
|
+
is_public: zod.z.boolean().describe("Whether the channel is public"),
|
|
52
|
+
operators: zod.z.array(SendbirdCreateChannel_MemberSchema).describe("List of channel operators"),
|
|
53
|
+
created_at: zod.z.number().int().describe("Timestamp when the channel was created (ms)"),
|
|
54
|
+
channel_url: zod.z.string().describe("Unique URL of the group channel"),
|
|
55
|
+
custom_type: zod.z.string().describe("Custom type identifier of the channel").nullable().optional(),
|
|
56
|
+
is_distinct: zod.z.boolean().describe("Whether the channel is distinct"),
|
|
57
|
+
is_broadcast: zod.z.boolean().describe("Whether the channel is broadcast type"),
|
|
58
|
+
is_ephemeral: zod.z.boolean().describe("Whether the channel is ephemeral"),
|
|
59
|
+
last_message: SendbirdCreateChannel_LastMessageSchema.nullable().optional(),
|
|
60
|
+
member_count: zod.z.number().int().describe("Number of members in the channel"),
|
|
61
|
+
read_receipt: zod.z.object({}).describe("Read receipt per user mapping").nullable().optional(),
|
|
62
|
+
is_discoverable: zod.z.boolean().describe("Whether the channel is discoverable in search"),
|
|
63
|
+
delivery_receipt: zod.z.object({}).describe("Delivery receipt per user mapping").nullable().optional(),
|
|
64
|
+
joined_member_count: zod.z.number().int().describe("Number of joined members in the channel"),
|
|
65
|
+
unread_message_count: zod.z.number().int().describe("Count of unread messages for the user")
|
|
66
|
+
}).describe("Response model for creating a Sendbird group channel.");
|
|
67
|
+
const sendbirdCreateChannel = require_action.action("SENDBIRD_CREATE_CHANNEL", {
|
|
68
|
+
slug: "sendbird-create-channel",
|
|
69
|
+
name: "Create Group Channel",
|
|
70
|
+
description: "Tool to create a new group channel. Use when you need to start a conversation with specific users. Execute after specifying users and optional settings.",
|
|
71
|
+
input: SendbirdCreateChannelInput,
|
|
72
|
+
output: SendbirdCreateChannelOutput
|
|
73
|
+
});
|
|
74
|
+
//#endregion
|
|
75
|
+
exports.sendbirdCreateChannel = sendbirdCreateChannel;
|
|
76
|
+
|
|
77
|
+
//# sourceMappingURL=create-channel.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-channel.cjs","names":["z","action"],"sources":["../../src/actions/create-channel.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const SendbirdCreateChannelInput: z.ZodTypeAny = z.object({\n data: z.string().describe(\"Custom data for the channel\").optional(),\n name: z.string().describe(\"Name of the channel\").optional(),\n strict: z.boolean().describe(\"True for strict creation; fails if channel exists\").optional(),\n is_super: z.boolean().describe(\"True to create a supergroup channel\").optional(),\n user_ids: z.array(z.string()).describe(\"List of user IDs to invite to the channel (max 100)\").optional(),\n cover_url: z.string().describe(\"URL of the channel cover image\").optional(),\n is_public: z.boolean().describe(\"True to create a public channel\").optional(),\n cover_file: z.string().describe(\"Binary content of the cover image for multipart upload\").optional(),\n access_code: z.string().describe(\"Access code for private channels\").optional(),\n channel_url: z.string().describe(\"Custom URL of the channel; autogenerated if omitted\").optional(),\n custom_type: z.string().describe(\"Custom type identifier for the channel\").optional(),\n is_distinct: z.boolean().describe(\"True to create a distinct channel\").optional(),\n is_ephemeral: z.boolean().describe(\"True to create an ephemeral channel\").optional(),\n operator_ids: z.array(z.string()).describe(\"List of user IDs to assign as operators\").optional(),\n custom_fields: z.record(z.string(), z.unknown()).describe(\"Custom fields object\").optional(),\n is_discoverable: z.boolean().describe(\"True to list the channel in search results\").optional(),\n is_chat_notification: z.boolean().describe(\"True to send system notifications for channel events\").optional(),\n message_survival_seconds: z.number().int().describe(\"Message retention period in seconds\").optional(),\n}).describe(\"Request model for creating a new Sendbird group channel.\");\nconst SendbirdCreateChannel_MemberSchema: z.ZodTypeAny = z.object({\n state: z.string().describe(\"Member state (joined, invited, etc.)\").nullable().optional(),\n has_pin: z.boolean().describe(\"Whether member has pinned the channel\").nullable().optional(),\n user_id: z.string().describe(\"Member user ID\"),\n nickname: z.string().describe(\"Member nickname\").nullable().optional(),\n profile_url: z.string().describe(\"Member profile image URL\").nullable().optional(),\n last_seen_at: z.number().int().describe(\"Timestamp when member was last active (ms)\").nullable().optional(),\n connection_id: z.number().int().describe(\"Member connection ID\").nullable().optional(),\n pin_timestamp: z.number().int().describe(\"Timestamp when channel was pinned (ms)\").nullable().optional(),\n});\nconst SendbirdCreateChannel_LastMessageSchema: z.ZodTypeAny = z.object({\n data: z.string().describe(\"Data payload of the last message\").nullable().optional(),\n message: z.string().describe(\"Content of the last message if text-based\").nullable().optional(),\n created_at: z.number().int().describe(\"Timestamp when the last message was created (ms)\"),\n message_id: z.string().describe(\"ID of the last message\"),\n updated_at: z.number().int().describe(\"Timestamp when the last message was last updated (ms)\"),\n custom_type: z.string().describe(\"Custom type of the last message\").nullable().optional(),\n message_type: z.string().describe(\"Type of the last message (MESG, FILE, ADMM)\"),\n});\nexport const SendbirdCreateChannelOutput: z.ZodTypeAny = z.object({\n data: z.string().describe(\"Custom data of the channel\").nullable().optional(),\n name: z.string().describe(\"Name of the channel\").nullable().optional(),\n freeze: z.boolean().describe(\"Whether the channel is frozen\"),\n members: z.array(SendbirdCreateChannel_MemberSchema).describe(\"List of channel members\"),\n is_super: z.boolean().describe(\"Whether the channel is a supergroup channel\"),\n metadata: z.object({}).describe(\"Channel metadata key-value pairs\").nullable().optional(),\n cover_url: z.string().describe(\"Cover image URL of the channel\").nullable().optional(),\n is_public: z.boolean().describe(\"Whether the channel is public\"),\n operators: z.array(SendbirdCreateChannel_MemberSchema).describe(\"List of channel operators\"),\n created_at: z.number().int().describe(\"Timestamp when the channel was created (ms)\"),\n channel_url: z.string().describe(\"Unique URL of the group channel\"),\n custom_type: z.string().describe(\"Custom type identifier of the channel\").nullable().optional(),\n is_distinct: z.boolean().describe(\"Whether the channel is distinct\"),\n is_broadcast: z.boolean().describe(\"Whether the channel is broadcast type\"),\n is_ephemeral: z.boolean().describe(\"Whether the channel is ephemeral\"),\n last_message: SendbirdCreateChannel_LastMessageSchema.nullable().optional(),\n member_count: z.number().int().describe(\"Number of members in the channel\"),\n read_receipt: z.object({}).describe(\"Read receipt per user mapping\").nullable().optional(),\n is_discoverable: z.boolean().describe(\"Whether the channel is discoverable in search\"),\n delivery_receipt: z.object({}).describe(\"Delivery receipt per user mapping\").nullable().optional(),\n joined_member_count: z.number().int().describe(\"Number of joined members in the channel\"),\n unread_message_count: z.number().int().describe(\"Count of unread messages for the user\"),\n}).describe(\"Response model for creating a Sendbird group channel.\");\n\nexport const sendbirdCreateChannel = action(\"SENDBIRD_CREATE_CHANNEL\", {\n slug: \"sendbird-create-channel\",\n name: \"Create Group Channel\",\n description: \"Tool to create a new group channel. Use when you need to start a conversation with specific users. Execute after specifying users and optional settings.\",\n input: SendbirdCreateChannelInput,\n output: SendbirdCreateChannelOutput,\n});\n"],"mappings":";;;AAIA,MAAa,6BAA2CA,IAAAA,EAAE,OAAO;CAC/D,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,6BAA6B,CAAC,CAAC,SAAS;CAClE,MAAMA,IAAAA,EAAE,OAAO,CAAC,CAAC,SAAS,qBAAqB,CAAC,CAAC,SAAS;CAC1D,QAAQA,IAAAA,EAAE,QAAQ,CAAC,CAAC,SAAS,mDAAmD,CAAC,CAAC,SAAS;CAC3F,UAAUA,IAAAA,EAAE,QAAQ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AAuC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CAC9F,aAAaA,IAAAA,EAAE,QAAQ,CAAC,CAAC,SAAS,iCAAiC;CACnE,cAAcA,IAAAA,EAAE,QAAQ,CAAC,CAAC,SAAS,uCAAuC;CAC1E,cAAcA,IAAAA,EAAE,QAAQ,CAAC,CAAC,SAAS,kCAAkC;CACrE,cAAc,wCAAwC,SAAS,CAAC,CAAC,SAAS;CAC1E,cAAcA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,kCAAkC;CAC1E,cAAcA,IAAAA,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,+BAA+B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACzF,iBAAiBA,IAAAA,EAAE,QAAQ,CAAC,CAAC,SAAS,+CAA+C;CACrF,kBAAkBA,IAAAA,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,mCAAmC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;CACjG,qBAAqBA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,yCAAyC;CACxF,sBAAsBA,IAAAA,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,uCAAuC;AACzF,CAAC,CAAC,CAAC,SAAS,uDAAuD;AAEnE,MAAa,wBAAwBC,eAAAA,OAAO,2BAA2B;CACrE,MAAM;CACN,MAAM;CACN,aAAa;CACb,OAAO;CACP,QAAQ;AACV,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/actions/create-channel.d.ts
|
|
4
|
+
declare const SendbirdCreateChannelInput: z.ZodTypeAny;
|
|
5
|
+
declare const SendbirdCreateChannelOutput: z.ZodTypeAny;
|
|
6
|
+
declare const sendbirdCreateChannel: import("@keystrokehq/action").WorkflowActionDefinition<unknown, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { sendbirdCreateChannel };
|
|
9
|
+
//# sourceMappingURL=create-channel.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-channel.d.cts","names":[],"sources":["../../src/actions/create-channel.ts"],"mappings":";;;cAIa,0BAAA,EAA4B,CAAA,CAAE,UAmB4B;AAAA,cAoB1D,2BAAA,EAA6B,CAAA,CAAE,UAuBwB;AAAA,cAEvD,qBAAA,gCAAqB,wBAAA,iDAAA,mBAAA,yCAAA,UAAA,4CAAA,UAAA"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
|
|
3
|
+
//#region src/actions/create-channel.d.ts
|
|
4
|
+
declare const SendbirdCreateChannelInput: z.ZodTypeAny;
|
|
5
|
+
declare const SendbirdCreateChannelOutput: z.ZodTypeAny;
|
|
6
|
+
declare const sendbirdCreateChannel: import("@keystrokehq/action").WorkflowActionDefinition<unknown, unknown, import("@keystrokehq/shared").ResolvedCredentials<readonly [import("@keystrokehq/shared").Credential]>, readonly [import("@keystrokehq/shared").Credential]>;
|
|
7
|
+
//#endregion
|
|
8
|
+
export { sendbirdCreateChannel };
|
|
9
|
+
//# sourceMappingURL=create-channel.d.mts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-channel.d.mts","names":[],"sources":["../../src/actions/create-channel.ts"],"mappings":";;;cAIa,0BAAA,EAA4B,CAAA,CAAE,UAmB4B;AAAA,cAoB1D,2BAAA,EAA6B,CAAA,CAAE,UAuBwB;AAAA,cAEvD,qBAAA,gCAAqB,wBAAA,iDAAA,mBAAA,yCAAA,UAAA,4CAAA,UAAA"}
|
|
@@ -0,0 +1,76 @@
|
|
|
1
|
+
import { action } from "../action.mjs";
|
|
2
|
+
import { z } from "zod";
|
|
3
|
+
//#region src/actions/create-channel.ts
|
|
4
|
+
const SendbirdCreateChannelInput = z.object({
|
|
5
|
+
data: z.string().describe("Custom data for the channel").optional(),
|
|
6
|
+
name: z.string().describe("Name of the channel").optional(),
|
|
7
|
+
strict: z.boolean().describe("True for strict creation; fails if channel exists").optional(),
|
|
8
|
+
is_super: z.boolean().describe("True to create a supergroup channel").optional(),
|
|
9
|
+
user_ids: z.array(z.string()).describe("List of user IDs to invite to the channel (max 100)").optional(),
|
|
10
|
+
cover_url: z.string().describe("URL of the channel cover image").optional(),
|
|
11
|
+
is_public: z.boolean().describe("True to create a public channel").optional(),
|
|
12
|
+
cover_file: z.string().describe("Binary content of the cover image for multipart upload").optional(),
|
|
13
|
+
access_code: z.string().describe("Access code for private channels").optional(),
|
|
14
|
+
channel_url: z.string().describe("Custom URL of the channel; autogenerated if omitted").optional(),
|
|
15
|
+
custom_type: z.string().describe("Custom type identifier for the channel").optional(),
|
|
16
|
+
is_distinct: z.boolean().describe("True to create a distinct channel").optional(),
|
|
17
|
+
is_ephemeral: z.boolean().describe("True to create an ephemeral channel").optional(),
|
|
18
|
+
operator_ids: z.array(z.string()).describe("List of user IDs to assign as operators").optional(),
|
|
19
|
+
custom_fields: z.record(z.string(), z.unknown()).describe("Custom fields object").optional(),
|
|
20
|
+
is_discoverable: z.boolean().describe("True to list the channel in search results").optional(),
|
|
21
|
+
is_chat_notification: z.boolean().describe("True to send system notifications for channel events").optional(),
|
|
22
|
+
message_survival_seconds: z.number().int().describe("Message retention period in seconds").optional()
|
|
23
|
+
}).describe("Request model for creating a new Sendbird group channel.");
|
|
24
|
+
const SendbirdCreateChannel_MemberSchema = z.object({
|
|
25
|
+
state: z.string().describe("Member state (joined, invited, etc.)").nullable().optional(),
|
|
26
|
+
has_pin: z.boolean().describe("Whether member has pinned the channel").nullable().optional(),
|
|
27
|
+
user_id: z.string().describe("Member user ID"),
|
|
28
|
+
nickname: z.string().describe("Member nickname").nullable().optional(),
|
|
29
|
+
profile_url: z.string().describe("Member profile image URL").nullable().optional(),
|
|
30
|
+
last_seen_at: z.number().int().describe("Timestamp when member was last active (ms)").nullable().optional(),
|
|
31
|
+
connection_id: z.number().int().describe("Member connection ID").nullable().optional(),
|
|
32
|
+
pin_timestamp: z.number().int().describe("Timestamp when channel was pinned (ms)").nullable().optional()
|
|
33
|
+
});
|
|
34
|
+
const SendbirdCreateChannel_LastMessageSchema = z.object({
|
|
35
|
+
data: z.string().describe("Data payload of the last message").nullable().optional(),
|
|
36
|
+
message: z.string().describe("Content of the last message if text-based").nullable().optional(),
|
|
37
|
+
created_at: z.number().int().describe("Timestamp when the last message was created (ms)"),
|
|
38
|
+
message_id: z.string().describe("ID of the last message"),
|
|
39
|
+
updated_at: z.number().int().describe("Timestamp when the last message was last updated (ms)"),
|
|
40
|
+
custom_type: z.string().describe("Custom type of the last message").nullable().optional(),
|
|
41
|
+
message_type: z.string().describe("Type of the last message (MESG, FILE, ADMM)")
|
|
42
|
+
});
|
|
43
|
+
const sendbirdCreateChannel = action("SENDBIRD_CREATE_CHANNEL", {
|
|
44
|
+
slug: "sendbird-create-channel",
|
|
45
|
+
name: "Create Group Channel",
|
|
46
|
+
description: "Tool to create a new group channel. Use when you need to start a conversation with specific users. Execute after specifying users and optional settings.",
|
|
47
|
+
input: SendbirdCreateChannelInput,
|
|
48
|
+
output: z.object({
|
|
49
|
+
data: z.string().describe("Custom data of the channel").nullable().optional(),
|
|
50
|
+
name: z.string().describe("Name of the channel").nullable().optional(),
|
|
51
|
+
freeze: z.boolean().describe("Whether the channel is frozen"),
|
|
52
|
+
members: z.array(SendbirdCreateChannel_MemberSchema).describe("List of channel members"),
|
|
53
|
+
is_super: z.boolean().describe("Whether the channel is a supergroup channel"),
|
|
54
|
+
metadata: z.object({}).describe("Channel metadata key-value pairs").nullable().optional(),
|
|
55
|
+
cover_url: z.string().describe("Cover image URL of the channel").nullable().optional(),
|
|
56
|
+
is_public: z.boolean().describe("Whether the channel is public"),
|
|
57
|
+
operators: z.array(SendbirdCreateChannel_MemberSchema).describe("List of channel operators"),
|
|
58
|
+
created_at: z.number().int().describe("Timestamp when the channel was created (ms)"),
|
|
59
|
+
channel_url: z.string().describe("Unique URL of the group channel"),
|
|
60
|
+
custom_type: z.string().describe("Custom type identifier of the channel").nullable().optional(),
|
|
61
|
+
is_distinct: z.boolean().describe("Whether the channel is distinct"),
|
|
62
|
+
is_broadcast: z.boolean().describe("Whether the channel is broadcast type"),
|
|
63
|
+
is_ephemeral: z.boolean().describe("Whether the channel is ephemeral"),
|
|
64
|
+
last_message: SendbirdCreateChannel_LastMessageSchema.nullable().optional(),
|
|
65
|
+
member_count: z.number().int().describe("Number of members in the channel"),
|
|
66
|
+
read_receipt: z.object({}).describe("Read receipt per user mapping").nullable().optional(),
|
|
67
|
+
is_discoverable: z.boolean().describe("Whether the channel is discoverable in search"),
|
|
68
|
+
delivery_receipt: z.object({}).describe("Delivery receipt per user mapping").nullable().optional(),
|
|
69
|
+
joined_member_count: z.number().int().describe("Number of joined members in the channel"),
|
|
70
|
+
unread_message_count: z.number().int().describe("Count of unread messages for the user")
|
|
71
|
+
}).describe("Response model for creating a Sendbird group channel.")
|
|
72
|
+
});
|
|
73
|
+
//#endregion
|
|
74
|
+
export { sendbirdCreateChannel };
|
|
75
|
+
|
|
76
|
+
//# sourceMappingURL=create-channel.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"create-channel.mjs","names":[],"sources":["../../src/actions/create-channel.ts"],"sourcesContent":["import { z } from \"zod\";\n\nimport { action } from \"../action\";\n\nexport const SendbirdCreateChannelInput: z.ZodTypeAny = z.object({\n data: z.string().describe(\"Custom data for the channel\").optional(),\n name: z.string().describe(\"Name of the channel\").optional(),\n strict: z.boolean().describe(\"True for strict creation; fails if channel exists\").optional(),\n is_super: z.boolean().describe(\"True to create a supergroup channel\").optional(),\n user_ids: z.array(z.string()).describe(\"List of user IDs to invite to the channel (max 100)\").optional(),\n cover_url: z.string().describe(\"URL of the channel cover image\").optional(),\n is_public: z.boolean().describe(\"True to create a public channel\").optional(),\n cover_file: z.string().describe(\"Binary content of the cover image for multipart upload\").optional(),\n access_code: z.string().describe(\"Access code for private channels\").optional(),\n channel_url: z.string().describe(\"Custom URL of the channel; autogenerated if omitted\").optional(),\n custom_type: z.string().describe(\"Custom type identifier for the channel\").optional(),\n is_distinct: z.boolean().describe(\"True to create a distinct channel\").optional(),\n is_ephemeral: z.boolean().describe(\"True to create an ephemeral channel\").optional(),\n operator_ids: z.array(z.string()).describe(\"List of user IDs to assign as operators\").optional(),\n custom_fields: z.record(z.string(), z.unknown()).describe(\"Custom fields object\").optional(),\n is_discoverable: z.boolean().describe(\"True to list the channel in search results\").optional(),\n is_chat_notification: z.boolean().describe(\"True to send system notifications for channel events\").optional(),\n message_survival_seconds: z.number().int().describe(\"Message retention period in seconds\").optional(),\n}).describe(\"Request model for creating a new Sendbird group channel.\");\nconst SendbirdCreateChannel_MemberSchema: z.ZodTypeAny = z.object({\n state: z.string().describe(\"Member state (joined, invited, etc.)\").nullable().optional(),\n has_pin: z.boolean().describe(\"Whether member has pinned the channel\").nullable().optional(),\n user_id: z.string().describe(\"Member user ID\"),\n nickname: z.string().describe(\"Member nickname\").nullable().optional(),\n profile_url: z.string().describe(\"Member profile image URL\").nullable().optional(),\n last_seen_at: z.number().int().describe(\"Timestamp when member was last active (ms)\").nullable().optional(),\n connection_id: z.number().int().describe(\"Member connection ID\").nullable().optional(),\n pin_timestamp: z.number().int().describe(\"Timestamp when channel was pinned (ms)\").nullable().optional(),\n});\nconst SendbirdCreateChannel_LastMessageSchema: z.ZodTypeAny = z.object({\n data: z.string().describe(\"Data payload of the last message\").nullable().optional(),\n message: z.string().describe(\"Content of the last message if text-based\").nullable().optional(),\n created_at: z.number().int().describe(\"Timestamp when the last message was created (ms)\"),\n message_id: z.string().describe(\"ID of the last message\"),\n updated_at: z.number().int().describe(\"Timestamp when the last message was last updated (ms)\"),\n custom_type: z.string().describe(\"Custom type of the last message\").nullable().optional(),\n message_type: z.string().describe(\"Type of the last message (MESG, FILE, ADMM)\"),\n});\nexport const SendbirdCreateChannelOutput: z.ZodTypeAny = z.object({\n data: z.string().describe(\"Custom data of the channel\").nullable().optional(),\n name: z.string().describe(\"Name of the channel\").nullable().optional(),\n freeze: z.boolean().describe(\"Whether the channel is frozen\"),\n members: z.array(SendbirdCreateChannel_MemberSchema).describe(\"List of channel members\"),\n is_super: z.boolean().describe(\"Whether the channel is a supergroup channel\"),\n metadata: z.object({}).describe(\"Channel metadata key-value pairs\").nullable().optional(),\n cover_url: z.string().describe(\"Cover image URL of the channel\").nullable().optional(),\n is_public: z.boolean().describe(\"Whether the channel is public\"),\n operators: z.array(SendbirdCreateChannel_MemberSchema).describe(\"List of channel operators\"),\n created_at: z.number().int().describe(\"Timestamp when the channel was created (ms)\"),\n channel_url: z.string().describe(\"Unique URL of the group channel\"),\n custom_type: z.string().describe(\"Custom type identifier of the channel\").nullable().optional(),\n is_distinct: z.boolean().describe(\"Whether the channel is distinct\"),\n is_broadcast: z.boolean().describe(\"Whether the channel is broadcast type\"),\n is_ephemeral: z.boolean().describe(\"Whether the channel is ephemeral\"),\n last_message: SendbirdCreateChannel_LastMessageSchema.nullable().optional(),\n member_count: z.number().int().describe(\"Number of members in the channel\"),\n read_receipt: z.object({}).describe(\"Read receipt per user mapping\").nullable().optional(),\n is_discoverable: z.boolean().describe(\"Whether the channel is discoverable in search\"),\n delivery_receipt: z.object({}).describe(\"Delivery receipt per user mapping\").nullable().optional(),\n joined_member_count: z.number().int().describe(\"Number of joined members in the channel\"),\n unread_message_count: z.number().int().describe(\"Count of unread messages for the user\"),\n}).describe(\"Response model for creating a Sendbird group channel.\");\n\nexport const sendbirdCreateChannel = action(\"SENDBIRD_CREATE_CHANNEL\", {\n slug: \"sendbird-create-channel\",\n name: \"Create Group Channel\",\n description: \"Tool to create a new group channel. Use when you need to start a conversation with specific users. Execute after specifying users and optional settings.\",\n input: SendbirdCreateChannelInput,\n output: SendbirdCreateChannelOutput,\n});\n"],"mappings":";;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EAAE,QAAQ,CAAC,CAAC,SAAS,iCAAiC;EACnE,cAAc,EAAE,QAAQ,CAAC,CAAC,SAAS,uCAAuC;EAC1E,cAAc,EAAE,QAAQ,CAAC,CAAC,SAAS,kCAAkC;EACrE,cAAc,wCAAwC,SAAS,CAAC,CAAC,SAAS;EAC1E,cAAc,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,kCAAkC;EAC1E,cAAc,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,+BAA+B,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;EACzF,iBAAiB,EAAE,QAAQ,CAAC,CAAC,SAAS,+CAA+C;EACrF,kBAAkB,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,SAAS,mCAAmC,CAAC,CAAC,SAAS,CAAC,CAAC,SAAS;EACjG,qBAAqB,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,yCAAyC;EACxF,sBAAsB,EAAE,OAAO,CAAC,CAAC,IAAI,CAAC,CAAC,SAAS,uCAAuC;CACzF,CAAC,CAAC,CAAC,SAAS,uDAOF;AACV,CAAC"}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
const require_action = require("../action.cjs");
|
|
2
|
+
let zod = require("zod");
|
|
3
|
+
//#region src/actions/create-user.ts
|
|
4
|
+
const SendbirdCreateUserInput = zod.z.object({
|
|
5
|
+
user_id: zod.z.string().describe("Unique identifier for the new user. Must be unique across the application. Can contain alphanumeric characters, underscores, and hyphens."),
|
|
6
|
+
metadata: zod.z.object({}).describe("Custom key-value pairs to store additional user data. Keys and values must be strings.").optional(),
|
|
7
|
+
nickname: zod.z.string().describe("Display name shown to other users in channels. If not provided, may default to user_id.").optional(),
|
|
8
|
+
is_active: zod.z.boolean().default(true).describe("If true, the user is active and can send/receive messages. Inactive users cannot participate in channels.").optional(),
|
|
9
|
+
profile_url: zod.z.string().describe("URL of the user's profile image. Must be a valid HTTP/HTTPS URL.").optional(),
|
|
10
|
+
phone_number: zod.z.string().describe("User's phone number in E.164 format (e.g., +15551234567). Used for user discovery if enabled.").optional(),
|
|
11
|
+
profile_file: zod.z.string().describe("Binary content of the user's profile image for multipart upload. Use this instead of profile_url when uploading an image file directly.").optional(),
|
|
12
|
+
discovery_keys: zod.z.array(zod.z.string()).describe("List of unique keys used to find this user through the discovery feature (e.g., email addresses, phone numbers).").optional(),
|
|
13
|
+
has_ever_logged_in: zod.z.boolean().default(false).describe("Internal flag indicating if the user has ever logged in. Typically managed by the system.").optional(),
|
|
14
|
+
issue_access_token: zod.z.boolean().default(false).describe("If true, generates and returns an access token for the user that can be used for client-side authentication.").optional(),
|
|
15
|
+
preferred_languages: zod.z.array(zod.z.string()).describe("List of ISO 639-1 language codes indicating user's preferred languages for push notifications.").optional()
|
|
16
|
+
}).describe("Request model for creating a new Sendbird user.");
|
|
17
|
+
const SendbirdCreateUserOutput = zod.z.object({
|
|
18
|
+
user_id: zod.z.string().describe("The unique identifier of the created user"),
|
|
19
|
+
metadata: zod.z.object({}).describe("Custom key-value pairs stored with the user").nullable().optional(),
|
|
20
|
+
nickname: zod.z.string().describe("The display name of the user").nullable().optional(),
|
|
21
|
+
is_active: zod.z.boolean().describe("Whether the user is currently active in the system"),
|
|
22
|
+
created_at: zod.z.number().int().describe("Unix timestamp (in milliseconds) when the user was created").nullable().optional(),
|
|
23
|
+
profile_url: zod.z.string().describe("URL of the user's profile image").nullable().optional(),
|
|
24
|
+
access_token: zod.z.string().describe("Access token for client-side authentication. Only returned if issue_access_token was set to true.").nullable().optional(),
|
|
25
|
+
last_seen_at: zod.z.number().int().describe("Unix timestamp (in milliseconds) of the user's last activity. May be 0 for newly created users.").nullable().optional(),
|
|
26
|
+
phone_number: zod.z.string().describe("User's phone number in E.164 format").nullable().optional(),
|
|
27
|
+
discovery_keys: zod.z.array(zod.z.string()).describe("List of discovery keys associated with the user").nullable().optional(),
|
|
28
|
+
has_ever_logged_in: zod.z.boolean().describe("Whether the user has ever logged in to the application").nullable().optional(),
|
|
29
|
+
preferred_languages: zod.z.array(zod.z.string()).describe("User's preferred language codes for push notifications").nullable().optional()
|
|
30
|
+
}).describe("Response model after successfully creating a new Sendbird user.");
|
|
31
|
+
const sendbirdCreateUser = require_action.action("SENDBIRD_CREATE_USER", {
|
|
32
|
+
slug: "sendbird-create-user",
|
|
33
|
+
name: "Create Sendbird User",
|
|
34
|
+
description: "Creates a new user in Sendbird. Use this to register user accounts before they can join channels or send messages. The user_id must be unique across the application.",
|
|
35
|
+
input: SendbirdCreateUserInput,
|
|
36
|
+
output: SendbirdCreateUserOutput
|
|
37
|
+
});
|
|
38
|
+
//#endregion
|
|
39
|
+
exports.sendbirdCreateUser = sendbirdCreateUser;
|
|
40
|
+
|
|
41
|
+
//# sourceMappingURL=create-user.cjs.map
|