internalapi

package
v0.1.26 Latest Latest
Warning

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

Go to latest
Published: Jun 26, 2026 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var InternalAPIRouteSpecs = []RouteContractSpec{
	{Method: http.MethodGet, Path: "/auth/internal/v1/capabilities", Errors: CapabilitiesGetErrors},
	{Method: http.MethodPost, Path: "/auth/internal/v1/organizations", Errors: CreateOrganizationErrors},
	{Method: http.MethodGet, Path: "/auth/internal/v1/organizations/{organizationID}", Errors: OrganizationErrors},
	{Method: http.MethodPatch, Path: "/auth/internal/v1/organizations/{organizationID}", Errors: OrganizationErrors},
	{Method: http.MethodGet, Path: "/auth/internal/v1/organizations/{organizationID}/members", Errors: OrganizationMembersGetErrors},
	{Method: http.MethodGet, Path: "/auth/internal/v1/organizations/{organizationID}/members/{userID}", Errors: OrganizationMemberErrors},
	{Method: http.MethodGet, Path: "/auth/internal/v1/organizations/{organizationID}/invitations", Errors: OrganizationInvitationsGetErrors},
	{Method: http.MethodPost, Path: "/auth/internal/v1/organizations/{organizationID}/invitations", Errors: CreateOrganizationInvitationErrors},
	{Method: http.MethodGet, Path: "/auth/internal/v1/organizations/{organizationID}/invitations/{invitationID}", Errors: OrganizationInvitationGetErrors},
	{Method: http.MethodPost, Path: "/auth/internal/v1/organizations/{organizationID}/invitations/{invitationID}/revoke", Errors: RevokeOrganizationInvitationErrors},
	{Method: http.MethodPost, Path: "/auth/internal/v1/organizations/{organizationID}/invitations/{invitationID}/resend", Errors: ResendOrganizationInvitationErrors},
	{Method: http.MethodGet, Path: "/auth/internal/v1/users/{userID}/memberships", Errors: UserMembershipsGetErrors},
}

Functions

This section is empty.

Types

type Handler

type Handler struct {
	Organizations *organization.Service
}

func New

func New(organizations *organization.Service) *Handler

func (*Handler) CapabilitiesGet

func (h *Handler) CapabilitiesGet(w http.ResponseWriter, r *http.Request)

func (*Handler) CreateOrganization

func (h *Handler) CreateOrganization(w http.ResponseWriter, r *http.Request)

func (*Handler) CreateOrganizationInvitation

func (h *Handler) CreateOrganizationInvitation(w http.ResponseWriter, r *http.Request)

func (*Handler) GetOrganization

func (h *Handler) GetOrganization(w http.ResponseWriter, r *http.Request)

func (*Handler) GetOrganizationInvitation

func (h *Handler) GetOrganizationInvitation(w http.ResponseWriter, r *http.Request)

func (*Handler) GetOrganizationMember

func (h *Handler) GetOrganizationMember(w http.ResponseWriter, r *http.Request)

func (*Handler) ListOrganizationInvitations

func (h *Handler) ListOrganizationInvitations(w http.ResponseWriter, r *http.Request)

func (*Handler) ListOrganizationMembers

func (h *Handler) ListOrganizationMembers(w http.ResponseWriter, r *http.Request)

func (*Handler) ListUserMemberships

func (h *Handler) ListUserMemberships(w http.ResponseWriter, r *http.Request)

func (*Handler) ResendOrganizationInvitation added in v0.1.26

func (h *Handler) ResendOrganizationInvitation(w http.ResponseWriter, r *http.Request)

func (*Handler) RevokeOrganizationInvitation

func (h *Handler) RevokeOrganizationInvitation(w http.ResponseWriter, r *http.Request)

func (*Handler) UpdateOrganization

func (h *Handler) UpdateOrganization(w http.ResponseWriter, r *http.Request)

type RouteContractSpec

type RouteContractSpec struct {
	Method string
	Path   string
	Errors map[response.ErrorCode]response.ErrorSpec
}

Jump to

Keyboard shortcuts

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