data

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 13, 2025 License: Apache-2.0 Imports: 7 Imported by: 0

Documentation

Overview

Package data provides functions to manage persistent data mappings. It is entirely inefficient and should be replaced with a proper solution.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func AddBitbucketUser

func AddBitbucketUser(accountID, email string) error

AddBitbucketUser saves a 2-way mapping between a Bitbucket user's account ID and email address.

func AddGitHubUser

func AddGitHubUser(username, email string) error

AddBitbucketUser saves a 2-way mapping between a GitHub user's username and email address.

func AddSlackUser

func AddSlackUser(userID, email string) error

AddBitbucketUser saves a 2-way mapping between a Slack user's user ID and email address.

func BitbucketUserEmailByID

func BitbucketUserEmailByID(accountID string) (string, error)

BitbucketUserEmailByID returns a Bitbucket user's email based on their account ID. Returns an empty string if the user is not found.

func BitbucketUserIDByEmail

func BitbucketUserIDByEmail(email string) (string, error)

BitbucketUserIDByEmail returns a Bitbucket user's account ID based on their email. Returns an empty string if the user is not found.

func ConvertURLToChannel

func ConvertURLToChannel(url string) (string, error)

func GitHubUserEmailByID

func GitHubUserEmailByID(username string) (string, error)

GitHubUserEmailByID returns a GitHub user's email based on their username. Returns an empty string if the user is not found.

func GitHubUserIDByEmail

func GitHubUserIDByEmail(email string) (string, error)

GitHubUserIDByEmail returns a GitHub user's username based on their email. Returns an empty string if the user is not found.

func IsOptedIn

func IsOptedIn(email string) (bool, error)

func MapURLToChannel

func MapURLToChannel(url, channel string) error

func OptInBitbucketUser

func OptInBitbucketUser(slackUserID, accountID, email string) error

func OptInGitHubUser

func OptInGitHubUser(slackUserID, username, email string) error

func OptOut

func OptOut(email string) error

func RemoveBitbucketUser

func RemoveBitbucketUser(email string) error

RemoveBitbucketUser forgets a Bitbucket user's account ID and email.

func RemoveGitHubUser

func RemoveGitHubUser(email string) error

RemoveGitHubUser forgets a GitHub user's username and email.

func RemoveSlackUser

func RemoveSlackUser(email string) error

RemoveSlackUser forgets a Slack user's user ID and email.

func RemoveURLToChannelMapping

func RemoveURLToChannelMapping(url string) error

func SlackUserEmailByID

func SlackUserEmailByID(userID string) (string, error)

SlackUserEmailByID returns a Slack user's email based on their user ID. Returns an empty string if the user is not found.

func SlackUserIDByEmail

func SlackUserIDByEmail(email string) (string, error)

SlackUserIDByEmail returns a Slack user's user ID based on their email. Returns an empty string if the user is not found.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL