graphql

package
v0.1.0-alpha.6 Latest Latest
Warning

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

Go to latest
Published: Jun 28, 2022 License: MIT Imports: 35 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

Functions

func AuthEmailExtendToken

func AuthEmailExtendToken(ctx context.Context, token string) (string, error)

AuthEmailExtendToken takes the current auth token and returns a new token if current token is valid @graphql authEmailToken Mutation @graphqlreturn token

func AuthEmailLogout

func AuthEmailLogout(ctx context.Context)

AuthEmailLogout logs the user out. @graphql authSignoutEmail Mutation TODO (developer): rename if you don't have conflicts?

func AuthEmailPassword

func AuthEmailPassword(ctx context.Context, email, password string) (string, error)

AuthEmailPassword takes an email and password and logs the user in if valid @graphql authEmailPassword Mutation @graphqlreturn token

func AuthPhoneExtendToken

func AuthPhoneExtendToken(ctx context.Context, token string) (string, error)

AuthPhoneExtendToken takes the current auth token and returns a new token if current token is valid @graphql authPhoneToken Mutation @graphqlreturn token

func AuthPhoneLogout

func AuthPhoneLogout(ctx context.Context)

AuthPhoneLogout logs the user out. @graphql authSignout Mutation TODO (developer): rename if you don't have conflicts?

func AuthPhoneNumber

func AuthPhoneNumber(ctx context.Context, phoneNumber, pin string) (string, error)

AuthPhoneNumber takes a phone number and pin and logs the user in if valid @graphql authPhoneNumber Mutation @graphqlreturn token

func CheckCanSigninWithEmailAddress

func CheckCanSigninWithEmailAddress(ctx context.Context, emailAddress string) (bool, error)

CheckCanSigninWithEmailAddress returns a boolean indicating if emailAddress is available TODO (developer): may make sense to remove this if you don't want to expose an API method that can be easily hit to check this without rate limits (or add rate limiting) @graphql authCheckAvailableEmailAddress Mutation @graphqlreturn available

func CheckCanSigninWithPhoneNumber

func CheckCanSigninWithPhoneNumber(ctx context.Context, phoneNumber string) (bool, error)

CheckCanSigninWithPhoneNumber returns a boolean indicating if phoneNumber is available TODO (developer): may make sense to remove this if you don't want to expose an API method that can be easily hit to check this without rate limits (or add rate limiting) @graphql authCheckAvailablePhoneNumber Mutation @graphqlreturn available

func NewExecutableSchema

func NewExecutableSchema(cfg Config) graphql.ExecutableSchema

NewExecutableSchema creates an ExecutableSchema from the ResolverRoot interface.

func SendSMS

func SendSMS(ctx context.Context, phoneNumber string) (string, error)

SendSMS takes a phone number and pin and "sends an sms" to the user Actually, it just returns the pin now but we'll have twilio, other integrations here later @graphql authSendSMS Mutation @graphqlreturn pin

func ValidAuthCredentials

func ValidAuthCredentials(ctx context.Context, phoneNumber, pin string) (bool, error)

ValidAuthCredentials takes phone number and pin and validates that they are valid for a new user. Does *not* clear the PIN @graphql authValidCredentials Mutation @graphqlreturn available

Types

type AddressCreateInput

type AddressCreateInput struct {
	City          string   `json:"city"`
	Country       string   `json:"country"`
	ResidentNames []string `json:"residentNames"`
	State         string   `json:"state"`
	StreetAddress string   `json:"streetAddress"`
	Zip           string   `json:"zip"`
}

type AddressCreateResponse

type AddressCreateResponse struct {
	Address *models.Address `json:"address"`
}

type AddressDeleteInput

type AddressDeleteInput struct {
	AddressID string `json:"addressID"`
}

type AddressDeleteResponse

type AddressDeleteResponse struct {
	DeletedAddressID *string `json:"deletedAddressId"`
}

type AddressEditInput

type AddressEditInput struct {
	AddressID     string   `json:"addressID"`
	City          string   `json:"city"`
	Country       string   `json:"country"`
	ResidentNames []string `json:"residentNames"`
	State         string   `json:"state"`
	StreetAddress string   `json:"streetAddress"`
	Zip           string   `json:"zip"`
}

