Documentation
¶
Overview ¶
Package intraoapi42 provides primitives to interact with the openapi HTTP API.
Code generated by github.com/oapi-codegen/oapi-codegen/v2 version v2.8.0 DO NOT EDIT.
Index ¶
- Variables
- func FetchAll[T any, P any, R HasJSON200Slice[T]](ctx context.Context, ...) ([]T, error)
- func FetchAllConcurrent[T any, P any, R HasJSON200Slice[T]](ctx context.Context, ...) ([]T, error)
- func NewGetCloseByIdRequest(server string, id int) (*http.Request, error)
- func NewGetClosesByUserIdRequest(server string, userId int, params *GetClosesByUserIdParams) (*http.Request, error)
- func NewGetClosesRequest(server string, params *GetClosesParams) (*http.Request, error)
- func NewGetInternshipsRequest(server string, params *GetInternshipsParams) (*http.Request, error)
- func NewGetLanguageByIdRequest(server string, id int) (*http.Request, error)
- func NewGetUserByIdRequest(server string, id string) (*http.Request, error)
- func NewGetUserCandidatureByIdRequest(server string, id string) (*http.Request, error)
- func NewGetUsersRequest(server string, params *GetUsersParams) (*http.Request, error)
- type AchievementResponse
- type CampusResponse
- type CampusUserResponse
- type Client
- func (c *Client) GetCloseById(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetCloses(ctx context.Context, params *GetClosesParams, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetClosesByUserId(ctx context.Context, userId int, params *GetClosesByUserIdParams, ...) (*http.Response, error)
- func (c *Client) GetInternships(ctx context.Context, params *GetInternshipsParams, ...) (*http.Response, error)
- func (c *Client) GetLanguageById(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetUserById(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetUserCandidatureById(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*http.Response, error)
- func (c *Client) GetUsers(ctx context.Context, params *GetUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error)
- type ClientInterface
- type ClientOption
- type ClientWithResponses
- func (c *ClientWithResponses) GetCloseByIdWithResponse(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*GetCloseByIdResponse, error)
- func (c *ClientWithResponses) GetClosesByUserIdWithResponse(ctx context.Context, userId int, params *GetClosesByUserIdParams, ...) (*GetClosesByUserIdResponse, error)
- func (c *ClientWithResponses) GetClosesWithResponse(ctx context.Context, params *GetClosesParams, reqEditors ...RequestEditorFn) (*GetClosesResponse, error)
- func (c *ClientWithResponses) GetInternshipsWithResponse(ctx context.Context, params *GetInternshipsParams, ...) (*GetInternshipsResponse, error)
- func (c *ClientWithResponses) GetLanguageByIdWithResponse(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*GetLanguageByIdResponse, error)
- func (c *ClientWithResponses) GetUserByIdWithResponse(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*GetUserByIdResponse, error)
- func (c *ClientWithResponses) GetUserCandidatureByIdWithResponse(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*GetUserCandidatureByIdResponse, error)
- func (c *ClientWithResponses) GetUsersWithResponse(ctx context.Context, params *GetUsersParams, reqEditors ...RequestEditorFn) (*GetUsersResponse, error)
- type ClientWithResponsesInterface
- type CloseResponse
- type CloseResponseKind
- type CommunityServiceResponse
- type Config
- type CursusResponse
- type CursusUserResponse
- type Error
- type ErrorResponse
- type GetCloseByIdResponse
- func (r GetCloseByIdResponse) ContentType() string
- func (r GetCloseByIdResponse) GetBody() []byte
- func (r GetCloseByIdResponse) GetJSON200() *CloseResponse
- func (r GetCloseByIdResponse) GetJSONDefault() *ErrorResponse
- func (r GetCloseByIdResponse) Status() string
- func (r GetCloseByIdResponse) StatusCode() int
- type GetClosesByUserIdParams
- type GetClosesByUserIdParamsSort
- type GetClosesByUserIdResponse
- func (r GetClosesByUserIdResponse) ContentType() string
- func (r GetClosesByUserIdResponse) GetBody() []byte
- func (r GetClosesByUserIdResponse) GetJSON200() *[]CloseResponse
- func (r GetClosesByUserIdResponse) GetJSONDefault() *ErrorResponse
- func (r GetClosesByUserIdResponse) Status() string
- func (r GetClosesByUserIdResponse) StatusCode() int
- type GetClosesParams
- type GetClosesParamsSort
- type GetClosesResponse
- type GetInternshipsParams
- type GetInternshipsResponse
- func (r GetInternshipsResponse) ContentType() string
- func (r GetInternshipsResponse) GetBody() []byte
- func (r GetInternshipsResponse) GetJSON200() *[]InternshipResponse
- func (r GetInternshipsResponse) GetJSONDefault() *ErrorResponse
- func (r GetInternshipsResponse) Status() string
- func (r GetInternshipsResponse) StatusCode() int
- type GetInternshipsResponse200Headers
- type GetLanguageByIdResponse
- func (r GetLanguageByIdResponse) ContentType() string
- func (r GetLanguageByIdResponse) GetBody() []byte
- func (r GetLanguageByIdResponse) GetJSON200() *LanguageResponse
- func (r GetLanguageByIdResponse) GetJSONDefault() *ErrorResponse
- func (r GetLanguageByIdResponse) Status() string
- func (r GetLanguageByIdResponse) StatusCode() int
- type GetUserByIdResponse
- func (r GetUserByIdResponse) ContentType() string
- func (r GetUserByIdResponse) GetBody() []byte
- func (r GetUserByIdResponse) GetJSON200() *UserResponse
- func (r GetUserByIdResponse) GetJSONDefault() *ErrorResponse
- func (r GetUserByIdResponse) Status() string
- func (r GetUserByIdResponse) StatusCode() int
- type GetUserCandidatureByIdResponse
- func (r GetUserCandidatureByIdResponse) ContentType() string
- func (r GetUserCandidatureByIdResponse) GetBody() []byte
- func (r GetUserCandidatureByIdResponse) GetJSON200() *UserCandidatureResponse
- func (r GetUserCandidatureByIdResponse) GetJSONDefault() *ErrorResponse
- func (r GetUserCandidatureByIdResponse) Status() string
- func (r GetUserCandidatureByIdResponse) StatusCode() int
- type GetUsersParams
- type GetUsersResponse
- type GetUsersResponse200Headers
- type GroupResponse
- type HasJSON200Slice
- type HasJSONDefault
- type HttpRequestDoer
- type InternshipResponse
- type InternshipResponseSalary0
- type InternshipResponseSalary1
- type InternshipResponse_Salary
- func (t InternshipResponse_Salary) AsInternshipResponseSalary0() (InternshipResponseSalary0, error)
- func (t InternshipResponse_Salary) AsInternshipResponseSalary1() (InternshipResponseSalary1, error)
- func (t *InternshipResponse_Salary) FromInternshipResponseSalary0(v InternshipResponseSalary0) error
- func (t *InternshipResponse_Salary) FromInternshipResponseSalary1(v InternshipResponseSalary1) error
- func (t InternshipResponse_Salary) MarshalJSON() ([]byte, error)
- func (t *InternshipResponse_Salary) MergeInternshipResponseSalary0(v InternshipResponseSalary0) error
- func (t *InternshipResponse_Salary) MergeInternshipResponseSalary1(v InternshipResponseSalary1) error
- func (t *InternshipResponse_Salary) UnmarshalJSON(b []byte) error
- type IntraDateTime
- type IntraTime
- type LanguageResponse
- type LanguageUserResponse
- type LightUserResponse
- type LightUserResponseKind
- type Page
- type PageNumber
- type PageSize
- type PatronageResponse
- type PerPage
- type ProjectLightResponse
- type ProjectUserResponse
- type RequestEditorFn
- type RoleResponse
- type SkillResponse
- type TitleResponse
- type TitleUserResponse
- type UserCandidatureResponse
- type UserCandidatureResponseGender
- type UserImageResponse
- type UserResponse
- type UserResponseKind
Constants ¶
This section is empty.
Variables ¶
var ProductionConfig = Config{ Config: clientcredentials.Config{ TokenURL: "https://api.intra.42.fr/oauth/token", }, ServerURL: "https://api.intra.42.fr/v2", }
var StagingConfig = Config{ Config: clientcredentials.Config{ TokenURL: "https://api.intra-staging.42.fr/oauth/token", }, ServerURL: "https://api.intra-staging.42.fr/v2", }
Functions ¶
func FetchAllConcurrent ¶
func NewGetCloseByIdRequest ¶
NewGetCloseByIdRequest constructs an http.Request for the GetCloseById method
func NewGetClosesByUserIdRequest ¶
func NewGetClosesByUserIdRequest(server string, userId int, params *GetClosesByUserIdParams) (*http.Request, error)
NewGetClosesByUserIdRequest constructs an http.Request for the GetClosesByUserId method
func NewGetClosesRequest ¶
func NewGetClosesRequest(server string, params *GetClosesParams) (*http.Request, error)
NewGetClosesRequest constructs an http.Request for the GetCloses method
func NewGetInternshipsRequest ¶
func NewGetInternshipsRequest(server string, params *GetInternshipsParams) (*http.Request, error)
NewGetInternshipsRequest constructs an http.Request for the GetInternships method
func NewGetLanguageByIdRequest ¶
NewGetLanguageByIdRequest constructs an http.Request for the GetLanguageById method
func NewGetUserByIdRequest ¶
NewGetUserByIdRequest constructs an http.Request for the GetUserById method
func NewGetUserCandidatureByIdRequest ¶
NewGetUserCandidatureByIdRequest constructs an http.Request for the GetUserCandidatureById method
func NewGetUsersRequest ¶
func NewGetUsersRequest(server string, params *GetUsersParams) (*http.Request, error)
NewGetUsersRequest constructs an http.Request for the GetUsers method
Types ¶
type AchievementResponse ¶
type AchievementResponse struct {
Description string `json:"description"`
Id int `json:"id"`
Image string `json:"image"`
Kind string `json:"kind"`
Name string `json:"name"`
NbrOfSuccess *int `json:"nbr_of_success,omitempty"`
Tier string `json:"tier"`
UsersUrl string `json:"users_url"`
Visible bool `json:"visible"`
}
AchievementResponse defines model for AchievementResponse.
type CampusResponse ¶
type CampusResponse struct {
Active bool `json:"active"`
Address *string `json:"address,omitempty"`
City string `json:"city"`
Country string `json:"country"`
DefaultHiddenPhone *bool `json:"default_hidden_phone,omitempty"`
EmailExtension string `json:"email_extension"`
Facebook *string `json:"facebook,omitempty"`
Id int `json:"id"`
Language *LanguageResponse `json:"language,omitempty"`
Name string `json:"name"`
Public bool `json:"public"`
TimeZone string `json:"time_zone"`
Twitter *string `json:"twitter,omitempty"`
UsersCount int `json:"users_count"`
VogsphereId int `json:"vogsphere_id"`
Website *string `json:"website,omitempty"`
Zip *string `json:"zip,omitempty"`
}
CampusResponse defines model for CampusResponse.
type CampusUserResponse ¶
type CampusUserResponse struct {
CampusId int `json:"campus_id"`
CreatedAt time.Time `json:"created_at"`
Id int `json:"id"`
IsPrimary bool `json:"is_primary"`
UpdatedAt time.Time `json:"updated_at"`
UserId int `json:"user_id"`
}
CampusUserResponse defines model for CampusUserResponse.
type Client ¶
type Client struct {
// The endpoint of the server conforming to this interface, with scheme,
// https://api.deepmap.com for example. This can contain a path relative
// to the server, such as https://api.deepmap.com/dev-test, and all the
// paths in the swagger spec will be appended to the server.
Server string
// Doer for performing requests, typically a *http.Client with any
// customized settings, such as certificate chains.
Client HttpRequestDoer
// A list of callbacks for modifying requests which are generated before sending over
// the network.
RequestEditors []RequestEditorFn
}
Client which conforms to the OpenAPI3 specification for this service.
func NewClient ¶
func NewClient(server string, opts ...ClientOption) (*Client, error)
Creates a new Client, with reasonable defaults
func (*Client) GetCloseById ¶
func (c *Client) GetCloseById(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*http.Response, error)
GetCloseById Get a close by ID
Corresponds with GET /closes/{id} (the `GetCloseById` operationId).
func (*Client) GetCloses ¶
func (c *Client) GetCloses(ctx context.Context, params *GetClosesParams, reqEditors ...RequestEditorFn) (*http.Response, error)
GetCloses Get a list of closes
Corresponds with GET /closes (the `GetCloses` operationId).
func (*Client) GetClosesByUserId ¶
func (c *Client) GetClosesByUserId(ctx context.Context, userId int, params *GetClosesByUserIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)
GetClosesByUserId Get a list of closes by user id
Corresponds with GET /users/{user_id}/closes (the `GetClosesByUserId` operationId).
func (*Client) GetInternships ¶
func (c *Client) GetInternships(ctx context.Context, params *GetInternshipsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
GetInternships Get a list of internships
Corresponds with GET /internships (the `GetInternships` operationId).
func (*Client) GetLanguageById ¶
func (c *Client) GetLanguageById(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*http.Response, error)
GetLanguageById Get a language by ID
Corresponds with GET /languages/{id} (the `GetLanguageById` operationId).
func (*Client) GetUserById ¶
func (c *Client) GetUserById(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*http.Response, error)
GetUserById Get a user by ID
Corresponds with GET /users/{id} (the `GetUserById` operationId).
func (*Client) GetUserCandidatureById ¶
func (c *Client) GetUserCandidatureById(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*http.Response, error)
GetUserCandidatureById Get user candidature information
Corresponds with GET /users/{id}/user_candidature (the `GetUserCandidatureById` operationId).
func (*Client) GetUsers ¶
func (c *Client) GetUsers(ctx context.Context, params *GetUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error)
GetUsers Get a list of users
Corresponds with GET /users (the `GetUsers` operationId).
type ClientInterface ¶
type ClientInterface interface {
// GetCloses Get a list of closes
//
// Corresponds with GET /closes (the `GetCloses` operationId).
GetCloses(ctx context.Context, params *GetClosesParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetCloseById Get a close by ID
//
// Corresponds with GET /closes/{id} (the `GetCloseById` operationId).
GetCloseById(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetInternships Get a list of internships
//
// Corresponds with GET /internships (the `GetInternships` operationId).
GetInternships(ctx context.Context, params *GetInternshipsParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetLanguageById Get a language by ID
//
// Corresponds with GET /languages/{id} (the `GetLanguageById` operationId).
GetLanguageById(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetUsers Get a list of users
//
// Corresponds with GET /users (the `GetUsers` operationId).
GetUsers(ctx context.Context, params *GetUsersParams, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetUserById Get a user by ID
//
// Corresponds with GET /users/{id} (the `GetUserById` operationId).
GetUserById(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetUserCandidatureById Get user candidature information
//
// Corresponds with GET /users/{id}/user_candidature (the `GetUserCandidatureById` operationId).
GetUserCandidatureById(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*http.Response, error)
// GetClosesByUserId Get a list of closes by user id
//
// Corresponds with GET /users/{user_id}/closes (the `GetClosesByUserId` operationId).
GetClosesByUserId(ctx context.Context, userId int, params *GetClosesByUserIdParams, reqEditors ...RequestEditorFn) (*http.Response, error)
}
The interface specification for the client above.
type ClientOption ¶
ClientOption allows setting custom parameters during construction
func WithHTTPClient ¶
func WithHTTPClient(doer HttpRequestDoer) ClientOption
WithHTTPClient allows overriding the default Doer, which is automatically created using http.Client. This is useful for tests.
func WithRequestEditorFn ¶
func WithRequestEditorFn(fn RequestEditorFn) ClientOption
WithRequestEditorFn allows setting up a callback function, which will be called right before sending the request. This can be used to mutate the request.
type ClientWithResponses ¶
type ClientWithResponses struct {
ClientInterface
}
ClientWithResponses builds on ClientInterface to offer response payloads
func New ¶
func New(config Config) (*ClientWithResponses, error)
func NewClientWithResponses ¶
func NewClientWithResponses(server string, opts ...ClientOption) (*ClientWithResponses, error)
NewClientWithResponses creates a new ClientWithResponses, which wraps Client with return type handling
func (*ClientWithResponses) GetCloseByIdWithResponse ¶
func (c *ClientWithResponses) GetCloseByIdWithResponse(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*GetCloseByIdResponse, error)
GetCloseByIdWithResponse Get a close by ID
Returns a wrapper object for the known response body format(s).
Corresponds with GET /closes/{id} (the `GetCloseById` operationId).
func (*ClientWithResponses) GetClosesByUserIdWithResponse ¶
func (c *ClientWithResponses) GetClosesByUserIdWithResponse(ctx context.Context, userId int, params *GetClosesByUserIdParams, reqEditors ...RequestEditorFn) (*GetClosesByUserIdResponse, error)
GetClosesByUserIdWithResponse Get a list of closes by user id
Returns a wrapper object for the known response body format(s).
Corresponds with GET /users/{user_id}/closes (the `GetClosesByUserId` operationId).
func (*ClientWithResponses) GetClosesWithResponse ¶
func (c *ClientWithResponses) GetClosesWithResponse(ctx context.Context, params *GetClosesParams, reqEditors ...RequestEditorFn) (*GetClosesResponse, error)
GetClosesWithResponse Get a list of closes
Returns a wrapper object for the known response body format(s).
Corresponds with GET /closes (the `GetCloses` operationId).
func (*ClientWithResponses) GetInternshipsWithResponse ¶
func (c *ClientWithResponses) GetInternshipsWithResponse(ctx context.Context, params *GetInternshipsParams, reqEditors ...RequestEditorFn) (*GetInternshipsResponse, error)
GetInternshipsWithResponse Get a list of internships
Returns a wrapper object for the known response body format(s).
Corresponds with GET /internships (the `GetInternships` operationId).
func (*ClientWithResponses) GetLanguageByIdWithResponse ¶
func (c *ClientWithResponses) GetLanguageByIdWithResponse(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*GetLanguageByIdResponse, error)
GetLanguageByIdWithResponse Get a language by ID
Returns a wrapper object for the known response body format(s).
Corresponds with GET /languages/{id} (the `GetLanguageById` operationId).
func (*ClientWithResponses) GetUserByIdWithResponse ¶
func (c *ClientWithResponses) GetUserByIdWithResponse(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*GetUserByIdResponse, error)
GetUserByIdWithResponse Get a user by ID
Returns a wrapper object for the known response body format(s).
Corresponds with GET /users/{id} (the `GetUserById` operationId).
func (*ClientWithResponses) GetUserCandidatureByIdWithResponse ¶
func (c *ClientWithResponses) GetUserCandidatureByIdWithResponse(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*GetUserCandidatureByIdResponse, error)
GetUserCandidatureByIdWithResponse Get user candidature information
Returns a wrapper object for the known response body format(s).
Corresponds with GET /users/{id}/user_candidature (the `GetUserCandidatureById` operationId).
func (*ClientWithResponses) GetUsersWithResponse ¶
func (c *ClientWithResponses) GetUsersWithResponse(ctx context.Context, params *GetUsersParams, reqEditors ...RequestEditorFn) (*GetUsersResponse, error)
GetUsersWithResponse Get a list of users
Returns a wrapper object for the known response body format(s).
Corresponds with GET /users (the `GetUsers` operationId).
type ClientWithResponsesInterface ¶
type ClientWithResponsesInterface interface {
// GetClosesWithResponse Get a list of closes
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /closes (the `GetCloses` operationId).
GetClosesWithResponse(ctx context.Context, params *GetClosesParams, reqEditors ...RequestEditorFn) (*GetClosesResponse, error)
// GetCloseByIdWithResponse Get a close by ID
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /closes/{id} (the `GetCloseById` operationId).
GetCloseByIdWithResponse(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*GetCloseByIdResponse, error)
// GetInternshipsWithResponse Get a list of internships
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /internships (the `GetInternships` operationId).
GetInternshipsWithResponse(ctx context.Context, params *GetInternshipsParams, reqEditors ...RequestEditorFn) (*GetInternshipsResponse, error)
// GetLanguageByIdWithResponse Get a language by ID
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /languages/{id} (the `GetLanguageById` operationId).
GetLanguageByIdWithResponse(ctx context.Context, id int, reqEditors ...RequestEditorFn) (*GetLanguageByIdResponse, error)
// GetUsersWithResponse Get a list of users
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /users (the `GetUsers` operationId).
GetUsersWithResponse(ctx context.Context, params *GetUsersParams, reqEditors ...RequestEditorFn) (*GetUsersResponse, error)
// GetUserByIdWithResponse Get a user by ID
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /users/{id} (the `GetUserById` operationId).
GetUserByIdWithResponse(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*GetUserByIdResponse, error)
// GetUserCandidatureByIdWithResponse Get user candidature information
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /users/{id}/user_candidature (the `GetUserCandidatureById` operationId).
GetUserCandidatureByIdWithResponse(ctx context.Context, id string, reqEditors ...RequestEditorFn) (*GetUserCandidatureByIdResponse, error)
// GetClosesByUserIdWithResponse Get a list of closes by user id
//
// Returns a wrapper object for the known response body format(s).
//
// Corresponds with GET /users/{user_id}/closes (the `GetClosesByUserId` operationId).
GetClosesByUserIdWithResponse(ctx context.Context, userId int, params *GetClosesByUserIdParams, reqEditors ...RequestEditorFn) (*GetClosesByUserIdResponse, error)
}
ClientWithResponsesInterface is the interface specification for the client with responses above.
type CloseResponse ¶
type CloseResponse struct {
// Closer Example: {"active":true,"alumni?":false,"alumnized_at":null,"anonymize_date":"2025-10-24T00:00:00.000+02:00","correction_point":4,"created_at":"2018-07-17T08:57:33.128Z","data_erasure_date":"2025-10-24T00:00:00.000+02:00","displayname":"Malo Allain","email":"malallai@student.42.fr","first_name":"Malo","id":39962,"image":{"link":"https://cdn.intra.42.fr/users/39a641ed152b654cfbff5c5864eb05c1/malallai.jpg","versions":{"large":"https://cdn.intra.42.fr/users/a818d7a54298d333411557d0b55b61b3/large_malallai.jpg","medium":"https://cdn.intra.42.fr/users/53691acd1e0ea75b782ddbe121c17423/medium_malallai.jpg","micro":"https://cdn.intra.42.fr/users/6f74b46e2016b0e6c41fa05b5952e17c/micro_malallai.jpg","small":"https://cdn.intra.42.fr/users/617de91b59fd7e59ecaf6470a4b37645/small_malallai.jpg"}},"kind":"student","last_name":"Allain","location":null,"login":"malallai","phone":"hidden","pool_month":"august","pool_year":"2018","staff":false,"updated_at":"2022-09-27T18:48:28.207Z","url":"https://api.intra.42.fr/v2/users/malallai","usual_first_name":null,"usual_full_name":"Malo Allain","wallet":290}
Closer LightUserResponse `json:"closer"`
CommunityServices []CommunityServiceResponse `json:"community_services"`
CreatedAt time.Time `json:"created_at"`
EndAt *time.Time `json:"end_at,omitempty"`
Id int `json:"id"`
Kind CloseResponseKind `json:"kind"`
Reason string `json:"reason"`
State string `json:"state"`
UpdatedAt time.Time `json:"updated_at"`
// User Example: {"active":true,"alumni?":false,"alumnized_at":null,"anonymize_date":"2025-10-24T00:00:00.000+02:00","correction_point":4,"created_at":"2018-07-17T08:57:33.128Z","data_erasure_date":"2025-10-24T00:00:00.000+02:00","displayname":"Malo Allain","email":"malallai@student.42.fr","first_name":"Malo","id":39962,"image":{"link":"https://cdn.intra.42.fr/users/39a641ed152b654cfbff5c5864eb05c1/malallai.jpg","versions":{"large":"https://cdn.intra.42.fr/users/a818d7a54298d333411557d0b55b61b3/large_malallai.jpg","medium":"https://cdn.intra.42.fr/users/53691acd1e0ea75b782ddbe121c17423/medium_malallai.jpg","micro":"https://cdn.intra.42.fr/users/6f74b46e2016b0e6c41fa05b5952e17c/micro_malallai.jpg","small":"https://cdn.intra.42.fr/users/617de91b59fd7e59ecaf6470a4b37645/small_malallai.jpg"}},"kind":"student","last_name":"Allain","location":null,"login":"malallai","phone":"hidden","pool_month":"august","pool_year":"2018","staff":false,"updated_at":"2022-09-27T18:48:28.207Z","url":"https://api.intra.42.fr/v2/users/malallai","usual_first_name":null,"usual_full_name":"Malo Allain","wallet":290}
User LightUserResponse `json:"user"`
}
CloseResponse defines model for CloseResponse.
type CloseResponseKind ¶
type CloseResponseKind string
CloseResponseKind defines model for CloseResponse.Kind.
const ( CloseResponseKindAgu CloseResponseKind = "agu" CloseResponseKindBlackHole CloseResponseKind = "black_hole" CloseResponseKindDeserter CloseResponseKind = "deserter" CloseResponseKindNonAdmitted CloseResponseKind = "non_admitted" CloseResponseKindOther CloseResponseKind = "other" CloseResponseKindPaceUnknown CloseResponseKind = "pace_unknown" CloseResponseKindSeriousMisconduct CloseResponseKind = "serious_misconduct" CloseResponseKindSocialSecurity CloseResponseKind = "social_security" )
Defines values for CloseResponseKind.
func (CloseResponseKind) Valid ¶
func (e CloseResponseKind) Valid() bool
Valid indicates whether the value is a known member of the CloseResponseKind enum.
type CommunityServiceResponse ¶
type CommunityServiceResponse struct {
CreatedAt time.Time `json:"created_at"`
Duration int `json:"duration"`
Id int `json:"id"`
Occupation string `json:"occupation"`
ScheduleAt time.Time `json:"schedule_at"`
State string `json:"state"`
UpdatedAt *string `json:"updated_at,omitempty"`
}
CommunityServiceResponse defines model for CommunityServiceResponse.
type Config ¶
type Config struct {
clientcredentials.Config
ServerURL string
}
func (Config) WithClientCredentials ¶
func (Config) WithScopes ¶
type CursusResponse ¶
type CursusResponse struct {
CreatedAt time.Time `json:"created_at"`
Id int `json:"id"`
Kind string `json:"kind"`
Name string `json:"name"`
Slug string `json:"slug"`
}
CursusResponse defines model for CursusResponse.
type CursusUserResponse ¶
type CursusUserResponse struct {
BeginAt time.Time `json:"begin_at"`
BlackholedAt *time.Time `json:"blackholed_at,omitempty"`
CreatedAt time.Time `json:"created_at"`
Cursus CursusResponse `json:"cursus"`
CursusId int `json:"cursus_id"`
EndAt *time.Time `json:"end_at,omitempty"`
Grade string `json:"grade"`
HasCoalition bool `json:"has_coalition"`
Id int `json:"id"`
Level float64 `json:"level"`
Skills []SkillResponse `json:"skills"`
UpdatedAt time.Time `json:"updated_at"`
}
CursusUserResponse defines model for CursusUserResponse.
type Error ¶
type Error struct {
// Error Error message
Error string `json:"error"`
// Status HTTP status code
Status int `json:"status"`
}
Error Example: {"error":"The access token is invalid","status":401}
type ErrorResponse ¶
type ErrorResponse = Error
ErrorResponse Example: {"error":"The access token is invalid","status":401}
type GetCloseByIdResponse ¶
type GetCloseByIdResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *CloseResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
}
func ParseGetCloseByIdResponse ¶
func ParseGetCloseByIdResponse(rsp *http.Response) (*GetCloseByIdResponse, error)
ParseGetCloseByIdResponse parses an HTTP response from a GetCloseByIdWithResponse call
func (GetCloseByIdResponse) ContentType ¶
func (r GetCloseByIdResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetCloseByIdResponse) GetBody ¶
func (r GetCloseByIdResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetCloseByIdResponse) GetJSON200 ¶
func (r GetCloseByIdResponse) GetJSON200() *CloseResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetCloseByIdResponse) GetJSONDefault ¶
func (r GetCloseByIdResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetCloseByIdResponse) Status ¶
func (r GetCloseByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetCloseByIdResponse) StatusCode ¶
func (r GetCloseByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetClosesByUserIdParams ¶
type GetClosesByUserIdParams struct {
// Sort The sort field. Sorted by created_at desc, id desc by default.
// Must be one of: id, user_id, closer_id, reason, state, created_at, updated_at, kind, end_at, jid.
Sort *GetClosesByUserIdParamsSort `form:"sort,omitempty" json:"sort,omitempty"`
// Filter Filtering on one or more fields. Must be one of: id, user_id, closer_id, reason, state, created_at, updated_at, kind, end_at, jid, campus_id, end.
Filter *map[string]string `json:"filter,omitempty"`
// Range Select on a particular range. Must be one of: id, user_id, closer_id, reason, state, created_at, updated_at, kind, end_at, jid.
Range *map[string]string `json:"range,omitempty"`
// Page Page number (1-based). The 42 API paginates index endpoints and defaults to 30 items per page.
// You can also use the `per_page` parameter to set the page size (up to 100 for many endpoints).
Page *Page `form:"page,omitempty" json:"page,omitempty"`
// PerPage Number of items per page. Maximum is generally 100 but some endpoints limit this for technical reasons.
PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"`
// PageNumber Alternate pagination style using `page[number]` (1-based page index). Can be used together with `page[size]`.
PageNumber *PageNumber `form:"page[number],omitempty" json:"page[number],omitempty"`
// PageSize Alternate pagination style to set the page size (maximum depends on endpoint, commonly up to 100).
PageSize *PageSize `form:"page[size],omitempty" json:"page[size],omitempty"`
}
GetClosesByUserIdParams defines parameters for GetClosesByUserId.
type GetClosesByUserIdParamsSort ¶
type GetClosesByUserIdParamsSort string
GetClosesByUserIdParamsSort defines parameters for GetClosesByUserId.
const ( GetClosesByUserIdParamsSortCloserId GetClosesByUserIdParamsSort = "closer_id" GetClosesByUserIdParamsSortCreatedAt GetClosesByUserIdParamsSort = "created_at" GetClosesByUserIdParamsSortEndAt GetClosesByUserIdParamsSort = "end_at" GetClosesByUserIdParamsSortId GetClosesByUserIdParamsSort = "id" GetClosesByUserIdParamsSortJid GetClosesByUserIdParamsSort = "jid" GetClosesByUserIdParamsSortKind GetClosesByUserIdParamsSort = "kind" GetClosesByUserIdParamsSortReason GetClosesByUserIdParamsSort = "reason" GetClosesByUserIdParamsSortState GetClosesByUserIdParamsSort = "state" GetClosesByUserIdParamsSortUpdatedAt GetClosesByUserIdParamsSort = "updated_at" GetClosesByUserIdParamsSortUserId GetClosesByUserIdParamsSort = "user_id" )
Defines values for GetClosesByUserIdParamsSort.
func (GetClosesByUserIdParamsSort) Valid ¶
func (e GetClosesByUserIdParamsSort) Valid() bool
Valid indicates whether the value is a known member of the GetClosesByUserIdParamsSort enum.
type GetClosesByUserIdResponse ¶
type GetClosesByUserIdResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *[]CloseResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
}
func ParseGetClosesByUserIdResponse ¶
func ParseGetClosesByUserIdResponse(rsp *http.Response) (*GetClosesByUserIdResponse, error)
ParseGetClosesByUserIdResponse parses an HTTP response from a GetClosesByUserIdWithResponse call
func (GetClosesByUserIdResponse) ContentType ¶
func (r GetClosesByUserIdResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetClosesByUserIdResponse) GetBody ¶
func (r GetClosesByUserIdResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetClosesByUserIdResponse) GetJSON200 ¶
func (r GetClosesByUserIdResponse) GetJSON200() *[]CloseResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetClosesByUserIdResponse) GetJSONDefault ¶
func (r GetClosesByUserIdResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetClosesByUserIdResponse) Status ¶
func (r GetClosesByUserIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetClosesByUserIdResponse) StatusCode ¶
func (r GetClosesByUserIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetClosesParams ¶
type GetClosesParams struct {
// Sort The sort field. Sorted by created_at desc, id desc by default.
// Must be one of: id, user_id, closer_id, reason, state, created_at, updated_at, kind, end_at, jid.
Sort *GetClosesParamsSort `form:"sort,omitempty" json:"sort,omitempty"`
// Filter Filtering on one or more fields. Must be one of: id, user_id, closer_id, reason, state, created_at, updated_at, kind, end_at, jid, campus_id, end.
Filter *map[string]string `json:"filter,omitempty"`
// Range Select on a particular range. Must be one of: id, user_id, closer_id, reason, state, created_at, updated_at, kind, end_at, jid.
Range *map[string]string `json:"range,omitempty"`
// Page Page number (1-based). The 42 API paginates index endpoints and defaults to 30 items per page.
// You can also use the `per_page` parameter to set the page size (up to 100 for many endpoints).
Page *Page `form:"page,omitempty" json:"page,omitempty"`
// PerPage Number of items per page. Maximum is generally 100 but some endpoints limit this for technical reasons.
PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"`
// PageNumber Alternate pagination style using `page[number]` (1-based page index). Can be used together with `page[size]`.
PageNumber *PageNumber `form:"page[number],omitempty" json:"page[number],omitempty"`
// PageSize Alternate pagination style to set the page size (maximum depends on endpoint, commonly up to 100).
PageSize *PageSize `form:"page[size],omitempty" json:"page[size],omitempty"`
}
GetClosesParams defines parameters for GetCloses.
type GetClosesParamsSort ¶
type GetClosesParamsSort string
GetClosesParamsSort defines parameters for GetCloses.
const ( GetClosesParamsSortCloserId GetClosesParamsSort = "closer_id" GetClosesParamsSortCreatedAt GetClosesParamsSort = "created_at" GetClosesParamsSortEndAt GetClosesParamsSort = "end_at" GetClosesParamsSortId GetClosesParamsSort = "id" GetClosesParamsSortJid GetClosesParamsSort = "jid" GetClosesParamsSortKind GetClosesParamsSort = "kind" GetClosesParamsSortReason GetClosesParamsSort = "reason" GetClosesParamsSortState GetClosesParamsSort = "state" GetClosesParamsSortUpdatedAt GetClosesParamsSort = "updated_at" GetClosesParamsSortUserId GetClosesParamsSort = "user_id" )
Defines values for GetClosesParamsSort.
func (GetClosesParamsSort) Valid ¶
func (e GetClosesParamsSort) Valid() bool
Valid indicates whether the value is a known member of the GetClosesParamsSort enum.
type GetClosesResponse ¶
type GetClosesResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *[]CloseResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
}
func ParseGetClosesResponse ¶
func ParseGetClosesResponse(rsp *http.Response) (*GetClosesResponse, error)
ParseGetClosesResponse parses an HTTP response from a GetClosesWithResponse call
func (GetClosesResponse) ContentType ¶
func (r GetClosesResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetClosesResponse) GetBody ¶
func (r GetClosesResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetClosesResponse) GetJSON200 ¶
func (r GetClosesResponse) GetJSON200() *[]CloseResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetClosesResponse) GetJSONDefault ¶
func (r GetClosesResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetClosesResponse) Status ¶
func (r GetClosesResponse) Status() string
Status returns HTTPResponse.Status
func (GetClosesResponse) StatusCode ¶
func (r GetClosesResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetInternshipsParams ¶
type GetInternshipsParams struct {
// Sort The sort field. Sorted by id desc by default.
// Must be one of: id, user_id, administration_id, offer_id, language_id, state, days, user_address, user_postal, user_city, user_country, company_name, company_boss_user_first_name, company_boss_user_last_name, company_boss_user_email, company_boss_user_phone, company_user_first_name, company_user_last_name, company_user_post, company_user_email, company_user_phone, company_address, company_postal, company_city, company_country, company_siret, internship_address, internship_postal, internship_city, internship_country, contract_type, subject, start_at, end_at, duration, nb_days, nb_hours, movement, salary, currency, breach_at, convention, created_at, updated_at, anti_grav_units_user_id.
// Example: -updated_at,anti_grav_units_user_id (to sort by updated_at descending and anti_grav_units_user_id ascending)
Sort *string `form:"sort,omitempty" json:"sort,omitempty"`
// Filter Filtering on one or more fields.
// Must be one of: id, user_id, administration_id, offer_id, language_id, state, days, user_address, user_postal, user_city, user_country, company_name, company_boss_user_first_name, company_boss_user_last_name, company_boss_user_email, company_boss_user_phone, company_user_first_name, company_user_last_name, company_user_post, company_user_email, company_user_phone, company_address, company_postal, company_city, company_country, company_siret, internship_address, internship_postal, internship_city, internship_country, contract_type, subject, start_at, end_at, duration, nb_days, nb_hours, movement, salary, currency, breach_at, convention, created_at, updated_at, anti_grav_units_user_id.
// Example: filter[id]=a_value,another_value (to filter on internships with id matching a_value or another_value)
Filter *map[string]string `json:"filter,omitempty"`
// Range Select on a particular range.
// Must be one of: id, user_id, administration_id, offer_id, language_id, state, days, user_address, user_postal, user_city, user_country, company_name, company_boss_user_first_name, company_boss_user_last_name, company_boss_user_email, company_boss_user_phone, company_user_first_name, company_user_last_name, company_user_post, company_user_email, company_user_phone, company_address, company_postal, company_city, company_country, company_siret, internship_address, internship_postal, internship_city, internship_country, contract_type, subject, start_at, end_at, duration, nb_days, nb_hours, movement, salary, currency, breach_at, convention, created_at, updated_at.
// Example: range[status]=min_value,max_value (to range on internships with status field between min_value and max_value)
Range *map[string]string `json:"range,omitempty"`
// Page Page number (1-based). The 42 API paginates index endpoints and defaults to 30 items per page.
// You can also use the `per_page` parameter to set the page size (up to 100 for many endpoints).
Page *Page `form:"page,omitempty" json:"page,omitempty"`
// PerPage Number of items per page. Maximum is generally 100 but some endpoints limit this for technical reasons.
PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"`
// PageNumber Alternate pagination style using `page[number]` (1-based page index). Can be used together with `page[size]`.
PageNumber *PageNumber `form:"page[number],omitempty" json:"page[number],omitempty"`
// PageSize Alternate pagination style to set the page size (maximum depends on endpoint, commonly up to 100).
PageSize *PageSize `form:"page[size],omitempty" json:"page[size],omitempty"`
}
GetInternshipsParams defines parameters for GetInternships.
type GetInternshipsResponse ¶
type GetInternshipsResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *[]InternshipResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
// Headers200 the parsed response headers for an HTTP 200 response
Headers200 *GetInternshipsResponse200Headers
}
func ParseGetInternshipsResponse ¶
func ParseGetInternshipsResponse(rsp *http.Response) (*GetInternshipsResponse, error)
ParseGetInternshipsResponse parses an HTTP response from a GetInternshipsWithResponse call
func (GetInternshipsResponse) ContentType ¶
func (r GetInternshipsResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetInternshipsResponse) GetBody ¶
func (r GetInternshipsResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetInternshipsResponse) GetJSON200 ¶
func (r GetInternshipsResponse) GetJSON200() *[]InternshipResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetInternshipsResponse) GetJSONDefault ¶
func (r GetInternshipsResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetInternshipsResponse) Status ¶
func (r GetInternshipsResponse) Status() string
Status returns HTTPResponse.Status
func (GetInternshipsResponse) StatusCode ¶
func (r GetInternshipsResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetInternshipsResponse200Headers ¶
GetInternshipsResponse200Headers the declared response headers of an HTTP 200 response for GetInternships
type GetLanguageByIdResponse ¶
type GetLanguageByIdResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *LanguageResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
}
func ParseGetLanguageByIdResponse ¶
func ParseGetLanguageByIdResponse(rsp *http.Response) (*GetLanguageByIdResponse, error)
ParseGetLanguageByIdResponse parses an HTTP response from a GetLanguageByIdWithResponse call
func (GetLanguageByIdResponse) ContentType ¶
func (r GetLanguageByIdResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetLanguageByIdResponse) GetBody ¶
func (r GetLanguageByIdResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetLanguageByIdResponse) GetJSON200 ¶
func (r GetLanguageByIdResponse) GetJSON200() *LanguageResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetLanguageByIdResponse) GetJSONDefault ¶
func (r GetLanguageByIdResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetLanguageByIdResponse) Status ¶
func (r GetLanguageByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetLanguageByIdResponse) StatusCode ¶
func (r GetLanguageByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetUserByIdResponse ¶
type GetUserByIdResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *UserResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
}
func ParseGetUserByIdResponse ¶
func ParseGetUserByIdResponse(rsp *http.Response) (*GetUserByIdResponse, error)
ParseGetUserByIdResponse parses an HTTP response from a GetUserByIdWithResponse call
func (GetUserByIdResponse) ContentType ¶
func (r GetUserByIdResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetUserByIdResponse) GetBody ¶
func (r GetUserByIdResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetUserByIdResponse) GetJSON200 ¶
func (r GetUserByIdResponse) GetJSON200() *UserResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetUserByIdResponse) GetJSONDefault ¶
func (r GetUserByIdResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetUserByIdResponse) Status ¶
func (r GetUserByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetUserByIdResponse) StatusCode ¶
func (r GetUserByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetUserCandidatureByIdResponse ¶
type GetUserCandidatureByIdResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *UserCandidatureResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
}
func ParseGetUserCandidatureByIdResponse ¶
func ParseGetUserCandidatureByIdResponse(rsp *http.Response) (*GetUserCandidatureByIdResponse, error)
ParseGetUserCandidatureByIdResponse parses an HTTP response from a GetUserCandidatureByIdWithResponse call
func (GetUserCandidatureByIdResponse) ContentType ¶
func (r GetUserCandidatureByIdResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetUserCandidatureByIdResponse) GetBody ¶
func (r GetUserCandidatureByIdResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetUserCandidatureByIdResponse) GetJSON200 ¶
func (r GetUserCandidatureByIdResponse) GetJSON200() *UserCandidatureResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetUserCandidatureByIdResponse) GetJSONDefault ¶
func (r GetUserCandidatureByIdResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetUserCandidatureByIdResponse) Status ¶
func (r GetUserCandidatureByIdResponse) Status() string
Status returns HTTPResponse.Status
func (GetUserCandidatureByIdResponse) StatusCode ¶
func (r GetUserCandidatureByIdResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetUsersParams ¶
type GetUsersParams struct {
// Sort The sort field. Sorted by id desc by default.
// Must be one of: id, login, email, encrypted_password, reset_password_token, reset_password_sent_at, created_at, updated_at, image, first_name, last_name, pool_year, pool_month, kind, status, otp_secret_key, otp_tmp, otp_activated, otp_backup_passwords, slack_team, slack_login, slack_mail, slack_code_validation, slack_validated_at, token_id, email_stop, linked_user_id, usual_first_name, last_seen_at, password_changed_at, encrypted_single_usage_password, first_warn_anon_sent_at, second_warn_anon_sent_at, alumnized_at, anonymized_at.
// Example: -alumnized_at,anonymized_at (to sort on alumnized_at descending and anonymized_at ascending)
Sort *string `form:"sort,omitempty" json:"sort,omitempty"`
// Filter Filtering on one or more fields.
// Must be one of: id, login, email, created_at, updated_at, pool_year, pool_month, kind, status, primary_campus_id, first_name, last_name, alumni?, staff?.
// Example: filter[id]=a_value,another_value (to filter on users with id matching a_value or another_value)
Filter *map[string]string `json:"filter,omitempty"`
// Range Select on a particular range.
// Must be one of: id, login, email, created_at, updated_at, pool_year, pool_month, kind, status.
// Example: range[status]=min_value,max_value (to range on users with status field between min_value and max_value)
Range *map[string]string `json:"range,omitempty"`
// Page Page number (1-based). The 42 API paginates index endpoints and defaults to 30 items per page.
// You can also use the `per_page` parameter to set the page size (up to 100 for many endpoints).
Page *Page `form:"page,omitempty" json:"page,omitempty"`
// PerPage Number of items per page. Maximum is generally 100 but some endpoints limit this for technical reasons.
PerPage *PerPage `form:"per_page,omitempty" json:"per_page,omitempty"`
// PageNumber Alternate pagination style using `page[number]` (1-based page index). Can be used together with `page[size]`.
PageNumber *PageNumber `form:"page[number],omitempty" json:"page[number],omitempty"`
// PageSize Alternate pagination style to set the page size (maximum depends on endpoint, commonly up to 100).
PageSize *PageSize `form:"page[size],omitempty" json:"page[size],omitempty"`
}
GetUsersParams defines parameters for GetUsers.
type GetUsersResponse ¶
type GetUsersResponse struct {
Body []byte
HTTPResponse *http.Response
// JSON200 the response for an HTTP 200 `application/json` response
JSON200 *[]LightUserResponse
// JSONDefault the response for an HTTP default `application/json` response
JSONDefault *ErrorResponse
// Headers200 the parsed response headers for an HTTP 200 response
Headers200 *GetUsersResponse200Headers
}
func ParseGetUsersResponse ¶
func ParseGetUsersResponse(rsp *http.Response) (*GetUsersResponse, error)
ParseGetUsersResponse parses an HTTP response from a GetUsersWithResponse call
func (GetUsersResponse) ContentType ¶
func (r GetUsersResponse) ContentType() string
ContentType is a convenience method to retrieve the Content-Type value from the HTTP response headers
func (GetUsersResponse) GetBody ¶
func (r GetUsersResponse) GetBody() []byte
GetBody returns the raw response body bytes
func (GetUsersResponse) GetJSON200 ¶
func (r GetUsersResponse) GetJSON200() *[]LightUserResponse
GetJSON200 returns the response for an HTTP 200 `application/json` response
func (GetUsersResponse) GetJSONDefault ¶
func (r GetUsersResponse) GetJSONDefault() *ErrorResponse
GetJSONDefault returns the response for an HTTP default `application/json` response
func (GetUsersResponse) Status ¶
func (r GetUsersResponse) Status() string
Status returns HTTPResponse.Status
func (GetUsersResponse) StatusCode ¶
func (r GetUsersResponse) StatusCode() int
StatusCode returns HTTPResponse.StatusCode
type GetUsersResponse200Headers ¶
GetUsersResponse200Headers the declared response headers of an HTTP 200 response for GetUsers
type GroupResponse ¶
GroupResponse defines model for GroupResponse.
type HasJSON200Slice ¶
Varies per endpoint — needs a type parameter
type HasJSONDefault ¶
type HasJSONDefault interface {
GetJSONDefault() *ErrorResponse
}
type HttpRequestDoer ¶
Doer performs HTTP requests.
The standard http.Client implements this interface.
type InternshipResponse ¶
type InternshipResponse struct {
AdministrationId int `json:"administration_id"`
BreachAt *time.Time `json:"breach_at"`
CompanyAddress string `json:"company_address"`
CompanyBossUserEmail string `json:"company_boss_user_email"`
CompanyBossUserFirstName string `json:"company_boss_user_first_name"`
CompanyBossUserLastName string `json:"company_boss_user_last_name"`
CompanyBossUserPhone string `json:"company_boss_user_phone"`
CompanyCity string `json:"company_city"`
CompanyCountry string `json:"company_country"`
CompanyName string `json:"company_name"`
CompanyPostal string `json:"company_postal"`
CompanySiret string `json:"company_siret"`
CompanyUserEmail string `json:"company_user_email"`
CompanyUserFirstName string `json:"company_user_first_name"`
CompanyUserLastName string `json:"company_user_last_name"`
CompanyUserPhone string `json:"company_user_phone"`
CompanyUserPost string `json:"company_user_post"`
ContractType string `json:"contract_type"`
Convention struct {
Convention struct {
Url *string `json:"url"`
} `json:"convention"`
} `json:"convention"`
ConventionUri *string `json:"convention_uri"`
Currency string `json:"currency"`
Days string `json:"days"`
Duration int `json:"duration"`
EndAt time.Time `json:"end_at"`
Id int `json:"id"`
InternshipAddress string `json:"internship_address"`
InternshipCity string `json:"internship_city"`
InternshipCountry string `json:"internship_country"`
InternshipPostal string `json:"internship_postal"`
LanguageId int `json:"language_id"`
NbDays int `json:"nb_days"`
NbHours int `json:"nb_hours"`
OfferId *int `json:"offer_id"`
ProjectsUser *int `json:"projects_user,omitempty"`
Salary InternshipResponse_Salary `json:"salary"`
StartAt time.Time `json:"start_at"`
State string `json:"state"`
Subject string `json:"subject"`
// User Example: {"active":true,"alumni?":false,"alumnized_at":null,"anonymize_date":"2025-10-24T00:00:00.000+02:00","correction_point":4,"created_at":"2018-07-17T08:57:33.128Z","data_erasure_date":"2025-10-24T00:00:00.000+02:00","displayname":"Malo Allain","email":"malallai@student.42.fr","first_name":"Malo","id":39962,"image":{"link":"https://cdn.intra.42.fr/users/39a641ed152b654cfbff5c5864eb05c1/malallai.jpg","versions":{"large":"https://cdn.intra.42.fr/users/a818d7a54298d333411557d0b55b61b3/large_malallai.jpg","medium":"https://cdn.intra.42.fr/users/53691acd1e0ea75b782ddbe121c17423/medium_malallai.jpg","micro":"https://cdn.intra.42.fr/users/6f74b46e2016b0e6c41fa05b5952e17c/micro_malallai.jpg","small":"https://cdn.intra.42.fr/users/617de91b59fd7e59ecaf6470a4b37645/small_malallai.jpg"}},"kind":"student","last_name":"Allain","location":null,"login":"malallai","phone":"hidden","pool_month":"august","pool_year":"2018","staff":false,"updated_at":"2022-09-27T18:48:28.207Z","url":"https://api.intra.42.fr/v2/users/malallai","usual_first_name":null,"usual_full_name":"Malo Allain","wallet":290}
User LightUserResponse `json:"user"`
UserAddress string `json:"user_address"`
UserCity string `json:"user_city"`
UserCountry string `json:"user_country"`
UserPostal string `json:"user_postal"`
}
InternshipResponse defines model for InternshipResponse.
type InternshipResponseSalary0 ¶
type InternshipResponseSalary0 = int
InternshipResponseSalary0 defines model for InternshipResponse.Salary.0.
type InternshipResponseSalary1 ¶
type InternshipResponseSalary1 = float32
InternshipResponseSalary1 defines model for InternshipResponse.Salary.1.
type InternshipResponse_Salary ¶
type InternshipResponse_Salary struct {
// contains filtered or unexported fields
}
InternshipResponse_Salary defines model for InternshipResponse.Salary.
func (InternshipResponse_Salary) AsInternshipResponseSalary0 ¶
func (t InternshipResponse_Salary) AsInternshipResponseSalary0() (InternshipResponseSalary0, error)
AsInternshipResponseSalary0 returns the union data inside the InternshipResponse_Salary as a InternshipResponseSalary0
func (InternshipResponse_Salary) AsInternshipResponseSalary1 ¶
func (t InternshipResponse_Salary) AsInternshipResponseSalary1() (InternshipResponseSalary1, error)
AsInternshipResponseSalary1 returns the union data inside the InternshipResponse_Salary as a InternshipResponseSalary1
func (*InternshipResponse_Salary) FromInternshipResponseSalary0 ¶
func (t *InternshipResponse_Salary) FromInternshipResponseSalary0(v InternshipResponseSalary0) error
FromInternshipResponseSalary0 overwrites any union data inside the InternshipResponse_Salary as the provided InternshipResponseSalary0
func (*InternshipResponse_Salary) FromInternshipResponseSalary1 ¶
func (t *InternshipResponse_Salary) FromInternshipResponseSalary1(v InternshipResponseSalary1) error
FromInternshipResponseSalary1 overwrites any union data inside the InternshipResponse_Salary as the provided InternshipResponseSalary1
func (InternshipResponse_Salary) MarshalJSON ¶
func (t InternshipResponse_Salary) MarshalJSON() ([]byte, error)
func (*InternshipResponse_Salary) MergeInternshipResponseSalary0 ¶
func (t *InternshipResponse_Salary) MergeInternshipResponseSalary0(v InternshipResponseSalary0) error
MergeInternshipResponseSalary0 performs a merge with any union data inside the InternshipResponse_Salary, using the provided InternshipResponseSalary0
func (*InternshipResponse_Salary) MergeInternshipResponseSalary1 ¶
func (t *InternshipResponse_Salary) MergeInternshipResponseSalary1(v InternshipResponseSalary1) error
MergeInternshipResponseSalary1 performs a merge with any union data inside the InternshipResponse_Salary, using the provided InternshipResponseSalary1
func (*InternshipResponse_Salary) UnmarshalJSON ¶
func (t *InternshipResponse_Salary) UnmarshalJSON(b []byte) error
type IntraTime ¶
IntraTime accepts Intra date strings that may be date-only or RFC3339 date-times.
func (IntraTime) MarshalJSON ¶
MarshalJSON renders the time in RFC3339Nano.
func (*IntraTime) UnmarshalJSON ¶
UnmarshalJSON normalizes common Intra formats before parsing.
type LanguageResponse ¶
type LanguageResponse struct {
CreatedAt time.Time `json:"created_at"`
Id int `json:"id"`
Identifier string `json:"identifier"`
Name string `json:"name"`
UpdatedAt time.Time `json:"updated_at"`
}
LanguageResponse defines model for LanguageResponse.
type LanguageUserResponse ¶
type LanguageUserResponse struct {
CreatedAt time.Time `json:"created_at"`
Id int `json:"id"`
LanguageId int `json:"language_id"`
Position int `json:"position"`
UserId int `json:"user_id"`
}
LanguageUserResponse defines model for LanguageUserResponse.
type LightUserResponse ¶
type LightUserResponse struct {
// Active Indicates if the user is active.
Active bool `json:"active"`
// Alumni Indicates if the user is an alumnus.
Alumni bool `json:"alumni?"`
// AlumnizedAt The date when the user became an alumnus.
AlumnizedAt *time.Time `json:"alumnized_at,omitempty"`
// AnonymizeDate The date when user data will be anonymized.
AnonymizeDate time.Time `json:"anonymize_date"`
// CorrectionPoint The user's correction points.
CorrectionPoint int `json:"correction_point"`
// CreatedAt The user creation timestamp.
CreatedAt time.Time `json:"created_at"`
// DataErasureDate The date when user data will be erased.
DataErasureDate time.Time `json:"data_erasure_date"`
// Displayname The display name of the user.
Displayname string `json:"displayname"`
// Email The email address of the user.
Email string `json:"email"`
// FirstName The first name of the user.
FirstName string `json:"first_name"`
// Id The unique identifier of the user.
Id int `json:"id"`
Image *UserImageResponse `json:"image,omitempty"`
// Kind The kind of user (e.g., student, admin, external).
Kind LightUserResponseKind `json:"kind"`
// LastName The last name of the user.
LastName string `json:"last_name"`
// Location The location of the user.
Location *string `json:"location,omitempty"`
// Login The login name of the user.
Login string `json:"login"`
// Phone The phone number of the user (always hidden).
Phone *string `json:"phone,omitempty"`
// PoolMonth The month of the user's pool.
PoolMonth string `json:"pool_month"`
// PoolYear The year of the user's pool.
PoolYear string `json:"pool_year"`
// Staff Indicates if the user is staff.
Staff *bool `json:"staff?,omitempty"`
// UpdatedAt The last user update timestamp.
UpdatedAt time.Time `json:"updated_at"`
// Url The URL to the user's resource.
Url string `json:"url"`
// UsualFirstName The usual first name of the user, first_name if none.
UsualFirstName *string `json:"usual_first_name,omitempty"`
// UsualFullName The usual full name of the user, usually usual_first_name or first_name + last_name.
UsualFullName string `json:"usual_full_name"`
// Wallet The user's wallet balance.
Wallet int `json:"wallet"`
}
LightUserResponse Example: {"active":true,"alumni?":false,"alumnized_at":null,"anonymize_date":"2025-10-24T00:00:00.000+02:00","correction_point":4,"created_at":"2018-07-17T08:57:33.128Z","data_erasure_date":"2025-10-24T00:00:00.000+02:00","displayname":"Malo Allain","email":"malallai@student.42.fr","first_name":"Malo","id":39962,"image":{"link":"https://cdn.intra.42.fr/users/39a641ed152b654cfbff5c5864eb05c1/malallai.jpg","versions":{"large":"https://cdn.intra.42.fr/users/a818d7a54298d333411557d0b55b61b3/large_malallai.jpg","medium":"https://cdn.intra.42.fr/users/53691acd1e0ea75b782ddbe121c17423/medium_malallai.jpg","micro":"https://cdn.intra.42.fr/users/6f74b46e2016b0e6c41fa05b5952e17c/micro_malallai.jpg","small":"https://cdn.intra.42.fr/users/617de91b59fd7e59ecaf6470a4b37645/small_malallai.jpg"}},"kind":"student","last_name":"Allain","location":null,"login":"malallai","phone":"hidden","pool_month":"august","pool_year":"2018","staff":false,"updated_at":"2022-09-27T18:48:28.207Z","url":"https://api.intra.42.fr/v2/users/malallai","usual_first_name":null,"usual_full_name":"Malo Allain","wallet":290}
type LightUserResponseKind ¶
type LightUserResponseKind string
LightUserResponseKind The kind of user (e.g., student, admin, external).
const ( LightUserResponseKindAdmin LightUserResponseKind = "admin" LightUserResponseKindExternal LightUserResponseKind = "external" LightUserResponseKindStudent LightUserResponseKind = "student" )
Defines values for LightUserResponseKind.
func (LightUserResponseKind) Valid ¶
func (e LightUserResponseKind) Valid() bool
Valid indicates whether the value is a known member of the LightUserResponseKind enum.
type PatronageResponse ¶
type PatronageResponse struct {
CreatedAt time.Time `json:"created_at"`
GodfatherId *int `json:"godfather_id,omitempty"`
GodsonId *int `json:"godson_id,omitempty"`
Id int `json:"id"`
Ongoing bool `json:"ongoing"`
UpdatedAt time.Time `json:"updated_at"`
UserId *int `json:"user_id,omitempty"`
}
PatronageResponse defines model for PatronageResponse.
type ProjectLightResponse ¶
type ProjectLightResponse struct {
Id int `json:"id"`
Name string `json:"name"`
ParentId *int `json:"parent_id,omitempty"`
Slug string `json:"slug"`
}
ProjectLightResponse defines model for ProjectLightResponse.
type ProjectUserResponse ¶
type ProjectUserResponse struct {
CreatedAt time.Time `json:"created_at"`
CurrentTeamId *int `json:"current_team_id,omitempty"`
CursusIds []int `json:"cursus_ids"`
FinalMark *int `json:"final_mark,omitempty"`
Id int `json:"id"`
Marked bool `json:"marked"`
MarkedAt *time.Time `json:"marked_at,omitempty"`
Occurrence int `json:"occurrence"`
Project *ProjectLightResponse `json:"project,omitempty"`
RetriableAt *time.Time `json:"retriable_at,omitempty"`
Status string `json:"status"`
UpdatedAt time.Time `json:"updated_at"`
Validated *bool `json:"validated,omitempty"`
}
ProjectUserResponse defines model for ProjectUserResponse.
type RequestEditorFn ¶
RequestEditorFn is the function signature for the RequestEditor callback function
type RoleResponse ¶
RoleResponse defines model for RoleResponse.
type SkillResponse ¶
type SkillResponse struct {
Id int `json:"id"`
Level float64 `json:"level"`
Name string `json:"name"`
}
SkillResponse defines model for SkillResponse.
type TitleResponse ¶
TitleResponse defines model for TitleResponse.
type TitleUserResponse ¶
type TitleUserResponse struct {
CreatedAt time.Time `json:"created_at"`
Id int `json:"id"`
Selected bool `json:"selected"`
TitleId int `json:"title_id"`
UpdatedAt time.Time `json:"updated_at"`
UserId int `json:"user_id"`
}
TitleUserResponse defines model for TitleUserResponse.
type UserCandidatureResponse ¶
type UserCandidatureResponse struct {
BirthCity string `json:"birth_city"`
BirthCountry *string `json:"birth_country,omitempty"`
BirthDate *openapi_types.Date `json:"birth_date,omitempty"`
ContactAffiliation string `json:"contact_affiliation"`
ContactFirstName string `json:"contact_first_name"`
ContactLastName string `json:"contact_last_name"`
ContactPhone1 string `json:"contact_phone1"`
ContactPhone2 *string `json:"contact_phone2,omitempty"`
Country *string `json:"country,omitempty"`
CreatedAt time.Time `json:"created_at"`
Email string `json:"email"`
Gender *UserCandidatureResponseGender `json:"gender,omitempty"`
HiddenPhone bool `json:"hidden_phone"`
Id int `json:"id"`
Language string `json:"language"`
MaxLevelLogic *float64 `json:"max_level_logic,omitempty"`
MaxLevelMemory *float64 `json:"max_level_memory,omitempty"`
MeetingDate *IntraDateTime `json:"meeting_date,omitempty"`
OtherInformation *string `json:"other_information,omitempty"`
Phone string `json:"phone"`
PhoneCountryCode string `json:"phone_country_code"`
Pin string `json:"pin"`
PiscineDate *IntraDateTime `json:"piscine_date,omitempty"`
PostalCity string `json:"postal_city"`
PostalComplement *string `json:"postal_complement,omitempty"`
PostalCountry string `json:"postal_country"`
PostalStreet string `json:"postal_street"`
PostalZipCode string `json:"postal_zip_code"`
UpdatedAt time.Time `json:"updated_at"`
UserId int `json:"user_id"`
ZipCode *string `json:"zip_code,omitempty"`
}
UserCandidatureResponse Example: {"birth_city":"Paris","birth_country":"France","birth_date":"2013-01-01","contact_affiliation":"Parent","contact_first_name":"Norminette","contact_last_name":"Moulinette","contact_phone1":"+33600000000","contact_phone2":null,"country":"France","created_at":"2020-08-27T07:31:49.431Z","email":"tmatis@example.com","gender":"male","hidden_phone":false,"id":42,"language":"fr","max_level_logic":null,"max_level_memory":null,"meeting_date":"2020-08-27T07:31:49.431Z","other_information":null,"phone":"+33600000000","phone_country_code":"FR","pin":"7777","piscine_date":null,"postal_city":"Paris","postal_complement":null,"postal_country":"France","postal_street":"96 boulevard Bessières","postal_zip_code":"75017","updated_at":"2025-07-10T16:16:34.238Z","user_id":42,"zip_code":"75017"}
type UserCandidatureResponseGender ¶
type UserCandidatureResponseGender string
UserCandidatureResponseGender defines model for UserCandidatureResponse.Gender.
const ( UserCandidatureResponseGenderFemale UserCandidatureResponseGender = "female" UserCandidatureResponseGenderMale UserCandidatureResponseGender = "male" UserCandidatureResponseGenderOther UserCandidatureResponseGender = "other" )
Defines values for UserCandidatureResponseGender.
func (UserCandidatureResponseGender) Valid ¶
func (e UserCandidatureResponseGender) Valid() bool
Valid indicates whether the value is a known member of the UserCandidatureResponseGender enum.
type UserImageResponse ¶
type UserImageResponse struct {
// Link The URL to the user's image.
Link string `json:"link"`
Versions struct {
// Large URL to the large version of the user's image.
Large string `json:"large"`
// Medium URL to the medium version of the user's image.
Medium string `json:"medium"`
// Micro URL to the micro version of the user's image.
Micro string `json:"micro"`
// Small URL to the small version of the user's image.
Small string `json:"small"`
} `json:"versions"`
}
UserImageResponse defines model for UserImageResponse.
type UserResponse ¶
type UserResponse struct {
Achievements []AchievementResponse `json:"achievements"`
// Active Indicates if the user is active.
Active bool `json:"active"`
// Alumni Indicates if the user is an alumnus.
Alumni bool `json:"alumni?"`
// AlumnizedAt The date when the user became an alumnus.
AlumnizedAt *time.Time `json:"alumnized_at,omitempty"`
// AnonymizeDate The date when user data will be anonymized.
AnonymizeDate time.Time `json:"anonymize_date"`
Campus []CampusResponse `json:"campus"`
CampusUsers []CampusUserResponse `json:"campus_users"`
// CorrectionPoint The user's correction points.
CorrectionPoint int `json:"correction_point"`
// CreatedAt The user creation timestamp.
CreatedAt time.Time `json:"created_at"`
CursusUsers []CursusUserResponse `json:"cursus_users"`
// DataErasureDate The date when user data will be erased.
DataErasureDate time.Time `json:"data_erasure_date"`
// Displayname The display name of the user.
Displayname string `json:"displayname"`
// Email The email address of the user.
Email string `json:"email"`
// FirstName The first name of the user.
FirstName string `json:"first_name"`
Groups []GroupResponse `json:"groups"`
// Id The unique identifier of the user.
Id int `json:"id"`
Image *UserImageResponse `json:"image,omitempty"`
// Kind The kind of user (e.g., student, admin, external).
Kind UserResponseKind `json:"kind"`
LanguagesUsers []LanguageUserResponse `json:"languages_users"`
// LastName The last name of the user.
LastName string `json:"last_name"`
// Location The location of the user.
Location *string `json:"location,omitempty"`
// Login The login name of the user.
Login string `json:"login"`
Patroned []PatronageResponse `json:"patroned"`
Patroning []PatronageResponse `json:"patroning"`
// Phone The phone number of the user (always hidden).
Phone *string `json:"phone,omitempty"`
// PoolMonth The month of the user's pool.
PoolMonth string `json:"pool_month"`
// PoolYear The year of the user's pool.
PoolYear string `json:"pool_year"`
ProjectsUsers []ProjectUserResponse `json:"projects_users"`
Roles []RoleResponse `json:"roles"`
// Staff Indicates if the user is staff.
Staff *bool `json:"staff?,omitempty"`
Titles []TitleResponse `json:"titles"`
TitlesUsers []TitleUserResponse `json:"titles_users"`
// UpdatedAt The last user update timestamp.
UpdatedAt time.Time `json:"updated_at"`
// Url The URL to the user's resource.
Url string `json:"url"`
// UsualFirstName The usual first name of the user, first_name if none.
UsualFirstName *string `json:"usual_first_name,omitempty"`
// UsualFullName The usual full name of the user, usually usual_first_name or first_name + last_name.
UsualFullName string `json:"usual_full_name"`
// Wallet The user's wallet balance.
Wallet int `json:"wallet"`
}
UserResponse defines model for UserResponse.
type UserResponseKind ¶
type UserResponseKind string
UserResponseKind The kind of user (e.g., student, admin, external).
const ( UserResponseKindAdmin UserResponseKind = "admin" UserResponseKindExternal UserResponseKind = "external" UserResponseKindStudent UserResponseKind = "student" )
Defines values for UserResponseKind.
func (UserResponseKind) Valid ¶
func (e UserResponseKind) Valid() bool
Valid indicates whether the value is a known member of the UserResponseKind enum.