Edits history of script submission #17 for ' List Users (slack)'

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/index.ts";
    import { WebClient } from "https://deno.land/x/[email protected]/mod.ts";
    /*
    @param: {string} channel - encoded team id to list users in, required if org token is used.
    @param: {boolean} include_locale - Set this to true to receive the locale for users. Defaults to false
    @param: {number} limit - The maximum number of items to return.
    */
    
    export async function main(
      slack_auth: wmill.Resource<"slack">,
      team_id: string,
      include_locale: boolean = false,
      limit: number = 0,
    ) {
      const web = new WebClient(slack_auth);
    
      let response = await web.users.list({
        team_id: team_id,
        include_locale: include_locale,
        limit: limit,
      });
    
      return { "response": response };
    }

    Submitted by rossmccrann 1449 days ago

  • deno
    import * as wmill from "https://deno.land/x/[email protected]/index.ts";
    import { WebClient } from "https://deno.land/x/[email protected]/mod.ts";
    /*
    @param: {string} channel - encoded team id to list users in, required if org token is used.
    @param: {boolean} include_locale - Set this to true to receive the locale for users. Defaults to false
    @param: {number} limit - The maximum number of items to return. 
    */
    
    export async function main(
      team_id: string,
      include_locale: boolean = false,
      limit: number = 0,
    ) {
      const web = new WebClient(slack_token);
    
      let response = await web.users.list({
        team_id: team_id,
        include_locale: include_locale,
        limit: limit,
      });
    
      return { "response": response };
    }
    

    Submitted by rossmccrann 1450 days ago