slackapi / slackapi/node-slack-sdk

Use the web standard Request/Response types for `installer.handleCallback`

Open
#2,270 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

auto-triage-skip enhancement pkg:oauth
Dominant language
TypeScript
Stars
3.4k
Forks
688
Avg merge
15h 31m
Merged PRs (30d)
27

Description

Currently, the installer.handleCallback method supports the Node specific IncomingMessage and ServerResponse. This is not ideal for apps using Bun and other frameworks like Hono:

Image

Here,

  1. c.req.raw is of type Request and is not assignable to IncomingResponse which is a node:http specific type.
  2. c.Res (type of Response) is not assignable to ServerResponse<IncomingMessage>.

I understand that this is node-slack-sdk and not bun-slack-sdk but this feature request is more about adopting a more compatible standard hence making it more framework/runtime agnostic. Some kind of backward compatibility might be needed.

If this is out of scope, how can I use this package with my above example (Hono and Bun)?

Packages:

Select all that apply:

  • @slack/web-api
  • @slack/rtm-api
  • @slack/webhooks
  • @slack/oauth
  • @slack/socket-mode
  • @slack/types
  • I don't know
Requirements

Please read the Contributing guidelines and Code of Conduct before creating this issue or pull request. By submitting, you are agreeing to those rules.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The entry point is installer.handleCallback in @slack/oauth; read its current Request/Response type declarations and the linked OAuth handling documentation first. Account for both Node IncomingMessage/ServerResponse and web-standard Request/Response, then verify that the Hono/Bun example no longer has the reported type incompatibilities while preserving backward compatibility.

Written by the indexing model from the issue text.

Assessment

Tech stack
bun, node.js, typescript
Domain
api, authentication
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.