type AddressEditResponse

type AddressEditResponse struct {
	Address *models.Address `json:"address"`
}

type AdminBlockInput

type AdminBlockInput struct {
	BlockeeID string `json:"blockeeID"`
	BlockerID string `json:"blockerID"`
}

type AdminBlockResponse

type AdminBlockResponse struct {
	Success *bool `json:"success"`
}

type AuthCheckAvailableEmailAddressInput

type AuthCheckAvailableEmailAddressInput struct {
	EmailAddress string `json:"emailAddress"`
}

type AuthCheckAvailableEmailAddressResponse

type AuthCheckAvailableEmailAddressResponse struct {
	Available bool `json:"available"`
}

type AuthCheckAvailablePhoneNumberInput

type AuthCheckAvailablePhoneNumberInput struct {
	PhoneNumber string `json:"phoneNumber"`
}

type AuthCheckAvailablePhoneNumberResponse

type AuthCheckAvailablePhoneNumberResponse struct {
	Available bool `json:"available"`
}

type AuthEmailPasswordInput

type AuthEmailPasswordInput struct {
	Email    string `json:"email"`
	Password string `json:"password"`
}

type AuthEmailPasswordResponse

type AuthEmailPasswordResponse struct {
	Token string `json:"token"`
}

type AuthEmailTokenInput

type AuthEmailTokenInput struct {
	Token string `json:"token"`
}

type AuthEmailTokenResponse

type AuthEmailTokenResponse struct {
	Token string `json:"token"`
}

type AuthPhoneNumberInput

type AuthPhoneNumberInput struct {
	PhoneNumber string `json:"phoneNumber"`
	Pin         string `json:"pin"`
}

type AuthPhoneNumberResponse

type AuthPhoneNumberResponse struct {
	Token string `json:"token"`
}

type AuthPhoneTokenInput

type AuthPhoneTokenInput struct {
	Token string `json:"token"`
}

type AuthPhoneTokenResponse

type AuthPhoneTokenResponse struct {
	Token string `json:"token"`
}

type AuthSendSMSInput

type AuthSendSMSInput struct {
	PhoneNumber string `json:"phoneNumber"`
}

type AuthSendSMSResponse

type AuthSendSMSResponse struct {
	Pin string `json:"pin"`
}

type AuthSignoutEmailResponse

type AuthSignoutEmailResponse struct {
	Success *bool `json:"success"`
}

type AuthSignoutResponse

type AuthSignoutResponse struct {
	Success *bool `json:"success"`
}

type AuthUserInput

type AuthUserInput struct {
	Email    string `json:"email"`
	Password string `json:"password"`
}

type AuthUserResponse

type AuthUserResponse struct {
	Token string       `json:"token"`
	User  *models.User `json:"user"`
}

type AuthUserResult

type AuthUserResult struct {
	Token string       `json:"token"`
	User  *models.User `json:"user"`
}

type AuthValidCredentialsInput

type AuthValidCredentialsInput struct {
	PhoneNumber string `json:"phoneNumber"`
	Pin         string `json:"pin"`
}

type AuthValidCredentialsResponse

type AuthValidCredentialsResponse struct {
	Available bool `json:"available"`
}

type ComplexityRoot

