slackline/api/conversations

This module is generated by gleam run -m slackline_codegen/generate. Do not edit it by hand.

Channels, DMs and Slack Connect invitations (conversations.*).

Types

Identifies conversations.acceptSharedInvite in the slackline.Call that accept_shared_invite returns.

pub type AcceptSharedInvite

A successful response from conversations.acceptSharedInvite.

pub type AcceptSharedInviteResponse {
  AcceptSharedInviteResponse(
    implicit_approval: option.Option(Bool),
    channel_id: option.Option(String),
    invite_id: option.Option(String),
  )
}

Constructors

  • AcceptSharedInviteResponse(
      implicit_approval: option.Option(Bool),
      channel_id: option.Option(String),
      invite_id: option.Option(String),
    )

    Arguments

    implicit_approval

    Whether the channel was approved without needing an admin.

    channel_id

    The ID of the Slack Connect channel.

    invite_id

    The ID of the accepted invite.

Identifies conversations.approveSharedInvite in the slackline.Call that approve_shared_invite returns.

pub type ApproveSharedInvite

Identifies conversations.archive in the slackline.Call that archive returns.

pub type Archive

Identifies conversations.canvases.create in the slackline.Call that canvases_create returns.

pub type CanvasesCreate

A successful response from conversations.canvases.create.

pub type CanvasesCreateResponse {
  CanvasesCreateResponse(canvas_id: String)
}

Constructors

  • CanvasesCreateResponse(canvas_id: String)

    Arguments

    canvas_id

    The ID of the new channel canvas.

Identifies conversations.close in the slackline.Call that close returns.

pub type Close

A successful response from conversations.close.

pub type CloseResponse {
  CloseResponse(
    no_op: option.Option(Bool),
    already_closed: option.Option(Bool),
  )
}

Constructors

  • CloseResponse(
      no_op: option.Option(Bool),
      already_closed: option.Option(Bool),
    )

    Arguments

    no_op

    true when nothing happened, for example because the conversation was already closed.

    already_closed

    true when the conversation was already closed.

A pending shared channel invite, sent or received by the workspace.

pub type ConnectInvite {
  ConnectInvite(
    direction: option.Option(String),
    status: option.Option(String),
    date_last_updated: option.Option(Int),
    invite_type: option.Option(String),
    invite: option.Option(ConnectInviteDetails),
    channel: option.Option(ConnectInviteChannel),
    acceptances: option.Option(List(ConnectInviteAcceptance)),
  )
}

Constructors

One acceptance of a Slack Connect invite.

pub type ConnectInviteAcceptance {
  ConnectInviteAcceptance(
    approval_status: option.Option(String),
    date_accepted: option.Option(Int),
    date_invalid: option.Option(Int),
    date_last_updated: option.Option(Int),
    accepting_team: option.Option(team.Team),
    accepting_user: option.Option(user.User),
    reviews: option.Option(List(ConnectInviteReview)),
  )
}

Constructors

  • ConnectInviteAcceptance(
      approval_status: option.Option(String),
      date_accepted: option.Option(Int),
      date_invalid: option.Option(Int),
      date_last_updated: option.Option(Int),
      accepting_team: option.Option(team.Team),
      accepting_user: option.Option(user.User),
      reviews: option.Option(List(ConnectInviteReview)),
    )

    Arguments

    approval_status

    The approval state, such as pending_approval.

    date_accepted

    Unix timestamp of when the invite was accepted.

    date_invalid

    Unix timestamp of when the acceptance stops being valid.

    date_last_updated

    Unix timestamp of the last update.

    accepting_team

    The workspace or organization that accepted the invite.

    accepting_user

    The user who accepted the invite.

    reviews

    Reviews of this acceptance.

The channel a pending Slack Connect invite is for.

pub type ConnectInviteChannel {
  ConnectInviteChannel(
    id: String,
    name: option.Option(String),
    is_private: option.Option(Bool),
    is_im: option.Option(Bool),
  )
}

Constructors

  • ConnectInviteChannel(
      id: String,
      name: option.Option(String),
      is_private: option.Option(Bool),
      is_im: option.Option(Bool),
    )

    Arguments

    id

    The channel ID.

    name

    The channel name.

    is_private

    Whether the channel is private.

    is_im

    Whether the conversation is a DM.

The invite part of a pending Slack Connect invite.

pub type ConnectInviteDetails {
  ConnectInviteDetails(
    id: String,
    date_created: option.Option(Int),
    date_invalid: option.Option(Int),
    inviting_team: option.Option(team.Team),
    inviting_user: option.Option(user.User),
    recipient_email: option.Option(String),
    recipient_user_id: option.Option(String),
    link: option.Option(String),
  )
}

