responses

package
v0.0.0-...-f6cc6f7 Latest Latest
Warning

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

Go to latest
Published: Dec 26, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ComposeOAuth2Google

func ComposeOAuth2Google(url string) *resources.OAuth2Google200Response

func ComposePostHeaderListResponse

func ComposePostHeaderListResponse(
	headers []data.PostHeader,
	r *http.Request,
) (*resources.GetConfirmedPostsHeaders200Response, error)

func ComposePostsAmount

func ComposePostsAmount(amount int64) *resources.GetPostsAmount200Response

func ComposeStarredPostHeaderListResponse

func ComposeStarredPostHeaderListResponse(
	headers []data.PostHeader,
	usersQ data.Users,
) (*resources.GetConfirmedPostsHeaders200Response, error)

func ConvertToAuthTokenResource

func ConvertToAuthTokenResource(access string, expiresAt int64) *resources.AuthToken

Types

type AuthTokenResponse

type AuthTokenResponse struct {
	Data resources.AuthToken `json:"data"`
}

func ComposeAuthToken

func ComposeAuthToken(authToken *resources.AuthToken) *AuthTokenResponse

type EmailResponse

type EmailResponse struct {
	Data resources.Email `json:"data"`
}

func ComposeEmail

func ComposeEmail(email string) *EmailResponse

type PostKeyResponse

type PostKeyResponse struct {
	Data resources.PostKey `json:"data"`
}

func ComposePostKey

func ComposePostKey(postID int64) *PostKeyResponse

type PostWithUserResponse

type PostWithUserResponse struct {
	Data     resources.Post                               `json:"data"`
	Included resources.CreatePost201ResponseIncludedInner `json:"included"`
}

func ComposePostWithUser

func ComposePostWithUser(post *data.Post, user *data.User, starred bool) *PostWithUserResponse

type UserResponse

type UserResponse struct {
	Data resources.User `json:"data"`
}

func ComposeUser

func ComposeUser(user *data.User) *UserResponse

type UserWithAuthTokenResponse

type UserWithAuthTokenResponse struct {
	Data     resources.User                          `json:"data"`
	Included resources.Login200ResponseIncludedInner `json:"included"`
}

func ComposeUserWithAuthToken

func ComposeUserWithAuthToken(user *data.User, authToken *resources.AuthToken) *UserWithAuthTokenResponse

Jump to

Keyboard shortcuts

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