type ComplexityRoot struct {
	Address struct {
		City          func(childComplexity int) int
		Country       func(childComplexity int) int
		ID            func(childComplexity int) int
		ResidentNames func(childComplexity int) int
		State         func(childComplexity int) int
		StreetAddress func(childComplexity int) int
		Zip           func(childComplexity int) int
	}

	AddressCreateResponse struct {
		Address func(childComplexity int) int
	}

	AddressDeleteResponse struct {
		DeletedAddressID func(childComplexity int) int
	}

	AddressEditResponse struct {
		Address func(childComplexity int) int
	}

	AdminBlockResponse struct {
		Success func(childComplexity int) int
	}

	AuthCheckAvailableEmailAddressResponse struct {
		Available func(childComplexity int) int
	}

	AuthCheckAvailablePhoneNumberResponse struct {
		Available func(childComplexity int) int
	}

	AuthEmailPasswordResponse struct {
		Token func(childComplexity int) int
	}

	AuthEmailTokenResponse struct {
		Token func(childComplexity int) int
	}

	AuthPhoneNumberResponse struct {
		Token func(childComplexity int) int
	}

	AuthPhoneTokenResponse struct {
		Token func(childComplexity int) int
	}

	AuthSendSMSResponse struct {
		Pin func(childComplexity int) int
	}

	AuthSignoutEmailResponse struct {
		Success func(childComplexity int) int
	}

	AuthSignoutResponse struct {
		Success func(childComplexity int) int
	}

	AuthUserResponse struct {
		Token func(childComplexity int) int
		User  func(childComplexity int) int
	}

	AuthUserResult struct {
		Token func(childComplexity int) int
		User  func(childComplexity int) int
	}

	AuthValidCredentialsResponse struct {
		Available func(childComplexity int) int
	}

	Contact struct {
		AllowList     func(childComplexity int) int
		ContactEmails func(childComplexity int) int
		EmailAddress  func(childComplexity int) int
		FirstName     func(childComplexity int) int
		GetContactBar func(childComplexity int, foo int) int
		GetContactFoo func(childComplexity int) int
		ID            func(childComplexity int) int
		LastName      func(childComplexity int) int
		User          func(childComplexity int) int
	}

	ContactCreateResponse struct {
		Contact func(childComplexity int) int
	}

	ContactEmail struct {
		Contact      func(childComplexity int) int
		EmailAddress func(childComplexity int) int
		ID           func(childComplexity int) int
		Label        func(childComplexity int) int
	}

	Event struct {
		Attending        func(childComplexity int) int
		Creator          func(childComplexity int) int
		Declined         func(childComplexity int) int
		EndTime          func(childComplexity int) int
		Hosts            func(childComplexity int) int
		ID               func(childComplexity int) int
		Invited          func(childComplexity int) int
		Location         func(childComplexity int) int
		Name             func(childComplexity int) int
		StartTime        func(childComplexity int) int
		User             func(childComplexity int) int
		ViewerRsvpStatus func(childComplexity int) int
	}

	EventCreateResponse struct {
		Event func(childComplexity int) int
	}

	EventRsvpStatusEditResponse struct {
		Event func(childComplexity int) int
	}

	EventsConnection struct {
		Edges func(childComplexity int) int
		Nodes func(childComplexity int) int
	}

	EventsEdge struct {
		Node func(childComplexity int) int
	}

	LogEvent2Response struct {
		Success func(childComplexity int) int
	}

	LogEventResponse struct {
		Success func(childComplexity int) int
	}

	Mutation struct {
		AddressCreate                  func(childComplexity int, input AddressCreateInput) int
		AddressDelete                  func(childComplexity int, input AddressDeleteInput) int
		AddressEdit                    func(childComplexity int, input AddressEditInput) int
		AdminBlock                     func(childComplexity int, input AdminBlockInput) int
		AuthCheckAvailableEmailAddress func(childComplexity int, input AuthCheckAvailableEmailAddressInput) int
		AuthCheckAvailablePhoneNumber  func(childComplexity int, input AuthCheckAvailablePhoneNumberInput) int
		AuthEmailPassword              func(childComplexity int, input AuthEmailPasswordInput) int
		AuthEmailToken                 func(childComplexity int, input AuthEmailTokenInput) int
		AuthPhoneNumber                func(childComplexity int, input AuthPhoneNumberInput) int
		AuthPhoneToken                 func(childComplexity int, input AuthPhoneTokenInput) int
		AuthSendSms                    func(childComplexity int, input AuthSendSMSInput) int
		AuthSignout                    func(childComplexity int) int
		AuthSignoutEmail               func(childComplexity int) int
		AuthUser                       func(childComplexity int, input AuthUserInput) int
		AuthValidCredentials           func(childComplexity int, input AuthValidCredentialsInput) int
		ContactCreate                  func(childComplexity int, input ContactCreateInput) int
		EventCreate                    func(childComplexity int, input EventCreateInput) int
		EventRsvpStatusEdit            func(childComplexity int, input EventRsvpStatusEditInput) int
		LogEvent                       func(childComplexity int, input LogEventInput) int
		LogEvent2                      func(childComplexity int, input LogEvent2Input) int
		UserAddFamilyMember            func(childComplexity int, input UserAddFamilyMemberInput) int
		UserAddFriend                  func(childComplexity int, input UserAddFriendInput) int
		UserCreate                     func(childComplexity int, input UserCreateInput) int
		UserDelete                     func(childComplexity int, input UserDeleteInput) int
		UserEdit                       func(childComplexity int, input UserEditInput) int
		UserRemoveFamilyMember         func(childComplexity int, input UserRemoveFamilyMemberInput) int
		UserRemoveFriend               func(childComplexity int, input UserRemoveFriendInput) int
		ViewerBlock                    func(childComplexity int, input ViewerBlockInput) int
		ViewerBlockMultiple            func(childComplexity int, input ViewerBlockMultipleInput) int
		ViewerBlockMultipleIDs         func(childComplexity int, input ViewerBlockMultipleIDsInput) int
		ViewerBlockParam               func(childComplexity int, userID string) int
	}

	Query struct {
		Address      func(childComplexity int, id string) int
		AuthUser     func(childComplexity int, email string, password string) int
		Contact      func(childComplexity int, id string) int
		ContactEmail func(childComplexity int, id string) int
		Event        func(childComplexity int, id string) int
		ServerTime   func(childComplexity int) int
		User         func(childComplexity int, id string) int
		Viewer       func(childComplexity int) int
	}

	User struct {
		Baz             func(childComplexity int) int
		Bio             func(childComplexity int) int
		Contacts        func(childComplexity int) int
		DeclinedEvents  func(childComplexity int) int
		EmailAddress    func(childComplexity int) int
		Events          func(childComplexity int) int
		EventsAttending func(childComplexity int) int
		FamilyMembers   func(childComplexity int) int
		FirstName       func(childComplexity int) int
		Friends         func(childComplexity int) int
		GetUserFoo      func(childComplexity int) int
		ID              func(childComplexity int) int
		InvitedEvents   func(childComplexity int) int
		LastName        func(childComplexity int) int
		PhoneNumber     func(childComplexity int) int
	}

	UserAddFamilyMemberResponse struct {
		User func(childComplexity int) int
	}

	UserAddFriendResponse struct {
		User func(childComplexity int) int
	}

	UserCreateResponse struct {
		User func(childComplexity int) int
	}

	UserDeleteResponse struct {
		DeletedUserID func(childComplexity int) int
	}

	UserEditResponse struct {
		User func(childComplexity int) int
	}

	UserRemoveFamilyMemberResponse struct {
		User func(childComplexity int) int
	}

	UserRemoveFriendResponse struct {
		User func(childComplexity int) int
	}

	UsersConnection struct {
		Edges func(childComplexity int) int
		Nodes func(childComplexity int) int
	}

	UsersEdge struct {
		Node func(childComplexity int) int
	}

	Viewer struct {
		GetUser           func(childComplexity int) int
		LoadViewerContact func(childComplexity int) int
	}

	ViewerBlockMultipleIDsResponse struct {
		Viewer func(childComplexity int) int
	}

	ViewerBlockMultipleResponse struct {
		Viewer func(childComplexity int) int
	}

	ViewerBlockParamResponse struct {
		Viewer func(childComplexity int) int
	}

	ViewerBlockResponse struct {
		Viewer func(childComplexity int) int
	}
}

