Skip to content

docs: add team permissions webhook events to documentation#597

Merged
fomalhautb merged 1 commit intohexclave:devfrom
madster456:docs/add-team-permission-webhooks
Apr 1, 2025
Merged

docs: add team permissions webhook events to documentation#597
fomalhautb merged 1 commit intohexclave:devfrom
madster456:docs/add-team-permission-webhooks

Conversation

@madster456
Copy link
Copy Markdown
Collaborator

@madster456 madster456 commented Mar 29, 2025

Description

Added team permission webhook events to the documentation. This includes:

  • team_permission.created - Triggered when a team permission is created
  • team_permission.deleted - Triggered when a team permission is deleted

Changes

  • Added webhook events to packages/stack-shared/src/interface/webhooks.ts
  • Generated updated OpenAPI documentation

Testing

  • Verified the webhooks appear in the documentation by running the docs server locally
  • Confirmed the webhook payloads match the schema defined in team-permissions.ts

Important

Add teamPermissionCreated and teamPermissionDeleted webhook events to documentation and update OpenAPI docs.

  • Webhooks:
    • Added teamPermissionCreatedWebhookEvent and teamPermissionDeletedWebhookEvent to webhooks.ts.
    • Updated webhookEvents array to include new team permission events.
  • Documentation:
    • Generated updated OpenAPI documentation to include new webhook events.
  • Testing:
    • Verified new webhooks appear in local documentation server.
    • Confirmed webhook payloads match schema in team-permissions.ts.

This description was created by Ellipsis for f54b655. It will automatically update as commits are pushed.

@vercel
Copy link
Copy Markdown

vercel Bot commented Mar 29, 2025

@madster456 is attempting to deploy a commit to the Stack Team on Vercel.

A member of the Team first needs to authorize it.

@CLAassistant
Copy link
Copy Markdown

CLAassistant commented Mar 29, 2025

CLA assistant check
All committers have signed the CLA.

@recurseml
Copy link
Copy Markdown

recurseml Bot commented Mar 29, 2025

✨ No issues found! Your code is sparkling clean! ✨

🗒️ View all ignored comments in this repo
  • The constraint 'TokenStoreType extends string' is too restrictive. It should likely be 'TokenStoreType extends string | object' to match the condition check in line 113 where TokenStoreType is checked against {}
  • Return type mismatch - the interface declares useUsers() returning ServerUser[] but the Team interface that this extends declares useUsers() returning TeamUser[]
  • There is a syntax error in the super constructor call due to the ellipsis operator used incorrectly. Objects aren't being merged correctly. This syntax usage can lead to runtime errors when trying to pass the merged object to 'super()'. Verify that the intended alterations to the object occur before or outside of the super() call if needed.
  • Throwing an error when no active span is found is too aggressive. The log function should gracefully fallback to console.log or another logging mechanism when there's no active span, since not all execution contexts will have an active span. This makes the code less resilient and could break functionality in non-traced environments.

📚 Relevant Docs

  • Function sets backendContext with a new configuration but doesn't pass 'defaultProjectKeys'. Since defaultProjectKeys is required in the type definition and cannot be updated (throws error if tried to set), this will cause a type error.
  • The schema is using array syntax for pick() which is incorrect for Yup schemas. The pick() method in Yup expects individual arguments, not an array. Should be changed to: emailConfigSchema.pick('type', 'host', 'port', 'username', 'sender_name', 'sender_email')

📚 Relevant Docs

  • Creating a refresh token with current timestamp as expiration means it expires immediately. Should set a future date for token expiration.
  • The 'tools' object is initialized as an empty object, even though 'tools' is presumably expected to contain tool definitions. This could cause the server capabilities to lack necessary tool configurations, thus potentially impacting functionalities that depend on certain tool setups.

📚 Relevant Docs

  • 'STACK_SECRET_SERVER_KEY' is potentially being included in every request header without checking its existence again here. Although it's checked during initialization, this could lead to security issues as it's exposed in all communications where the header is logged or captured.

📚 Relevant Docs

  • When adding 'use client' directive at the beginning, it doesn't check if file.text already contains the 'use client' directive. This could lead to duplicate 'use client' directives if the file already has one.

📚 Relevant Docs

@fomalhautb fomalhautb merged commit dfe827c into hexclave:dev Apr 1, 2025
4 of 7 checks passed
@fomalhautb
Copy link
Copy Markdown
Contributor

This is great, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants