import { removeObjectEmptyFields } from "https://deno.land/x/windmill_helpers@v1.0.1/mod.ts";
import { SlackAPI } from "https://deno.land/x/deno_slack_api@1.6.0/mod.ts";
/**
* @param cursor Paginate the list of users by setting the cursor parameter
* to a `next_cursor` attribute returned by a previous request's
* `response_metadata`. Default value fetches the first "page" of the users.
* Used in conjunction with `limit`.
*
* @param limit The maximum number of users to return. Fewer than the
* requested number of users may be returned, even if the end of the result
* list hasn't been reached.
* Used in conjunction with `cursor`.
*/
type Slack = {
token: string;
};
export async function main(auth: Slack, cursor?: string, limit?: number) {
const client = SlackAPI(auth.token);
const params = removeObjectEmptyFields({ cursor, limit });
return await client.users.list(params);
}
Submitted by admin 460 days ago
import { removeObjectEmptyFields } from "https://deno.land/x/windmill_helpers@v1.0.1/mod.ts";
import { SlackAPI } from "https://deno.land/x/deno_slack_api@1.6.0/mod.ts";
/**
* @param cursor Paginate the list of users by setting the cursor parameter
* to a `next_cursor` attribute returned by a previous request's
* `response_metadata`. Default value fetches the first "page" of the users.
* Used in conjunction with `limit`.
*
* @param limit The maximum number of users to return. Fewer than the
* requested number of users may be returned, even if the end of the result
* list hasn't been reached.
* Used in conjunction with `cursor`.
*/
type Slack = {
token: string;
};
export async function main(
auth: Slack,
cursor?: string,
limit?: number
) {
const client = SlackAPI(auth.token)
const params = removeObjectEmptyFields({ cursor, limit })
return await client.users.list(params)
}
Submitted by admin 463 days ago
import { Resource } from "https://deno.land/x/windmill@v1.85.0/mod.ts"
import { removeObjectEmptyFields } from "https://deno.land/x/windmill_helpers@v1.0.1/mod.ts";
import { SlackAPI } from "https://deno.land/x/deno_slack_api@1.6.0/mod.ts";
/**
* @param cursor Paginate the list of users by setting the cursor parameter
* to a `next_cursor` attribute returned by a previous request's
* `response_metadata`. Default value fetches the first "page" of the users.
* Used in conjunction with `limit`.
*
* @param limit The maximum number of users to return. Fewer than the
* requested number of users may be returned, even if the end of the result
* list hasn't been reached.
* Used in conjunction with `cursor`.
*/
export async function main(
auth: Resource<'slack'>,
cursor?: string,
limit?: number
) {
const client = SlackAPI(auth.token)
const params = removeObjectEmptyFields({ cursor, limit })
return await client.users.list(params)
}
Submitted by adam186 591 days ago
import { Resource } from "https://deno.land/x/windmill@v1.70.1/mod.ts"
import { removeObjectEmptyFields } from "https://deno.land/x/windmill_helpers@v1.0.1/mod.ts";
import { SlackAPI } from "https://deno.land/x/deno_slack_api@1.6.0/mod.ts";
/**
* @param cursor Paginate the list of users by setting the cursor parameter
* to a `next_cursor` attribute returned by a previous request's
* `response_metadata`. Default value fetches the first "page" of the users.
* Used in conjunction with `limit`.
*
* @param limit The maximum number of users to return. Fewer than the
* requested number of users may be returned, even if the end of the result
* list hasn't been reached.
* Used in conjunction with `cursor`.
*/
export async function main(
auth: Resource<'slack'>,
cursor?: string,
limit?: number
) {
const client = SlackAPI(auth.token)
const params = removeObjectEmptyFields({ cursor, limit })
return await client.users.list(params)
}
Submitted by adam186 626 days ago
import { Resource } from "https://deno.land/x/windmill@v1.62.0/mod.ts"
import { removeObjectEmptyFields } from "https://deno.land/x/windmill_helpers@v1.0.1/mod.ts";
import { SlackAPI } from "https://deno.land/x/deno_slack_api@1.6.0/mod.ts";
/**
* @param cursor Paginate the list of users by setting the cursor parameter
* to a `next_cursor` attribute returned by a previous request's
* `response_metadata`. Default value fetches the first "page" of the users.
* Used in conjunction with `limit`.
*
* @param limit The maximum number of users to return. Fewer than the
* requested number of users may be returned, even if the end of the result
* list hasn't been reached.
* Used in conjunction with `cursor`.
*/
export async function main(
auth: Resource<'slack'>,
cursor?: string,
limit?: number
) {
const client = SlackAPI(auth.token)
const params = removeObjectEmptyFields({ cursor, limit })
return await client.users.list(params)
}
Submitted by adam186 640 days ago