type Config

type Config struct {
	Resolvers  ResolverRoot
	Directives DirectiveRoot
	Complexity ComplexityRoot
}

type Connection

type Connection interface {
	IsConnection()
}

type ContactCreateInput

type ContactCreateInput struct {
	EmailAddress  string   `json:"emailAddress"`
	Favorite      *bool    `json:"favorite"`
	FirstName     string   `json:"firstName"`
	LastName      string   `json:"lastName"`
	NumberOfCalls *int     `json:"numberOfCalls"`
	Pi            *float64 `json:"pi"`
	UserID        string   `json:"userID"`
}

type ContactCreateResponse

type ContactCreateResponse struct {
	Contact *models.Contact `json:"contact"`
}

type ContactEmailResolver

type ContactEmailResolver interface {
	Contact(ctx context.Context, obj *models.ContactEmail) (*models.Contact, error)
}

type ContactResolver

type ContactResolver interface {
	AllowList(ctx context.Context, obj *models.Contact) ([]*models.User, error)

	ContactEmails(ctx context.Context, obj *models.Contact) ([]*models.ContactEmail, error)

	User(ctx context.Context, obj *models.Contact) (*models.User, error)
}

type DirectiveRoot

type DirectiveRoot struct {
}

type Edge

type Edge interface {
	IsEdge()
}