Constructors

  • ConnectInviteDetails(
      id: String,
      date_created: option.Option(Int),
      date_invalid: option.Option(Int),
      inviting_team: option.Option(team.Team),
      inviting_user: option.Option(user.User),
      recipient_email: option.Option(String),
      recipient_user_id: option.Option(String),
      link: option.Option(String),
    )

    Arguments

    id

    The invite ID.

    date_created

    Unix timestamp of when the invite was created.

    date_invalid

    Unix timestamp of when the invite stops being valid.

    inviting_team

    The workspace or organization that sent the invite.

    inviting_user

    The user who sent the invite.

    recipient_email

    The email address the invite was sent to.

    recipient_user_id

    The user the invite was sent to.

    link

    The invite link.

A review (approval or denial) of an accepted Slack Connect invite.

pub type ConnectInviteReview {
  ConnectInviteReview(
    review_type: option.Option(String),
    date_review: option.Option(Int),
    reviewing_team: option.Option(team.Team),
  )
}

Constructors

  • ConnectInviteReview(
      review_type: option.Option(String),
      date_review: option.Option(Int),
      reviewing_team: option.Option(team.Team),
    )

    Arguments

    review_type

    The kind of review, such as approval.

    date_review

    Unix timestamp of the review.

    reviewing_team

    The workspace or organization that reviewed the invite.

Why one user could not be invited by conversations.invite.

pub type ConversationInviteError {
  ConversationInviteError(
    user: option.Option(String),
    ok: option.Option(Bool),
    error: option.Option(String),
  )
}

Constructors

  • ConversationInviteError(
      user: option.Option(String),
      ok: option.Option(Bool),
      error: option.Option(String),
    )

    Arguments

    user

    The user that could not be invited.

    ok

    Always false.

    error

    The error code, such as user_not_found or cant_invite_self.

Identifies conversations.create in the slackline.Call that create returns.

pub type Create

A successful response from conversations.create.

pub type CreateResponse {
  CreateResponse(channel: conversation.Conversation)
}

Constructors

Identifies conversations.declineSharedInvite in the slackline.Call that decline_shared_invite returns.

pub type DeclineSharedInvite

Whether to upgrade or downgrade an external invite.

pub type ExternalInviteAction {
  Upgrade
  Downgrade
}

Constructors

  • Upgrade

    upgrade

  • Downgrade

    downgrade

Identifies conversations.externalInvitePermissions.set in the slackline.Call that external_invite_permissions_set returns.

pub type ExternalInvitePermissionsSet

Identifies conversations.history in the slackline.Call that history returns.

pub type History

A successful response from conversations.history.

