Documentation ¶
Index ¶
- Constants
- func AfterEach()
- func AssociateUserToTenant(tenantId string, userId string, userContext ...supertokens.UserContext) (multitenancymodels.AssociateUserToTenantResponse, error)
- func BeforeEach()
- func CreateOrUpdateTenant(tenantId string, config multitenancymodels.TenantConfig, ...) (multitenancymodels.CreateOrUpdateTenantResponse, error)
- func CreateOrUpdateThirdPartyConfig(tenantId string, config tpmodels.ProviderConfig, skipValidation *bool, ...) (multitenancymodels.CreateOrUpdateThirdPartyConfigResponse, error)
- func DeleteTenant(tenantId string, userContext ...supertokens.UserContext) (multitenancymodels.DeleteTenantResponse, error)
- func DeleteThirdPartyConfig(tenantId string, thirdPartyId string, userContext ...supertokens.UserContext) (multitenancymodels.DeleteThirdPartyConfigResponse, error)
- func DisassociateUserFromTenant(tenantId string, userId string, userContext ...supertokens.UserContext) (multitenancymodels.DisassociateUserFromTenantResponse, error)
- func GetTenant(tenantId string, userContext ...supertokens.UserContext) (*multitenancymodels.Tenant, error)
- func Init(config *multitenancymodels.TypeInput) supertokens.Recipe
- func ListAllTenants(userContext ...supertokens.UserContext) (multitenancymodels.ListAllTenantsResponse, error)
- func NewAllowedDomainsClaim() (*claims.TypeSessionClaim, claims.PrimitiveArrayClaimValidators)
- func ResetForTest()
- type Recipe
Constants ¶
View Source
const (
LoginMethodsAPI = "/loginmethods"
)
View Source
const RECIPE_ID = "multitenancy"
Variables ¶
This section is empty.
Functions ¶
func AssociateUserToTenant ¶
func AssociateUserToTenant(tenantId string, userId string, userContext ...supertokens.UserContext) (multitenancymodels.AssociateUserToTenantResponse, error)
func BeforeEach ¶
func BeforeEach()
func CreateOrUpdateTenant ¶
func CreateOrUpdateTenant(tenantId string, config multitenancymodels.TenantConfig, userContext ...supertokens.UserContext) (multitenancymodels.CreateOrUpdateTenantResponse, error)
func CreateOrUpdateThirdPartyConfig ¶
func CreateOrUpdateThirdPartyConfig(tenantId string, config tpmodels.ProviderConfig, skipValidation *bool, userContext ...supertokens.UserContext) (multitenancymodels.CreateOrUpdateThirdPartyConfigResponse, error)
Third party provider management
func DeleteTenant ¶
func DeleteTenant(tenantId string, userContext ...supertokens.UserContext) (multitenancymodels.DeleteTenantResponse, error)
func DeleteThirdPartyConfig ¶
func DeleteThirdPartyConfig(tenantId string, thirdPartyId string, userContext ...supertokens.UserContext) (multitenancymodels.DeleteThirdPartyConfigResponse, error)
func DisassociateUserFromTenant ¶
func DisassociateUserFromTenant(tenantId string, userId string, userContext ...supertokens.UserContext) (multitenancymodels.DisassociateUserFromTenantResponse, error)
func GetTenant ¶
func GetTenant(tenantId string, userContext ...supertokens.UserContext) (*multitenancymodels.Tenant, error)
func Init ¶
func Init(config *multitenancymodels.TypeInput) supertokens.Recipe
func ListAllTenants ¶
func ListAllTenants(userContext ...supertokens.UserContext) (multitenancymodels.ListAllTenantsResponse, error)
func NewAllowedDomainsClaim ¶
func NewAllowedDomainsClaim() (*claims.TypeSessionClaim, claims.PrimitiveArrayClaimValidators)
func ResetForTest ¶
func ResetForTest()
Types ¶
type Recipe ¶
type Recipe struct { RecipeModule supertokens.RecipeModule Config multitenancymodels.TypeNormalisedInput RecipeImpl multitenancymodels.RecipeInterface APIImpl multitenancymodels.APIInterface GetAllowedDomainsForTenantId func(tenantId string, userContext supertokens.UserContext) ([]string, error) // contains filtered or unexported fields }
func GetRecipeInstance ¶
func GetRecipeInstance() *Recipe
func MakeRecipe ¶
func MakeRecipe(recipeId string, appInfo supertokens.NormalisedAppinfo, config *multitenancymodels.TypeInput, onSuperTokensAPIError func(err error, req *http.Request, res http.ResponseWriter)) (*Recipe, error)
func (*Recipe) SetStaticThirdPartyProviders ¶
func (r *Recipe) SetStaticThirdPartyProviders(providers []tpmodels.ProviderInput)
Source Files ¶
Click to show internal directories.
Click to hide internal directories.