type EventCreateInput

type EventCreateInput struct {
	EndTime   *time.Time `json:"endTime"`
	Location  string     `json:"location"`
	Name      string     `json:"name"`
	StartTime time.Time  `json:"startTime"`
	UserID    string     `json:"userID"`
}

type EventCreateResponse

type EventCreateResponse struct {
	Event *models.Event `json:"event"`
}

type EventResolver

type EventResolver interface {
	Attending(ctx context.Context, obj *models.Event) ([]*models.User, error)
	Creator(ctx context.Context, obj *models.Event) (*models.User, error)
	Declined(ctx context.Context, obj *models.Event) ([]*models.User, error)

	Hosts(ctx context.Context, obj *models.Event) ([]*models.User, error)

	Invited(ctx context.Context, obj *models.Event) ([]*models.User, error)

	User(ctx context.Context, obj *models.Event) (*models.User, error)
	ViewerRsvpStatus(ctx context.Context, obj *models.Event) (*EventRsvpStatus, error)
}

type EventRsvpStatus

type EventRsvpStatus string
const (
	EventRsvpStatusEventAttending EventRsvpStatus = "EVENT_ATTENDING"
	EventRsvpStatusEventDeclined  EventRsvpStatus = "EVENT_DECLINED"
	EventRsvpStatusEventInvited   EventRsvpStatus = "EVENT_INVITED"
	EventRsvpStatusEventUnknown   EventRsvpStatus = "EVENT_UNKNOWN"
)

func (EventRsvpStatus) IsValid

func (e EventRsvpStatus) IsValid() bool

func (EventRsvpStatus) MarshalGQL

func (e EventRsvpStatus) MarshalGQL(w io.Writer)

func (EventRsvpStatus) String

func (e EventRsvpStatus) String() string

func (*EventRsvpStatus) UnmarshalGQL

func (e *EventRsvpStatus) UnmarshalGQL(v interface{}) error

type EventRsvpStatusEditInput

type EventRsvpStatusEditInput struct {
	EventID    string `json:"eventID"`
	RsvpStatus string `json:"rsvpStatus"`
	UserID     string `json:"userID"`
}

type EventRsvpStatusEditResponse

type EventRsvpStatusEditResponse struct {
	Event *models.Event `json:"event"`
}

type EventsConnection

type EventsConnection struct {
	Edges []*EventsEdge   `json:"edges"`
	Nodes []*models.Event `json:"nodes"`
}

func (EventsConnection) IsConnection

func (EventsConnection) IsConnection()

type EventsEdge

type EventsEdge struct {
	Node *models.Event `json:"node"`
}

func (EventsEdge) IsEdge

func (EventsEdge) IsEdge()

type LogEvent2Input

type LogEvent2Input struct {
	Event string `json:"event"`
}

type LogEvent2Response

type LogEvent2Response struct {
	Success *bool `json:"success"`
}

type LogEventInput

type LogEventInput struct {
	Event string `json:"event"`
}

type LogEventResponse

type LogEventResponse struct {
	Success *bool `json:"success"`
}

type MutationResolver