pub type HistoryResponse {
  HistoryResponse(
    messages: option.Option(List(message.Message)),
    has_more: option.Option(Bool),
    pin_count: option.Option(Int),
    latest: option.Option(String),
    is_limited: option.Option(Bool),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

  • HistoryResponse(
      messages: option.Option(List(message.Message)),
      has_more: option.Option(Bool),
      pin_count: option.Option(Int),
      latest: option.Option(String),
      is_limited: option.Option(Bool),
      response_metadata: option.Option(slackline.ResponseMetadata),
    )

    Arguments

    messages

    The messages, most recent first.

    has_more

    true when more messages exist in the requested time range.

    pin_count

    The number of pinned items in the conversation.

    latest

    The latest timestamp of the request, echoed back.

    is_limited

    Only for free teams past the message limit: true when older messages exist beyond the limit.

Identifies conversations.info in the slackline.Call that info returns.

pub type Info

A successful response from conversations.info.

pub type InfoResponse {
  InfoResponse(channel: conversation.Conversation)
}

Constructors

Identifies conversations.invite in the slackline.Call that invite returns.

pub type Invite

A successful response from conversations.invite.

pub type InviteResponse {
  InviteResponse(
    channel: conversation.Conversation,
    errors: option.Option(List(ConversationInviteError)),
  )
}

Constructors

Identifies conversations.inviteShared in the slackline.Call that invite_shared returns.

pub type InviteShared

A successful response from conversations.inviteShared.

pub type InviteSharedResponse {
  InviteSharedResponse(
    invite_id: String,
    is_legacy_shared_channel: option.Option(Bool),
    conf_code: option.Option(String),
    url: option.Option(String),
  )
}

Constructors

  • InviteSharedResponse(
      invite_id: String,
      is_legacy_shared_channel: option.Option(Bool),
      conf_code: option.Option(String),
      url: option.Option(String),
    )

    Arguments

    invite_id

    The ID of the invite.

    is_legacy_shared_channel

    Whether the channel is a legacy shared channel.

    conf_code

    The invite confirmation code. Omitted for targeted invites and when external_limited is true.

    url

    The invite URL. Omitted for targeted invites and when external_limited is true.

Identifies conversations.join in the slackline.Call that join returns.

pub type Join

A successful response from conversations.join.

pub type JoinResponse {
  JoinResponse(
    channel: conversation.Conversation,
    warning: option.Option(String),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

Identifies conversations.kick in the slackline.Call that kick returns.

pub type Kick

A successful response from conversations.kick.

pub type KickResponse {
  KickResponse(errors: option.Option(value.Value))
}

Constructors

Identifies conversations.leave in the slackline.Call that leave returns.

pub type Leave

A successful response from conversations.leave.

pub type LeaveResponse {
  LeaveResponse(not_in_channel: option.Option(Bool))
}

Constructors

  • LeaveResponse(not_in_channel: option.Option(Bool))

    Arguments

    not_in_channel

    true when the user was not in the conversation.

Identifies conversations.listConnectInvites in the slackline.Call that list_connect_invites returns.

pub type ListConnectInvites

A successful response from conversations.listConnectInvites.

pub type ListConnectInvitesResponse {
  ListConnectInvitesResponse(
    invites: option.Option(List(ConnectInvite)),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

Identifies conversations.list in the slackline.Call that list returns.

pub type ListMethod

A successful response from conversations.list.

pub type ListResponse {
  ListResponse(
    channels: option.Option(List(conversation.Conversation)),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

Identifies conversations.mark in the slackline.Call that mark returns.

pub type Mark

Identifies conversations.members in the slackline.Call that members returns.

pub type Members

A successful response from conversations.members.

pub type MembersResponse {
  MembersResponse(
    members: option.Option(List(String)),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

Identifies conversations.open in the slackline.Call that open returns.

pub type Open

A successful response from conversations.open.

pub type OpenResponse {
  OpenResponse(
    channel: conversation.Conversation,
    no_op: option.Option(Bool),
    already_open: option.Option(Bool),
  )
}

Constructors

  • OpenResponse(
      channel: conversation.Conversation,
      no_op: option.Option(Bool),
      already_open: option.Option(Bool),
    )

    Arguments

    channel

    The conversation. Only id is set unless return_im is true.

    no_op

    true when the conversation already existed.

    already_open

    true when the conversation was already open.

Identifies conversations.rename in the slackline.Call that rename returns.

pub type Rename

A successful response from conversations.rename.

pub type RenameResponse {
  RenameResponse(channel: conversation.Conversation)
}

Constructors

Identifies conversations.replies in the slackline.Call that replies returns.

pub type Replies

A successful response from conversations.replies.

pub type RepliesResponse {
  RepliesResponse(
    messages: option.Option(List(message.Message)),
    has_more: option.Option(Bool),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

Identifies conversations.requestSharedInvite.approve in the slackline.Call that request_shared_invite_approve returns.

pub type RequestSharedInviteApprove

A successful response from conversations.requestSharedInvite.approve.

pub type RequestSharedInviteApproveResponse {
  RequestSharedInviteApproveResponse(invite_id: String)
}

Constructors

  • RequestSharedInviteApproveResponse(invite_id: String)

    Arguments

    invite_id

    The ID of the approved invitation request.

Identifies conversations.requestSharedInvite.deny in the slackline.Call that request_shared_invite_deny returns.

pub type RequestSharedInviteDeny

A successful response from conversations.requestSharedInvite.deny.

pub type RequestSharedInviteDenyResponse {
  RequestSharedInviteDenyResponse(invite_id: String)
}

Constructors

  • RequestSharedInviteDenyResponse(invite_id: String)

    Arguments

    invite_id

    The ID of the denied invitation request.

Identifies conversations.requestSharedInvite.list in the slackline.Call that request_shared_invite_list returns.

pub type RequestSharedInviteList

A successful response from conversations.requestSharedInvite.list.

pub type RequestSharedInviteListResponse {
  RequestSharedInviteListResponse(
    invite_requests: option.Option(List(SharedInviteRequest)),
    response_metadata: option.Option(slackline.ResponseMetadata),
  )
}

Constructors

Identifies conversations.setPurpose in the slackline.Call that set_purpose returns.

pub type SetPurpose

A successful response from conversations.setPurpose.

pub type SetPurposeResponse {
  SetPurposeResponse(purpose: option.Option(String))
}

Constructors

  • SetPurposeResponse(purpose: option.Option(String))

    Arguments

    purpose

    The new purpose.

Identifies conversations.setTopic in the slackline.Call that set_topic returns.

pub type SetTopic

A successful response from conversations.setTopic.

pub type SetTopicResponse {
  SetTopicResponse(channel: conversation.Conversation)
}

Constructors

The channel of a requested Slack Connect invitation.

pub type SharedInviteChannel {
  SharedInviteChannel(
    id: String,
    name: option.Option(String),
    is_im: option.Option(Bool),
    is_private: option.Option(Bool),
    date_created: option.Option(Int),
    connections: option.Option(List(SharedInviteConnection)),
    pending_connections: option.Option(
      List(SharedInviteConnection),
    ),
    previous_connections: option.Option(
      List(SharedInviteConnection),
    ),
  )
}

Constructors

A team connected to a shared channel.

pub type SharedInviteConnection {
  SharedInviteConnection(
    team: option.Option(team.Team),
    is_private: option.Option(Bool),
  )
}

Constructors

  • SharedInviteConnection(
      team: option.Option(team.Team),
      is_private: option.Option(Bool),
    )

    Arguments

    team

    The connected workspace or organization.

    is_private

    Whether the channel is private for this team.

A message sent along with an approved Slack Connect invitation request.

pub type SharedInviteMessage {
  SharedInviteMessage(text: String, is_override: Bool)
}

Constructors

  • SharedInviteMessage(text: String, is_override: Bool)

    Arguments

    text

    The text of the message. With is_override false, the combined length with the original message must stay under 560 characters.

    is_override

    When true, text replaces the original invitation message. Otherwise Slack adds text to the end of it.

A requested Slack Connect invitation.

pub type SharedInviteRequest {
  SharedInviteRequest(
    id: String,
    date_created: option.Option(Int),
    date_last_updated: option.Option(Int),
    expires_at: option.Option(Int),
    date_denied: option.Option(Int),
    inviting_team: option.Option(team.Team),
    inviting_user: option.Option(user.User),
    reviewing_user: option.Option(user.User),
    is_external_limited: option.Option(Bool),
    is_sponsored: option.Option(Bool),
    recipient_email: option.Option(String),
    target_user: option.Option(SharedInviteTargetUser),
    channel: option.Option(SharedInviteChannel),
  )
}

Constructors

  • SharedInviteRequest(
      id: String,
      date_created: option.Option(Int),
      date_last_updated: option.Option(Int),
      expires_at: option.Option(Int),
      date_denied: option.Option(Int),
      inviting_team: option.Option(team.Team),
      inviting_user: option.Option(user.User),
      reviewing_user: option.Option(user.User),
      is_external_limited: option.Option(Bool),
      is_sponsored: option.Option(Bool),
      recipient_email: option.Option(String),
      target_user: option.Option(SharedInviteTargetUser),
      channel: option.Option(SharedInviteChannel),
    )

    Arguments

    id

    The invitation request ID.

    date_created

    Unix timestamp of when the request was created.

    date_last_updated

    Unix timestamp of the last update.

    expires_at

    Unix timestamp of when the request expires.

    date_denied

    Unix timestamp of when the request was denied.

    inviting_team

    The workspace or organization of the requesting user.

    inviting_user

    The user who requested the invitation.

    reviewing_user

    The user who reviewed the request.

    is_external_limited

    Whether the invited party has post-only permissions.

    is_sponsored

    Whether the invitation is sponsored.

    recipient_email

    The email address of the invited user.

    target_user

    The invited user.

    channel

    The channel the user is invited to.

The recipient of a requested Slack Connect invitation.

pub type SharedInviteTargetUser {
  SharedInviteTargetUser(
    recipient_email: option.Option(String),
    recipient_user_id: option.Option(String),
  )
}

Constructors

  • SharedInviteTargetUser(
      recipient_email: option.Option(String),
      recipient_user_id: option.Option(String),
    )

    Arguments

    recipient_email

    The recipient’s email address.

    recipient_user_id

    The recipient’s user ID.

Identifies conversations.unarchive in the slackline.Call that unarchive returns.

pub type Unarchive

Values

pub fn accept_shared_invite(
  channel_name channel_name: String,
) -> slackline.Call(
  AcceptSharedInvite,
  AcceptSharedInviteResponse,
)

conversations.acceptSharedInvite: Accepts an invitation to a Slack Connect channel.

conversations.AcceptSharedInvite identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/accept_shared_invite.

Bot token scopes: conversations.connect:write.

Rate limit tier: t2.

Documented errors: accepter_email_not_verified, channel_conversion_in_progress, connection_limit_exceeded, email_does_not_match, failed_to_start_trial, has_already_connected_to_org, invalid_emoji_not_allowed, invalid_host_team, invalid_link, invalid_name, invalid_name_maxlength, invalid_name_punctuation, invalid_name_required, invalid_name_specials, invalid_privacy, invalid_recipient_team, invalid_target_team, invite_from_same_org, invite_not_found, invite_used, is_pending_connected_to_org, legacy_connection_invalid_org, legacy_connection_limit_exceeded, name_taken, not_allowed_for_grid_workspace, not_paid, restricted_action, team_not_found, user_cannot_create_channel, user_is_restricted, user_not_found, user_required_to_accept_as_private_but_cannot.

pub fn accept_shared_invite_response_decoder() -> decode.Decoder(
  AcceptSharedInviteResponse,
)

Decodes the response from conversations.acceptSharedInvite.

pub fn approve_shared_invite(
  invite_id invite_id: String,
) -> slackline.Call(ApproveSharedInvite, Nil)

conversations.approveSharedInvite: Approves an invitation to a Slack Connect channel

conversations.ApproveSharedInvite identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/approve_shared_invite.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t3.

Documented errors: already_approved, approval_inactive, approval_not_found, channel_conversion_in_progress, channel_not_found, invalid_action, invalid_link, invite_not_found, missing_target_team, not_paid, restricted_action.

pub fn archive(
  channel channel: String,
) -> slackline.Call(Archive, Nil)

conversations.archive: Archives a conversation.

conversations.Archive identifies this method in slackline.Call.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t2.

Documented errors: already_archived, cant_archive_general, cant_archive_required, channel_not_found, method_not_supported_for_channel_type, not_in_channel, restricted_action.

pub fn canvases_create(
  channel_id channel_id: String,
) -> slackline.Call(CanvasesCreate, CanvasesCreateResponse)

conversations.canvases.create: Create a channel canvas for a channel

conversations.CanvasesCreate identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/canvases_create.

Bot token scopes: canvases:write. User token scopes: canvases:write.

Rate limit tier: t2.

Documented errors: canvas_creation_failed, canvas_disabled_user_team, canvas_tab_creation_failed, channel_canvas_already_exists, channel_canvas_creation_failed, channel_not_found, free_team_canvas_tab_already_exists, posting_to_channel_denied, restricted_action, team_tier_cannot_create_channel_canvases.

pub fn canvases_create_response_decoder() -> decode.Decoder(
  CanvasesCreateResponse,
)

Decodes the response from conversations.canvases.create.

pub fn close(
  channel channel: String,
) -> slackline.Call(Close, CloseResponse)

conversations.close: Closes a direct message or multi-person direct message.

conversations.Close identifies this method in slackline.Call.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t2.

Documented errors: channel_not_found, external_channel_migrating, method_not_supported_for_channel_type, not_permitted, user_does_not_own_channel.

pub fn close_response_decoder() -> decode.Decoder(CloseResponse)

Decodes the response from conversations.close.

pub fn connect_invite_acceptance_decoder() -> decode.Decoder(
  ConnectInviteAcceptance,
)

Decodes ConnectInviteAcceptance from json.

pub fn connect_invite_acceptance_to_json(
  it: ConnectInviteAcceptance,
) -> json.Json

Encodes ConnectInviteAcceptance as json.

pub fn connect_invite_channel_decoder() -> decode.Decoder(
  ConnectInviteChannel,
)

Decodes ConnectInviteChannel from json.

pub fn connect_invite_channel_to_json(
  it: ConnectInviteChannel,
) -> json.Json

Encodes ConnectInviteChannel as json.

pub fn connect_invite_decoder() -> decode.Decoder(ConnectInvite)

Decodes ConnectInvite from json.

pub fn connect_invite_details_decoder() -> decode.Decoder(
  ConnectInviteDetails,
)

Decodes ConnectInviteDetails from json.

pub fn connect_invite_details_to_json(
  it: ConnectInviteDetails,
) -> json.Json

Encodes ConnectInviteDetails as json.

pub fn connect_invite_review_decoder() -> decode.Decoder(
  ConnectInviteReview,
)

Decodes ConnectInviteReview from json.

pub fn connect_invite_review_to_json(
  it: ConnectInviteReview,
) -> json.Json

Encodes ConnectInviteReview as json.

pub fn connect_invite_to_json(it: ConnectInvite) -> json.Json

Encodes ConnectInvite as json.

pub fn conversation_invite_error_decoder() -> decode.Decoder(
  ConversationInviteError,
)

Decodes ConversationInviteError from json.

pub fn conversation_invite_error_to_json(
  it: ConversationInviteError,
) -> json.Json

Encodes ConversationInviteError as json.

pub fn create(
  name name: String,
) -> slackline.Call(Create, CreateResponse)

conversations.create: Initiates a public or private channel-based conversation

conversations.Create identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/create.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t2.

Documented errors: cannot_create_channel, canvas_disabled_user_team, invalid_name, invalid_name_maxlength, invalid_name_punctuation, invalid_name_required, invalid_name_specials, name_taken, no_channel, restricted_action.

pub fn create_response_decoder() -> decode.Decoder(CreateResponse)

Decodes the response from conversations.create.

pub fn decline_shared_invite(
  invite_id invite_id: String,
) -> slackline.Call(DeclineSharedInvite, Nil)

conversations.declineSharedInvite: Declines a Slack Connect channel invite.

conversations.DeclineSharedInvite identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/decline_shared_invite.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t3.

Documented errors: approval_inactive, approval_not_found, inactive_invite, invite_not_found, missing_target_team, not_paid, restricted_action.

pub fn external_invite_action_decoder() -> decode.Decoder(
  ExternalInviteAction,
)

Decodes ExternalInviteAction from a json string.

pub fn external_invite_action_from_string(
  string: String,
) -> Result(ExternalInviteAction, Nil)

Parses ExternalInviteAction from its json string.

pub fn external_invite_action_to_json(
  it: ExternalInviteAction,
) -> json.Json

Encodes ExternalInviteAction as a json string.

pub fn external_invite_action_to_string(
  it: ExternalInviteAction,
) -> String

The json string of ExternalInviteAction.

pub fn external_invite_permissions_set(
  channel channel: String,
  target_team target_team: String,
  action action: ExternalInviteAction,
) -> slackline.Call(ExternalInvitePermissionsSet, Nil)

conversations.externalInvitePermissions.set: Upgrade or downgrade Slack Connect channel permissions between ‘can post only’ and ‘can post and invite’.

conversations.ExternalInvitePermissionsSet identifies this method in slackline.Call.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t2.

Documented errors: channel_not_found, invalid_action, invalid_target_team, not_supported, restricted_action.

pub fn history(
  channel channel: String,
) -> slackline.Call(History, HistoryResponse)

conversations.history: Fetches a conversation’s history of messages and events.

conversations.History identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/history.

Bot token scopes: groups:history, im:history, mpim:history, channels:history. User token scopes: groups:history, im:history, mpim:history, channels:history.

Rate limit tier: t3.

Documented errors: channel_is_limited_access, channel_not_found, invalid_cursor, invalid_metadata_filter_keys, invalid_ts_latest, invalid_ts_oldest, not_in_channel, restricted_action.

pub fn history_response_decoder() -> decode.Decoder(
  HistoryResponse,
)

Decodes the response from conversations.history.

pub fn info(
  channel channel: String,
) -> slackline.Call(Info, InfoResponse)

conversations.info: Retrieve information about a conversation.

conversations.Info identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/info.

Bot token scopes: groups:read, im:read, mpim:read, channels:read. User token scopes: groups:read, im:read, mpim:read, channels:read.

Rate limit tier: t3.

Documented errors: channel_is_limited_access, channel_not_found.

pub fn info_response_decoder() -> decode.Decoder(InfoResponse)

Decodes the response from conversations.info.

pub fn invite(
  channel channel: String,
  users users: List(String),
) -> slackline.Call(Invite, InviteResponse)

conversations.invite: Invites users to a channel.

conversations.Invite identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/invite.

Bot token scopes: channels:write.invites, groups:write.invites, channels:manage, groups:write, im:write, mpim:write. User token scopes: channels:write.invites, groups:write.invites, channels:write, groups:write, im:write, mpim:write.

Rate limit tier: t3.

Documented errors: already_in_channel, app_cannot_join_channel, cant_invite, cant_invite_self, channel_not_found, external_channel_migrating, invitee_cant_see_channel, is_archived, method_not_supported_for_channel_type, no_external_invite_permission, no_user, not_in_channel, org_user_not_in_team, ura_max_channels, user_is_restricted, user_not_found.

pub fn invite_response_decoder() -> decode.Decoder(InviteResponse)

Decodes the response from conversations.invite.

pub fn invite_shared(
  channel channel: String,
) -> slackline.Call(InviteShared, InviteSharedResponse)

conversations.inviteShared: Sends an invitation to a Slack Connect channel

conversations.InviteShared identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/invite_shared.

Bot token scopes: conversations.connect:write.

Rate limit tier: t2.

Documented errors: already_in_channel, cannot_share_cross_workspace_channel, cannot_share_mandatory_channel, channel_archived, channel_not_found, connection_limit_exceeded, connection_limit_exceeded_pending, invalid_channel_type, invalid_email, invite_lookup_error, invite_not_found, inviter_email_not_verified, legacy_connection_limit_exceeded, member_limit_exceeded, message_too_long, no_external_invite_permission, not_allowed_for_grid_workspace, not_in_channel, not_owner, not_paid, not_supported, ratelimit, recipients_not_specified, restricted_action, too_many_emails, url_in_message, user_not_found.

pub fn invite_shared_response_decoder() -> decode.Decoder(
  InviteSharedResponse,
)

Decodes the response from conversations.inviteShared.

pub fn join(
  channel channel: String,
) -> slackline.Call(Join, JoinResponse)

conversations.join: Joins an existing conversation.

conversations.Join identifies this method in slackline.Call.

Bot token scopes: channels:join. User token scopes: channels:write.

Rate limit tier: t3.

Documented errors: app_cannot_join_channel, channel_is_limited_access, channel_not_found, is_archived, method_not_supported_for_channel_type, too_many_members.

pub fn join_response_decoder() -> decode.Decoder(JoinResponse)

Decodes the response from conversations.join.

pub fn kick(
  channel channel: String,
) -> slackline.Call(Kick, KickResponse)

conversations.kick: Removes a user from a conversation.

conversations.Kick identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/kick.

Bot token scopes: groups:write, channels:manage. User token scopes: groups:write, channels:write.

Rate limit tier: t3.

Documented errors: cant_kick_from_general, cant_kick_self, channel_not_found, method_not_supported_for_channel_type, no_user, not_in_channel, not_supported, restricted_action, user_not_found.

pub fn kick_response_decoder() -> decode.Decoder(KickResponse)

Decodes the response from conversations.kick.

pub fn leave(
  channel channel: String,
) -> slackline.Call(Leave, LeaveResponse)

conversations.leave: Leaves a conversation.

conversations.Leave identifies this method in slackline.Call.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t3.

Documented errors: cant_leave_general, channel_not_found, is_archived, last_member, method_not_supported_for_channel_type, user_is_restricted.

pub fn leave_response_decoder() -> decode.Decoder(LeaveResponse)

Decodes the response from conversations.leave.

pub fn list() -> slackline.Call(ListMethod, ListResponse)

conversations.list: Lists all channels in a Slack team.

conversations.ListMethod identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/list.

Bot token scopes: groups:read, im:read, mpim:read, channels:read. User token scopes: groups:read, im:read, mpim:read, channels:read.

Rate limit tier: t2.

Documented errors: invalid_cursor, invalid_limit, invalid_types, method_not_supported_for_channel_type.

pub fn list_connect_invites() -> slackline.Call(
  ListConnectInvites,
  ListConnectInvitesResponse,
)

conversations.listConnectInvites: Lists shared channel invites that have been generated or received but have not been approved by all parties

conversations.ListConnectInvites identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/list_connect_invites.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t1.

Documented errors: restricted_action.

pub fn list_connect_invites_response_decoder() -> decode.Decoder(
  ListConnectInvitesResponse,
)

Decodes the response from conversations.listConnectInvites.

pub fn list_response_decoder() -> decode.Decoder(ListResponse)

Decodes the response from conversations.list.

pub fn mark(
  channel channel: String,
  ts ts: String,
) -> slackline.Call(Mark, Nil)

conversations.mark: Sets the read cursor in a channel.

conversations.Mark identifies this method in slackline.Call.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t3.

Documented errors: channel_not_found, invalid_timestamp, not_in_channel.

pub fn members(
  channel channel: String,
) -> slackline.Call(Members, MembersResponse)

conversations.members: Retrieve members of a conversation.

conversations.Members identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/members.

Bot token scopes: groups:read, im:read, mpim:read, channels:read. User token scopes: groups:read, im:read, mpim:read, channels:read.

Rate limit tier: t4.

Documented errors: channel_not_found, fetch_members_failed, invalid_cursor, invalid_limit, method_not_supported_for_channel_type.

pub fn members_response_decoder() -> decode.Decoder(
  MembersResponse,
)

Decodes the response from conversations.members.

pub fn open() -> slackline.Call(Open, OpenResponse)

conversations.open: Opens or resumes a direct message or multi-person direct message.

conversations.Open identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/open.

Bot token scopes: channels:manage, groups:write, im:write, mpim:write. User token scopes: channels:write, groups:write, im:write, mpim:write.

Rate limit tier: t3.

Documented errors: app_cannot_join_channel, channel_not_found, invalid_user_combination, method_not_supported_for_channel_type, not_enough_users, restricted_action, too_many_users, user_disabled, user_not_found, user_not_visible, users_list_not_supplied.

pub fn open_response_decoder() -> decode.Decoder(OpenResponse)

Decodes the response from conversations.open.

pub fn rename(
  channel channel: String,
  name name: String,
) -> slackline.Call(Rename, RenameResponse)

conversations.rename: Renames a conversation.

conversations.Rename identifies this method in slackline.Call.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t2.

Documented errors: channel_not_found, invalid_name, invalid_name_maxlength, invalid_name_punctuation, invalid_name_required, invalid_name_specials, is_archived, method_not_supported_for_channel_type, name_taken, not_authorized, not_in_channel.

pub fn rename_response_decoder() -> decode.Decoder(RenameResponse)

Decodes the response from conversations.rename.

pub fn replies(
  channel channel: String,
  ts ts: String,
) -> slackline.Call(Replies, RepliesResponse)

conversations.replies: Retrieve a thread of messages posted to a conversation

conversations.Replies identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/replies.

Bot token scopes: groups:history, im:history, mpim:history, channels:history. User token scopes: groups:history, im:history, mpim:history, channels:history.

Rate limit tier: t3.

Documented errors: channel_not_found, invalid_cursor, invalid_metadata_filter_keys, invalid_ts_latest, invalid_ts_oldest, list_record_comment_fetch_failed, method_not_supported_for_channel_type, thread_not_found.

pub fn replies_response_decoder() -> decode.Decoder(
  RepliesResponse,
)

Decodes the response from conversations.replies.

pub fn request_shared_invite_approve(
  invite_id invite_id: String,
) -> slackline.Call(
  RequestSharedInviteApprove,
  RequestSharedInviteApproveResponse,
)

conversations.requestSharedInvite.approve: Approves a request to add an external user to a channel and sends them a Slack Connect invite

conversations.RequestSharedInviteApprove identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/request_shared_invite_approve.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t2.

Documented errors: channel_not_found, invite_already_approved, invite_already_denied, invite_expired, invite_not_found, message_too_long, no_external_invite_permission, restricted_action, team_not_found, user_not_found.

pub fn request_shared_invite_approve_response_decoder() -> decode.Decoder(
  RequestSharedInviteApproveResponse,
)

Decodes the response from conversations.requestSharedInvite.approve.

pub fn request_shared_invite_deny(
  invite_id invite_id: String,
) -> slackline.Call(
  RequestSharedInviteDeny,
  RequestSharedInviteDenyResponse,
)

conversations.requestSharedInvite.deny: Denies a request to invite an external user to a channel

conversations.RequestSharedInviteDeny identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/request_shared_invite_deny.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t2.

Documented errors: channel_not_found, invite_already_approved, invite_already_denied, invite_expired, invite_not_found, message_too_long, restricted_action, team_not_found, user_not_found.

pub fn request_shared_invite_deny_response_decoder() -> decode.Decoder(
  RequestSharedInviteDenyResponse,
)

Decodes the response from conversations.requestSharedInvite.deny.

pub fn request_shared_invite_list() -> slackline.Call(
  RequestSharedInviteList,
  RequestSharedInviteListResponse,
)

conversations.requestSharedInvite.list: Lists requests to add external users to channels with ability to filter.

conversations.RequestSharedInviteList identifies this method in slackline.Call.

Set optional arguments with the functions in slackline/api/conversations/request_shared_invite_list.

Bot token scopes: conversations.connect:manage.

Rate limit tier: t2.

Documented errors: invalid_cursor, not_implemented, restricted_action.

pub fn request_shared_invite_list_response_decoder() -> decode.Decoder(
  RequestSharedInviteListResponse,
)

Decodes the response from conversations.requestSharedInvite.list.

pub fn set_purpose(
  channel channel: String,
  purpose purpose: String,
) -> slackline.Call(SetPurpose, SetPurposeResponse)

conversations.setPurpose: Sets the channel description.

conversations.SetPurpose identifies this method in slackline.Call.

Bot token scopes: channels:write.topic, groups:write.topic, mpim:write.topic, im:write.topic, channels:manage, groups:write, im:write, mpim:write. User token scopes: channels:write.topic, groups:write.topic, mpim:write.topic, im:write.topic, channels:write, groups:write, im:write, mpim:write.

Rate limit tier: t2.

Documented errors: channel_not_found, is_archived, method_not_supported_for_channel_type, not_in_channel, too_long, user_is_restricted.

pub fn set_purpose_response_decoder() -> decode.Decoder(
  SetPurposeResponse,
)

Decodes the response from conversations.setPurpose.

pub fn set_topic(
  channel channel: String,
  topic topic: String,
) -> slackline.Call(SetTopic, SetTopicResponse)

conversations.setTopic: Sets the topic for a conversation.

conversations.SetTopic identifies this method in slackline.Call.

Bot token scopes: channels:write.topic, groups:write.topic, mpim:write.topic, im:write.topic, channels:manage, groups:write, im:write, mpim:write. User token scopes: channels:write.topic, groups:write.topic, mpim:write.topic, im:write.topic, channels:write, groups:write, im:write, mpim:write.

Rate limit tier: t2.

Documented errors: channel_not_found, is_archived, method_not_supported_for_channel_type, not_in_channel, too_long, user_is_restricted.

pub fn set_topic_response_decoder() -> decode.Decoder(
  SetTopicResponse,
)

Decodes the response from conversations.setTopic.

pub fn shared_invite_channel_decoder() -> decode.Decoder(
  SharedInviteChannel,
)

Decodes SharedInviteChannel from json.

pub fn shared_invite_channel_to_json(
  it: SharedInviteChannel,
) -> json.Json

Encodes SharedInviteChannel as json.

pub fn shared_invite_connection_decoder() -> decode.Decoder(
  SharedInviteConnection,
)

Decodes SharedInviteConnection from json.

pub fn shared_invite_connection_to_json(
  it: SharedInviteConnection,
) -> json.Json

Encodes SharedInviteConnection as json.

pub fn shared_invite_message_decoder() -> decode.Decoder(
  SharedInviteMessage,
)

Decodes SharedInviteMessage from json.

pub fn shared_invite_message_to_json(
  it: SharedInviteMessage,
) -> json.Json

Encodes SharedInviteMessage as json.

pub fn shared_invite_request_decoder() -> decode.Decoder(
  SharedInviteRequest,
)

Decodes SharedInviteRequest from json.

pub fn shared_invite_request_to_json(
  it: SharedInviteRequest,
) -> json.Json

Encodes SharedInviteRequest as json.

pub fn shared_invite_target_user_decoder() -> decode.Decoder(
  SharedInviteTargetUser,
)

Decodes SharedInviteTargetUser from json.

pub fn shared_invite_target_user_to_json(
  it: SharedInviteTargetUser,
) -> json.Json

Encodes SharedInviteTargetUser as json.

pub fn unarchive(
  channel channel: String,
) -> slackline.Call(Unarchive, Nil)

conversations.unarchive: Reverses conversation archival.

conversations.Unarchive identifies this method in slackline.Call.

Bot token scopes: groups:write, im:write, mpim:write, channels:write, channels:manage. User token scopes: groups:write, im:write, mpim:write, channels:write.

Rate limit tier: t2.

Documented errors: channel_not_found, method_not_supported_for_channel_type, not_archived.

✨ Search Document