type MutationResolver interface {
	AddressCreate(ctx context.Context, input AddressCreateInput) (*AddressCreateResponse, error)
	AddressDelete(ctx context.Context, input AddressDeleteInput) (*AddressDeleteResponse, error)
	AddressEdit(ctx context.Context, input AddressEditInput) (*AddressEditResponse, error)
	AdminBlock(ctx context.Context, input AdminBlockInput) (*AdminBlockResponse, error)
	AuthCheckAvailableEmailAddress(ctx context.Context, input AuthCheckAvailableEmailAddressInput) (*AuthCheckAvailableEmailAddressResponse, error)
	AuthCheckAvailablePhoneNumber(ctx context.Context, input AuthCheckAvailablePhoneNumberInput) (*AuthCheckAvailablePhoneNumberResponse, error)
	AuthEmailPassword(ctx context.Context, input AuthEmailPasswordInput) (*AuthEmailPasswordResponse, error)
	AuthEmailToken(ctx context.Context, input AuthEmailTokenInput) (*AuthEmailTokenResponse, error)
	AuthPhoneNumber(ctx context.Context, input AuthPhoneNumberInput) (*AuthPhoneNumberResponse, error)
	AuthPhoneToken(ctx context.Context, input AuthPhoneTokenInput) (*AuthPhoneTokenResponse, error)
	AuthSendSms(ctx context.Context, input AuthSendSMSInput) (*AuthSendSMSResponse, error)
	AuthSignout(ctx context.Context) (*AuthSignoutResponse, error)
	AuthSignoutEmail(ctx context.Context) (*AuthSignoutEmailResponse, error)
	AuthUser(ctx context.Context, input AuthUserInput) (*AuthUserResponse, error)
	AuthValidCredentials(ctx context.Context, input AuthValidCredentialsInput) (*AuthValidCredentialsResponse, error)
	ContactCreate(ctx context.Context, input ContactCreateInput) (*ContactCreateResponse, error)
	EventCreate(ctx context.Context, input EventCreateInput) (*EventCreateResponse, error)
	EventRsvpStatusEdit(ctx context.Context, input EventRsvpStatusEditInput) (*EventRsvpStatusEditResponse, error)
	LogEvent(ctx context.Context, input LogEventInput) (*LogEventResponse, error)
	LogEvent2(ctx context.Context, input LogEvent2Input) (*LogEvent2Response, error)
	UserAddFamilyMember(ctx context.Context, input UserAddFamilyMemberInput) (*UserAddFamilyMemberResponse, error)
	UserAddFriend(ctx context.Context, input UserAddFriendInput) (*UserAddFriendResponse, error)
	UserCreate(ctx context.Context, input UserCreateInput) (*UserCreateResponse, error)
	UserDelete(ctx context.Context, input UserDeleteInput) (*UserDeleteResponse, error)
	UserEdit(ctx context.Context, input UserEditInput) (*UserEditResponse, error)
	UserRemoveFamilyMember(ctx context.Context, input UserRemoveFamilyMemberInput) (*UserRemoveFamilyMemberResponse, error)
	UserRemoveFriend(ctx context.Context, input UserRemoveFriendInput) (*UserRemoveFriendResponse, error)
	ViewerBlock(ctx context.Context, input ViewerBlockInput) (*ViewerBlockResponse, error)
	ViewerBlockMultiple(ctx context.Context, input ViewerBlockMultipleInput) (*ViewerBlockMultipleResponse, error)
	ViewerBlockMultipleIDs(ctx context.Context, input ViewerBlockMultipleIDsInput) (*ViewerBlockMultipleIDsResponse, error)
	ViewerBlockParam(ctx context.Context, userID string) (*ViewerBlockParamResponse, error)
}

type QueryResolver

type QueryResolver interface {
	Address(ctx context.Context, id string) (*models.Address, error)
	AuthUser(ctx context.Context, email string, password string) (*AuthUserResult, error)
	Contact(ctx context.Context, id string) (*models.Contact, error)
	ContactEmail(ctx context.Context, id string) (*models.ContactEmail, error)
	Event(ctx context.Context, id string) (*models.Event, error)
	ServerTime(ctx context.Context) (*time.Time, error)
	User(ctx context.Context, id string) (*models.User, error)
	Viewer(ctx context.Context) (*viewer.Viewer, error)
}

type Resolver

type Resolver struct{}

func (*Resolver) Contact

func (r *Resolver) Contact() ContactResolver

func (*Resolver) ContactEmail

func (r *Resolver) ContactEmail() ContactEmailResolver

func (*Resolver) Event

func (r *Resolver) Event() EventResolver

func (*Resolver) Mutation

func (r *Resolver) Mutation() MutationResolver

func (*Resolver) Query

func (r *Resolver) Query() QueryResolver

func (*Resolver) User

func (r *Resolver) User() UserResolver

type ResolverRoot

type ResolverRoot interface {
	Contact() ContactResolver
	ContactEmail() ContactEmailResolver
	Event() EventResolver
	Mutation() MutationResolver
	Query() QueryResolver
	User() UserResolver
}

type UserAddFamilyMemberInput

type UserAddFamilyMemberInput struct {
	FamilyMemberID string `json:"familyMemberID"`
	UserID         string `json:"userID"`
}

type UserAddFamilyMemberResponse

type UserAddFamilyMemberResponse struct {
	User *models.User `json:"user"`
}

type UserAddFriendInput

type UserAddFriendInput struct {
	FriendID string `json:"friendID"`
	UserID   string `json:"userID"`
}

type UserAddFriendResponse

type UserAddFriendResponse struct {
	User *models.User `json:"user"`
}

type UserCreateInput

type UserCreateInput struct {
	Bio          *string `json:"bio"`
	EmailAddress string  `json:"emailAddress"`
	FirstName    string  `json:"firstName"`
	LastName     string  `json:"lastName"`
	Password     string  `json:"password"`
	PhoneNumber  *string `json:"phoneNumber"`
}

type UserCreateResponse

type UserCreateResponse struct {
	User *models.User `json:"user"`
}

type UserDeleteInput

type UserDeleteInput struct {
	UserID string `json:"userID"`
}

type UserDeleteResponse

type UserDeleteResponse struct {
	DeletedUserID *string `json:"deletedUserId"`
}

type UserEditInput

type UserEditInput struct {
	Bio       *string `json:"bio"`
	FirstName string  `json:"firstName"`
	LastName  string  `json:"lastName"`
	UserID    string  `json:"userID"`
}

type UserEditResponse

type UserEditResponse struct {
	User *models.User `json:"user"`
}

type UserRemoveFamilyMemberInput

type UserRemoveFamilyMemberInput struct {
	FamilyMemberID string `json:"familyMemberID"`
	UserID         string `json:"userID"`
}

type UserRemoveFamilyMemberResponse

type UserRemoveFamilyMemberResponse struct {
	User *models.User `json:"user"`
}

type UserRemoveFriendInput

type UserRemoveFriendInput struct {
	FriendID string `json:"friendID"`
	UserID   string `json:"userID"`
}

type UserRemoveFriendResponse

type UserRemoveFriendResponse struct {
	User *models.User `json:"user"`
}

type UserResolver

type UserResolver interface {
	Contacts(ctx context.Context, obj *models.User) ([]*models.Contact, error)
	DeclinedEvents(ctx context.Context, obj *models.User) ([]*models.Event, error)

	Events(ctx context.Context, obj *models.User) ([]*models.Event, error)
	EventsAttending(ctx context.Context, obj *models.User) ([]*models.Event, error)
	FamilyMembers(ctx context.Context, obj *models.User) ([]*models.User, error)

	Friends(ctx context.Context, obj *models.User) ([]*models.User, error)

	InvitedEvents(ctx context.Context, obj *models.User) ([]*models.Event, error)
}

type UsersConnection

type UsersConnection struct {
	Edges []*UsersEdge   `json:"edges"`
	Nodes []*models.User `json:"nodes"`
}

func (UsersConnection) IsConnection

func (UsersConnection) IsConnection()

type UsersEdge

type UsersEdge struct {
	Node *models.User `json:"node"`
}

func (UsersEdge) IsEdge

func (UsersEdge) IsEdge()

type ViewerBlockInput

type ViewerBlockInput struct {
	BlockeeID string `json:"blockeeID"`
}

type ViewerBlockMultipleIDsInput

type ViewerBlockMultipleIDsInput struct {
	UserIDs []string `json:"userIDs"`
}

type ViewerBlockMultipleIDsResponse

type ViewerBlockMultipleIDsResponse struct {
	Viewer *viewer.Viewer `json:"viewer"`
}

type ViewerBlockMultipleInput

type ViewerBlockMultipleInput struct {
	UserIDs []string `json:"userIDs"`
}

type ViewerBlockMultipleResponse

type ViewerBlockMultipleResponse struct {
	Viewer *viewer.Viewer `json:"viewer"`
}

type ViewerBlockParamResponse

type ViewerBlockParamResponse struct {
	Viewer *viewer.Viewer `json:"viewer"`
}

type ViewerBlockResponse

type ViewerBlockResponse struct {
	Viewer *viewer.Viewer `json:"viewer"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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